mirror of
https://github.com/mihonapp/mihon.git
synced 2024-12-27 03:18:25 +01:00
Clean up strings and icons (#8326)
* Clean up strings and icons * fix incorrect usages of label_more * restore strings and reduce usage of android.R * removing icon desc of FABs anyway as app's not for visual impaired users
This commit is contained in:
parent
fde7bfa3d1
commit
4b60138d41
@ -13,12 +13,12 @@ import androidx.compose.foundation.layout.size
|
|||||||
import androidx.compose.foundation.lazy.grid.GridCells
|
import androidx.compose.foundation.lazy.grid.GridCells
|
||||||
import androidx.compose.foundation.rememberScrollState
|
import androidx.compose.foundation.rememberScrollState
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.HelpOutline
|
|
||||||
import androidx.compose.material.icons.filled.Public
|
|
||||||
import androidx.compose.material.icons.filled.Refresh
|
|
||||||
import androidx.compose.material.icons.outlined.Favorite
|
import androidx.compose.material.icons.outlined.Favorite
|
||||||
import androidx.compose.material.icons.outlined.FilterList
|
import androidx.compose.material.icons.outlined.FilterList
|
||||||
|
import androidx.compose.material.icons.outlined.HelpOutline
|
||||||
import androidx.compose.material.icons.outlined.NewReleases
|
import androidx.compose.material.icons.outlined.NewReleases
|
||||||
|
import androidx.compose.material.icons.outlined.Public
|
||||||
|
import androidx.compose.material.icons.outlined.Refresh
|
||||||
import androidx.compose.material3.FilterChip
|
import androidx.compose.material3.FilterChip
|
||||||
import androidx.compose.material3.FilterChipDefaults
|
import androidx.compose.material3.FilterChipDefaults
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
@ -253,7 +253,7 @@ fun BrowseSourceContent(
|
|||||||
listOf(
|
listOf(
|
||||||
EmptyScreenAction(
|
EmptyScreenAction(
|
||||||
stringResId = R.string.local_source_help_guide,
|
stringResId = R.string.local_source_help_guide,
|
||||||
icon = Icons.Default.HelpOutline,
|
icon = Icons.Outlined.HelpOutline,
|
||||||
onClick = onLocalSourceHelpClick,
|
onClick = onLocalSourceHelpClick,
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
@ -261,17 +261,17 @@ fun BrowseSourceContent(
|
|||||||
listOf(
|
listOf(
|
||||||
EmptyScreenAction(
|
EmptyScreenAction(
|
||||||
stringResId = R.string.action_retry,
|
stringResId = R.string.action_retry,
|
||||||
icon = Icons.Default.Refresh,
|
icon = Icons.Outlined.Refresh,
|
||||||
onClick = mangaList::refresh,
|
onClick = mangaList::refresh,
|
||||||
),
|
),
|
||||||
EmptyScreenAction(
|
EmptyScreenAction(
|
||||||
stringResId = R.string.action_open_in_web_view,
|
stringResId = R.string.action_open_in_web_view,
|
||||||
icon = Icons.Default.Public,
|
icon = Icons.Outlined.Public,
|
||||||
onClick = onWebViewClick,
|
onClick = onWebViewClick,
|
||||||
),
|
),
|
||||||
EmptyScreenAction(
|
EmptyScreenAction(
|
||||||
stringResId = R.string.label_help,
|
stringResId = R.string.label_help,
|
||||||
icon = Icons.Default.HelpOutline,
|
icon = Icons.Outlined.HelpOutline,
|
||||||
onClick = onHelpClick,
|
onClick = onHelpClick,
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
@ -12,7 +12,7 @@ import androidx.compose.foundation.layout.padding
|
|||||||
import androidx.compose.foundation.layout.size
|
import androidx.compose.foundation.layout.size
|
||||||
import androidx.compose.foundation.lazy.items
|
import androidx.compose.foundation.lazy.items
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.Close
|
import androidx.compose.material.icons.outlined.Close
|
||||||
import androidx.compose.material3.AlertDialog
|
import androidx.compose.material3.AlertDialog
|
||||||
import androidx.compose.material3.Button
|
import androidx.compose.material3.Button
|
||||||
import androidx.compose.material3.CircularProgressIndicator
|
import androidx.compose.material3.CircularProgressIndicator
|
||||||
@ -368,7 +368,7 @@ private fun ExtensionItemActions(
|
|||||||
} else {
|
} else {
|
||||||
IconButton(onClick = { onClickItemCancel(extension) }) {
|
IconButton(onClick = { onClickItemCancel(extension) }) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Close,
|
imageVector = Icons.Outlined.Close,
|
||||||
contentDescription = stringResource(R.string.action_cancel),
|
contentDescription = stringResource(R.string.action_cancel),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -47,7 +47,7 @@ fun SourceIcon(
|
|||||||
when {
|
when {
|
||||||
source.isStub && icon == null -> {
|
source.isStub && icon == null -> {
|
||||||
Image(
|
Image(
|
||||||
imageVector = Icons.Default.Warning,
|
imageVector = Icons.Filled.Warning,
|
||||||
contentDescription = null,
|
contentDescription = null,
|
||||||
colorFilter = ColorFilter.tint(MaterialTheme.colorScheme.error),
|
colorFilter = ColorFilter.tint(MaterialTheme.colorScheme.error),
|
||||||
modifier = modifier.then(defaultModifier),
|
modifier = modifier.then(defaultModifier),
|
||||||
@ -104,7 +104,7 @@ fun ExtensionIcon(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
is Extension.Untrusted -> Image(
|
is Extension.Untrusted -> Image(
|
||||||
imageVector = Icons.Default.Dangerous,
|
imageVector = Icons.Filled.Dangerous,
|
||||||
contentDescription = null,
|
contentDescription = null,
|
||||||
colorFilter = ColorFilter.tint(MaterialTheme.colorScheme.error),
|
colorFilter = ColorFilter.tint(MaterialTheme.colorScheme.error),
|
||||||
modifier = modifier.then(defaultModifier),
|
modifier = modifier.then(defaultModifier),
|
||||||
|
@ -20,7 +20,7 @@ fun RemoveMangaDialog(
|
|||||||
onDismissRequest = onDismissRequest,
|
onDismissRequest = onDismissRequest,
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
confirmButton = {
|
confirmButton = {
|
||||||
|
@ -130,7 +130,7 @@ fun CategoryDeleteDialog(
|
|||||||
},
|
},
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
title = {
|
title = {
|
||||||
|
@ -18,8 +18,10 @@ import androidx.compose.material3.Text
|
|||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.ui.Alignment
|
import androidx.compose.ui.Alignment
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
|
import androidx.compose.ui.res.stringResource
|
||||||
import eu.kanade.domain.category.model.Category
|
import eu.kanade.domain.category.model.Category
|
||||||
import eu.kanade.presentation.util.horizontalPadding
|
import eu.kanade.presentation.util.horizontalPadding
|
||||||
|
import eu.kanade.tachiyomi.R
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun CategoryListItem(
|
fun CategoryListItem(
|
||||||
@ -64,10 +66,10 @@ fun CategoryListItem(
|
|||||||
}
|
}
|
||||||
Spacer(modifier = Modifier.weight(1f))
|
Spacer(modifier = Modifier.weight(1f))
|
||||||
IconButton(onClick = onRename) {
|
IconButton(onClick = onRename) {
|
||||||
Icon(imageVector = Icons.Outlined.Edit, contentDescription = "")
|
Icon(imageVector = Icons.Outlined.Edit, contentDescription = stringResource(R.string.action_rename_category))
|
||||||
}
|
}
|
||||||
IconButton(onClick = onDelete) {
|
IconButton(onClick = onDelete) {
|
||||||
Icon(imageVector = Icons.Outlined.Delete, contentDescription = "")
|
Icon(imageVector = Icons.Outlined.Delete, contentDescription = stringResource(R.string.action_delete))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -12,11 +12,9 @@ import androidx.compose.foundation.text.KeyboardActions
|
|||||||
import androidx.compose.foundation.text.KeyboardOptions
|
import androidx.compose.foundation.text.KeyboardOptions
|
||||||
import androidx.compose.material.TextFieldDefaults
|
import androidx.compose.material.TextFieldDefaults
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.ArrowBack
|
|
||||||
import androidx.compose.material.icons.filled.Close
|
|
||||||
import androidx.compose.material.icons.filled.MoreVert
|
|
||||||
import androidx.compose.material.icons.outlined.ArrowBack
|
import androidx.compose.material.icons.outlined.ArrowBack
|
||||||
import androidx.compose.material.icons.outlined.Close
|
import androidx.compose.material.icons.outlined.Close
|
||||||
|
import androidx.compose.material.icons.outlined.MoreVert
|
||||||
import androidx.compose.material3.DropdownMenuItem
|
import androidx.compose.material3.DropdownMenuItem
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
import androidx.compose.material3.IconButton
|
import androidx.compose.material3.IconButton
|
||||||
@ -55,7 +53,7 @@ fun AppBar(
|
|||||||
subtitle: String? = null,
|
subtitle: String? = null,
|
||||||
// Up button
|
// Up button
|
||||||
navigateUp: (() -> Unit)? = null,
|
navigateUp: (() -> Unit)? = null,
|
||||||
navigationIcon: ImageVector = Icons.Default.ArrowBack,
|
navigationIcon: ImageVector = Icons.Outlined.ArrowBack,
|
||||||
// Menu
|
// Menu
|
||||||
actions: @Composable RowScope.() -> Unit = {},
|
actions: @Composable RowScope.() -> Unit = {},
|
||||||
// Action mode
|
// Action mode
|
||||||
@ -105,7 +103,7 @@ fun AppBar(
|
|||||||
titleContent: @Composable () -> Unit,
|
titleContent: @Composable () -> Unit,
|
||||||
// Up button
|
// Up button
|
||||||
navigateUp: (() -> Unit)? = null,
|
navigateUp: (() -> Unit)? = null,
|
||||||
navigationIcon: ImageVector = Icons.Default.ArrowBack,
|
navigationIcon: ImageVector = Icons.Outlined.ArrowBack,
|
||||||
// Menu
|
// Menu
|
||||||
actions: @Composable RowScope.() -> Unit = {},
|
actions: @Composable RowScope.() -> Unit = {},
|
||||||
// Action mode
|
// Action mode
|
||||||
@ -125,7 +123,7 @@ fun AppBar(
|
|||||||
if (isActionMode) {
|
if (isActionMode) {
|
||||||
IconButton(onClick = onCancelActionMode) {
|
IconButton(onClick = onCancelActionMode) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Close,
|
imageVector = Icons.Outlined.Close,
|
||||||
contentDescription = stringResource(R.string.action_cancel),
|
contentDescription = stringResource(R.string.action_cancel),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@ -200,7 +198,7 @@ fun AppBarActions(
|
|||||||
val overflowActions = actions.filterIsInstance<AppBar.OverflowAction>()
|
val overflowActions = actions.filterIsInstance<AppBar.OverflowAction>()
|
||||||
if (overflowActions.isNotEmpty()) {
|
if (overflowActions.isNotEmpty()) {
|
||||||
IconButton(onClick = { showMenu = !showMenu }) {
|
IconButton(onClick = { showMenu = !showMenu }) {
|
||||||
Icon(Icons.Default.MoreVert, contentDescription = stringResource(R.string.label_more))
|
Icon(Icons.Outlined.MoreVert, contentDescription = stringResource(R.string.abc_action_menu_overflow_description))
|
||||||
}
|
}
|
||||||
|
|
||||||
DropdownMenu(
|
DropdownMenu(
|
||||||
|
@ -68,7 +68,7 @@ fun ChangeCategoryDialog(
|
|||||||
}
|
}
|
||||||
Spacer(modifier = Modifier.weight(1f))
|
Spacer(modifier = Modifier.weight(1f))
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
TextButton(
|
TextButton(
|
||||||
onClick = {
|
onClick = {
|
||||||
|
@ -7,9 +7,9 @@ import androidx.compose.foundation.layout.Box
|
|||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.foundation.layout.size
|
import androidx.compose.foundation.layout.size
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.ArrowDownward
|
|
||||||
import androidx.compose.material.icons.filled.CheckCircle
|
import androidx.compose.material.icons.filled.CheckCircle
|
||||||
import androidx.compose.material.icons.filled.ErrorOutline
|
import androidx.compose.material.icons.outlined.ArrowDownward
|
||||||
|
import androidx.compose.material.icons.outlined.ErrorOutline
|
||||||
import androidx.compose.material.ripple.rememberRipple
|
import androidx.compose.material.ripple.rememberRipple
|
||||||
import androidx.compose.material3.CircularProgressIndicator
|
import androidx.compose.material3.CircularProgressIndicator
|
||||||
import androidx.compose.material3.DropdownMenuItem
|
import androidx.compose.material3.DropdownMenuItem
|
||||||
@ -78,7 +78,7 @@ private fun NotDownloadedIndicator(
|
|||||||
) {
|
) {
|
||||||
Icon(
|
Icon(
|
||||||
painter = painterResource(id = R.drawable.ic_download_chapter_24dp),
|
painter = painterResource(id = R.drawable.ic_download_chapter_24dp),
|
||||||
contentDescription = null,
|
contentDescription = stringResource(R.string.manga_download),
|
||||||
modifier = Modifier.size(IndicatorSize),
|
modifier = Modifier.size(IndicatorSize),
|
||||||
tint = MaterialTheme.colorScheme.onSurfaceVariant,
|
tint = MaterialTheme.colorScheme.onSurfaceVariant,
|
||||||
)
|
)
|
||||||
@ -148,7 +148,7 @@ private fun DownloadingIndicator(
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.ArrowDownward,
|
imageVector = Icons.Outlined.ArrowDownward,
|
||||||
contentDescription = null,
|
contentDescription = null,
|
||||||
modifier = ArrowModifier,
|
modifier = ArrowModifier,
|
||||||
tint = arrowColor,
|
tint = arrowColor,
|
||||||
@ -172,7 +172,7 @@ private fun DownloadedIndicator(
|
|||||||
contentAlignment = Alignment.Center,
|
contentAlignment = Alignment.Center,
|
||||||
) {
|
) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.CheckCircle,
|
imageVector = Icons.Filled.CheckCircle,
|
||||||
contentDescription = null,
|
contentDescription = null,
|
||||||
modifier = Modifier.size(IndicatorSize),
|
modifier = Modifier.size(IndicatorSize),
|
||||||
tint = MaterialTheme.colorScheme.onSurfaceVariant,
|
tint = MaterialTheme.colorScheme.onSurfaceVariant,
|
||||||
@ -204,8 +204,8 @@ private fun ErrorIndicator(
|
|||||||
contentAlignment = Alignment.Center,
|
contentAlignment = Alignment.Center,
|
||||||
) {
|
) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.ErrorOutline,
|
imageVector = Icons.Outlined.ErrorOutline,
|
||||||
contentDescription = null,
|
contentDescription = stringResource(R.string.chapter_error),
|
||||||
modifier = Modifier.size(IndicatorSize),
|
modifier = Modifier.size(IndicatorSize),
|
||||||
tint = MaterialTheme.colorScheme.error,
|
tint = MaterialTheme.colorScheme.error,
|
||||||
)
|
)
|
||||||
|
@ -39,7 +39,7 @@ fun DeleteLibraryMangaDialog(
|
|||||||
onDismissRequest = onDismissRequest,
|
onDismissRequest = onDismissRequest,
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
confirmButton = {
|
confirmButton = {
|
||||||
|
@ -10,9 +10,11 @@ import androidx.compose.material3.Icon
|
|||||||
import androidx.compose.material3.MaterialTheme
|
import androidx.compose.material3.MaterialTheme
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
|
import androidx.compose.ui.res.stringResource
|
||||||
import androidx.compose.ui.unit.DpOffset
|
import androidx.compose.ui.unit.DpOffset
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import androidx.compose.ui.window.PopupProperties
|
import androidx.compose.ui.window.PopupProperties
|
||||||
|
import eu.kanade.tachiyomi.R
|
||||||
import androidx.compose.material3.DropdownMenu as ComposeDropdownMenu
|
import androidx.compose.material3.DropdownMenu as ComposeDropdownMenu
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
@ -46,13 +48,13 @@ fun RadioMenuItem(
|
|||||||
if (isChecked) {
|
if (isChecked) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Outlined.RadioButtonChecked,
|
imageVector = Icons.Outlined.RadioButtonChecked,
|
||||||
contentDescription = "",
|
contentDescription = stringResource(R.string.selected),
|
||||||
tint = MaterialTheme.colorScheme.primary,
|
tint = MaterialTheme.colorScheme.primary,
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Outlined.RadioButtonUnchecked,
|
imageVector = Icons.Outlined.RadioButtonUnchecked,
|
||||||
contentDescription = "",
|
contentDescription = stringResource(R.string.not_selected),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -30,7 +30,7 @@ fun DuplicateMangaDialog(
|
|||||||
}
|
}
|
||||||
Spacer(modifier = Modifier.weight(1f))
|
Spacer(modifier = Modifier.weight(1f))
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
TextButton(
|
TextButton(
|
||||||
onClick = {
|
onClick = {
|
||||||
|
@ -11,8 +11,8 @@ import androidx.compose.foundation.layout.height
|
|||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.foundation.layout.paddingFromBaseline
|
import androidx.compose.foundation.layout.paddingFromBaseline
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.HelpOutline
|
import androidx.compose.material.icons.outlined.HelpOutline
|
||||||
import androidx.compose.material.icons.filled.Refresh
|
import androidx.compose.material.icons.outlined.Refresh
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
import androidx.compose.material3.MaterialTheme
|
import androidx.compose.material3.MaterialTheme
|
||||||
import androidx.compose.material3.Surface
|
import androidx.compose.material3.Surface
|
||||||
@ -187,12 +187,12 @@ private fun WithActionPreview() {
|
|||||||
actions = listOf(
|
actions = listOf(
|
||||||
EmptyScreenAction(
|
EmptyScreenAction(
|
||||||
stringResId = R.string.action_retry,
|
stringResId = R.string.action_retry,
|
||||||
icon = Icons.Default.Refresh,
|
icon = Icons.Outlined.Refresh,
|
||||||
onClick = {},
|
onClick = {},
|
||||||
),
|
),
|
||||||
EmptyScreenAction(
|
EmptyScreenAction(
|
||||||
stringResId = R.string.getting_started_guide,
|
stringResId = R.string.getting_started_guide,
|
||||||
icon = Icons.Default.HelpOutline,
|
icon = Icons.Outlined.HelpOutline,
|
||||||
onClick = {},
|
onClick = {},
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -22,13 +22,13 @@ import androidx.compose.foundation.layout.padding
|
|||||||
import androidx.compose.foundation.layout.size
|
import androidx.compose.foundation.layout.size
|
||||||
import androidx.compose.foundation.shape.ZeroCornerSize
|
import androidx.compose.foundation.shape.ZeroCornerSize
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.BookmarkAdd
|
import androidx.compose.material.icons.outlined.BookmarkAdd
|
||||||
import androidx.compose.material.icons.filled.BookmarkRemove
|
import androidx.compose.material.icons.outlined.BookmarkRemove
|
||||||
import androidx.compose.material.icons.filled.DoneAll
|
|
||||||
import androidx.compose.material.icons.filled.RemoveDone
|
|
||||||
import androidx.compose.material.icons.outlined.Delete
|
import androidx.compose.material.icons.outlined.Delete
|
||||||
|
import androidx.compose.material.icons.outlined.DoneAll
|
||||||
import androidx.compose.material.icons.outlined.Download
|
import androidx.compose.material.icons.outlined.Download
|
||||||
import androidx.compose.material.icons.outlined.Label
|
import androidx.compose.material.icons.outlined.Label
|
||||||
|
import androidx.compose.material.icons.outlined.RemoveDone
|
||||||
import androidx.compose.material.ripple.rememberRipple
|
import androidx.compose.material.ripple.rememberRipple
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
import androidx.compose.material3.MaterialTheme
|
import androidx.compose.material3.MaterialTheme
|
||||||
@ -98,7 +98,7 @@ fun MangaBottomActionMenu(
|
|||||||
if (onBookmarkClicked != null) {
|
if (onBookmarkClicked != null) {
|
||||||
Button(
|
Button(
|
||||||
title = stringResource(R.string.action_bookmark),
|
title = stringResource(R.string.action_bookmark),
|
||||||
icon = Icons.Default.BookmarkAdd,
|
icon = Icons.Outlined.BookmarkAdd,
|
||||||
toConfirm = confirm[0],
|
toConfirm = confirm[0],
|
||||||
onLongClick = { onLongClickItem(0) },
|
onLongClick = { onLongClickItem(0) },
|
||||||
onClick = onBookmarkClicked,
|
onClick = onBookmarkClicked,
|
||||||
@ -107,7 +107,7 @@ fun MangaBottomActionMenu(
|
|||||||
if (onRemoveBookmarkClicked != null) {
|
if (onRemoveBookmarkClicked != null) {
|
||||||
Button(
|
Button(
|
||||||
title = stringResource(R.string.action_remove_bookmark),
|
title = stringResource(R.string.action_remove_bookmark),
|
||||||
icon = Icons.Default.BookmarkRemove,
|
icon = Icons.Outlined.BookmarkRemove,
|
||||||
toConfirm = confirm[1],
|
toConfirm = confirm[1],
|
||||||
onLongClick = { onLongClickItem(1) },
|
onLongClick = { onLongClickItem(1) },
|
||||||
onClick = onRemoveBookmarkClicked,
|
onClick = onRemoveBookmarkClicked,
|
||||||
@ -116,7 +116,7 @@ fun MangaBottomActionMenu(
|
|||||||
if (onMarkAsReadClicked != null) {
|
if (onMarkAsReadClicked != null) {
|
||||||
Button(
|
Button(
|
||||||
title = stringResource(R.string.action_mark_as_read),
|
title = stringResource(R.string.action_mark_as_read),
|
||||||
icon = Icons.Default.DoneAll,
|
icon = Icons.Outlined.DoneAll,
|
||||||
toConfirm = confirm[2],
|
toConfirm = confirm[2],
|
||||||
onLongClick = { onLongClickItem(2) },
|
onLongClick = { onLongClickItem(2) },
|
||||||
onClick = onMarkAsReadClicked,
|
onClick = onMarkAsReadClicked,
|
||||||
@ -125,7 +125,7 @@ fun MangaBottomActionMenu(
|
|||||||
if (onMarkAsUnreadClicked != null) {
|
if (onMarkAsUnreadClicked != null) {
|
||||||
Button(
|
Button(
|
||||||
title = stringResource(R.string.action_mark_as_unread),
|
title = stringResource(R.string.action_mark_as_unread),
|
||||||
icon = Icons.Default.RemoveDone,
|
icon = Icons.Outlined.RemoveDone,
|
||||||
toConfirm = confirm[3],
|
toConfirm = confirm[3],
|
||||||
onLongClick = { onLongClickItem(3) },
|
onLongClick = { onLongClickItem(3) },
|
||||||
onClick = onMarkAsUnreadClicked,
|
onClick = onMarkAsUnreadClicked,
|
||||||
@ -254,7 +254,7 @@ fun LibraryBottomActionMenu(
|
|||||||
if (onMarkAsReadClicked != null) {
|
if (onMarkAsReadClicked != null) {
|
||||||
Button(
|
Button(
|
||||||
title = stringResource(R.string.action_mark_as_read),
|
title = stringResource(R.string.action_mark_as_read),
|
||||||
icon = Icons.Default.DoneAll,
|
icon = Icons.Outlined.DoneAll,
|
||||||
toConfirm = confirm[1],
|
toConfirm = confirm[1],
|
||||||
onLongClick = { onLongClickItem(1) },
|
onLongClick = { onLongClickItem(1) },
|
||||||
onClick = onMarkAsReadClicked,
|
onClick = onMarkAsReadClicked,
|
||||||
@ -263,7 +263,7 @@ fun LibraryBottomActionMenu(
|
|||||||
if (onMarkAsUnreadClicked != null) {
|
if (onMarkAsUnreadClicked != null) {
|
||||||
Button(
|
Button(
|
||||||
title = stringResource(R.string.action_mark_as_unread),
|
title = stringResource(R.string.action_mark_as_unread),
|
||||||
icon = Icons.Default.RemoveDone,
|
icon = Icons.Outlined.RemoveDone,
|
||||||
toConfirm = confirm[2],
|
toConfirm = confirm[2],
|
||||||
onLongClick = { onLongClickItem(2) },
|
onLongClick = { onLongClickItem(2) },
|
||||||
onClick = onMarkAsUnreadClicked,
|
onClick = onMarkAsUnreadClicked,
|
||||||
|
@ -67,7 +67,7 @@ fun HistoryDeleteDialog(
|
|||||||
},
|
},
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
@ -96,7 +96,7 @@ fun HistoryDeleteAllDialog(
|
|||||||
},
|
},
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
@ -2,7 +2,7 @@ package eu.kanade.presentation.library
|
|||||||
|
|
||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.HelpOutline
|
import androidx.compose.material.icons.outlined.HelpOutline
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.runtime.getValue
|
import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
@ -79,7 +79,7 @@ fun LibraryScreen(
|
|||||||
actions = listOf(
|
actions = listOf(
|
||||||
EmptyScreenAction(
|
EmptyScreenAction(
|
||||||
stringResId = R.string.getting_started_guide,
|
stringResId = R.string.getting_started_guide,
|
||||||
icon = Icons.Default.HelpOutline,
|
icon = Icons.Outlined.HelpOutline,
|
||||||
onClick = { handler.openUri("https://tachiyomi.org/help/guides/getting-started") },
|
onClick = { handler.openUri("https://tachiyomi.org/help/guides/getting-started") },
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -150,10 +150,10 @@ fun LibrarySelectionToolbar(
|
|||||||
titleContent = { Text(text = "${state.selection.size}") },
|
titleContent = { Text(text = "${state.selection.size}") },
|
||||||
actions = {
|
actions = {
|
||||||
IconButton(onClick = onClickSelectAll) {
|
IconButton(onClick = onClickSelectAll) {
|
||||||
Icon(Icons.Outlined.SelectAll, contentDescription = "search")
|
Icon(Icons.Outlined.SelectAll, contentDescription = stringResource(R.string.action_select_all))
|
||||||
}
|
}
|
||||||
IconButton(onClick = onClickInvertSelection) {
|
IconButton(onClick = onClickInvertSelection) {
|
||||||
Icon(Icons.Outlined.FlipToBack, contentDescription = "invert")
|
Icon(Icons.Outlined.FlipToBack, contentDescription = stringResource(R.string.action_select_inverse))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
isActionMode = true,
|
isActionMode = true,
|
||||||
|
@ -273,7 +273,7 @@ private fun MangaScreenSmallImpl(
|
|||||||
}
|
}
|
||||||
Text(text = stringResource(id))
|
Text(text = stringResource(id))
|
||||||
},
|
},
|
||||||
icon = { Icon(imageVector = Icons.Default.PlayArrow, contentDescription = null) },
|
icon = { Icon(imageVector = Icons.Filled.PlayArrow, contentDescription = null) },
|
||||||
onClick = onContinueReading,
|
onClick = onContinueReading,
|
||||||
expanded = chapterListState.isScrollingUp() || chapterListState.isScrolledToEnd(),
|
expanded = chapterListState.isScrollingUp() || chapterListState.isScrolledToEnd(),
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
@ -486,7 +486,7 @@ fun MangaScreenLargeImpl(
|
|||||||
}
|
}
|
||||||
Text(text = stringResource(id))
|
Text(text = stringResource(id))
|
||||||
},
|
},
|
||||||
icon = { Icon(imageVector = Icons.Default.PlayArrow, contentDescription = null) },
|
icon = { Icon(imageVector = Icons.Filled.PlayArrow, contentDescription = null) },
|
||||||
onClick = onContinueReading,
|
onClick = onContinueReading,
|
||||||
expanded = chapterListState.isScrollingUp() || chapterListState.isScrolledToEnd(),
|
expanded = chapterListState.isScrollingUp() || chapterListState.isScrolledToEnd(),
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
|
@ -37,7 +37,7 @@ fun DownloadCustomAmountDialog(
|
|||||||
onDismissRequest = onDismissRequest,
|
onDismissRequest = onDismissRequest,
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
confirmButton = {
|
confirmButton = {
|
||||||
@ -62,13 +62,13 @@ fun DownloadCustomAmountDialog(
|
|||||||
onClick = { setAmount(amount - 10) },
|
onClick = { setAmount(amount - 10) },
|
||||||
enabled = amount > 0,
|
enabled = amount > 0,
|
||||||
) {
|
) {
|
||||||
Icon(imageVector = Icons.Outlined.KeyboardDoubleArrowLeft, contentDescription = "")
|
Icon(imageVector = Icons.Outlined.KeyboardDoubleArrowLeft, contentDescription = "-10")
|
||||||
}
|
}
|
||||||
IconButton(
|
IconButton(
|
||||||
onClick = { setAmount(amount - 1) },
|
onClick = { setAmount(amount - 1) },
|
||||||
enabled = amount > 0,
|
enabled = amount > 0,
|
||||||
) {
|
) {
|
||||||
Icon(imageVector = Icons.Outlined.ChevronLeft, contentDescription = "")
|
Icon(imageVector = Icons.Outlined.ChevronLeft, contentDescription = "-1")
|
||||||
}
|
}
|
||||||
OutlinedTextField(
|
OutlinedTextField(
|
||||||
modifier = Modifier.weight(1f),
|
modifier = Modifier.weight(1f),
|
||||||
@ -81,13 +81,13 @@ fun DownloadCustomAmountDialog(
|
|||||||
onClick = { setAmount(amount + 1) },
|
onClick = { setAmount(amount + 1) },
|
||||||
enabled = amount < maxAmount,
|
enabled = amount < maxAmount,
|
||||||
) {
|
) {
|
||||||
Icon(imageVector = Icons.Outlined.ChevronRight, contentDescription = "")
|
Icon(imageVector = Icons.Outlined.ChevronRight, contentDescription = "+1")
|
||||||
}
|
}
|
||||||
IconButton(
|
IconButton(
|
||||||
onClick = { setAmount(amount + 10) },
|
onClick = { setAmount(amount + 10) },
|
||||||
enabled = amount < maxAmount,
|
enabled = amount < maxAmount,
|
||||||
) {
|
) {
|
||||||
Icon(imageVector = Icons.Outlined.KeyboardDoubleArrowRight, contentDescription = "")
|
Icon(imageVector = Icons.Outlined.KeyboardDoubleArrowRight, contentDescription = "+10")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -72,7 +72,7 @@ fun MangaChapterListItem(
|
|||||||
var textHeight by remember { mutableStateOf(0) }
|
var textHeight by remember { mutableStateOf(0) }
|
||||||
if (bookmark) {
|
if (bookmark) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Bookmark,
|
imageVector = Icons.Filled.Bookmark,
|
||||||
contentDescription = stringResource(R.string.action_filter_bookmarked),
|
contentDescription = stringResource(R.string.action_filter_bookmarked),
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
.sizeIn(maxHeight = with(LocalDensity.current) { textHeight.toDp() - 2.dp }),
|
.sizeIn(maxHeight = with(LocalDensity.current) { textHeight.toDp() - 2.dp }),
|
||||||
|
@ -14,7 +14,7 @@ import androidx.compose.foundation.layout.navigationBarsPadding
|
|||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.foundation.layout.systemBars
|
import androidx.compose.foundation.layout.systemBars
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.Close
|
import androidx.compose.material.icons.outlined.Close
|
||||||
import androidx.compose.material.icons.outlined.Edit
|
import androidx.compose.material.icons.outlined.Edit
|
||||||
import androidx.compose.material.icons.outlined.Save
|
import androidx.compose.material.icons.outlined.Save
|
||||||
import androidx.compose.material.icons.outlined.Share
|
import androidx.compose.material.icons.outlined.Share
|
||||||
@ -63,7 +63,7 @@ fun MangaCoverDialog(
|
|||||||
) {
|
) {
|
||||||
IconButton(onClick = onDismissRequest) {
|
IconButton(onClick = onDismissRequest) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Close,
|
imageVector = Icons.Outlined.Close,
|
||||||
contentDescription = stringResource(R.string.action_close),
|
contentDescription = stringResource(R.string.action_close),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -16,7 +16,7 @@ fun DeleteChaptersDialog(
|
|||||||
onDismissRequest = onDismissRequest,
|
onDismissRequest = onDismissRequest,
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
confirmButton = {
|
confirmButton = {
|
||||||
|
@ -23,18 +23,18 @@ import androidx.compose.foundation.lazy.LazyRow
|
|||||||
import androidx.compose.foundation.lazy.items
|
import androidx.compose.foundation.lazy.items
|
||||||
import androidx.compose.foundation.text.selection.SelectionContainer
|
import androidx.compose.foundation.text.selection.SelectionContainer
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.AttachMoney
|
|
||||||
import androidx.compose.material.icons.filled.Block
|
|
||||||
import androidx.compose.material.icons.filled.Close
|
|
||||||
import androidx.compose.material.icons.filled.Done
|
|
||||||
import androidx.compose.material.icons.filled.DoneAll
|
|
||||||
import androidx.compose.material.icons.filled.Favorite
|
import androidx.compose.material.icons.filled.Favorite
|
||||||
import androidx.compose.material.icons.filled.FavoriteBorder
|
|
||||||
import androidx.compose.material.icons.filled.Pause
|
|
||||||
import androidx.compose.material.icons.filled.Public
|
|
||||||
import androidx.compose.material.icons.filled.Schedule
|
|
||||||
import androidx.compose.material.icons.filled.Sync
|
|
||||||
import androidx.compose.material.icons.filled.Warning
|
import androidx.compose.material.icons.filled.Warning
|
||||||
|
import androidx.compose.material.icons.outlined.AttachMoney
|
||||||
|
import androidx.compose.material.icons.outlined.Block
|
||||||
|
import androidx.compose.material.icons.outlined.Close
|
||||||
|
import androidx.compose.material.icons.outlined.Done
|
||||||
|
import androidx.compose.material.icons.outlined.DoneAll
|
||||||
|
import androidx.compose.material.icons.outlined.FavoriteBorder
|
||||||
|
import androidx.compose.material.icons.outlined.Pause
|
||||||
|
import androidx.compose.material.icons.outlined.Public
|
||||||
|
import androidx.compose.material.icons.outlined.Schedule
|
||||||
|
import androidx.compose.material.icons.outlined.Sync
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
import androidx.compose.material3.LocalContentColor
|
import androidx.compose.material3.LocalContentColor
|
||||||
import androidx.compose.material3.LocalMinimumTouchTargetEnforcement
|
import androidx.compose.material3.LocalMinimumTouchTargetEnforcement
|
||||||
@ -173,7 +173,7 @@ fun MangaActionRow(
|
|||||||
} else {
|
} else {
|
||||||
stringResource(R.string.add_to_library)
|
stringResource(R.string.add_to_library)
|
||||||
},
|
},
|
||||||
icon = if (favorite) Icons.Default.Favorite else Icons.Default.FavoriteBorder,
|
icon = if (favorite) Icons.Filled.Favorite else Icons.Outlined.FavoriteBorder,
|
||||||
color = if (favorite) MaterialTheme.colorScheme.primary else defaultActionButtonColor,
|
color = if (favorite) MaterialTheme.colorScheme.primary else defaultActionButtonColor,
|
||||||
onClick = onAddToLibraryClicked,
|
onClick = onAddToLibraryClicked,
|
||||||
onLongClick = onEditCategory,
|
onLongClick = onEditCategory,
|
||||||
@ -185,7 +185,7 @@ fun MangaActionRow(
|
|||||||
} else {
|
} else {
|
||||||
pluralStringResource(id = R.plurals.num_trackers, count = trackingCount, trackingCount)
|
pluralStringResource(id = R.plurals.num_trackers, count = trackingCount, trackingCount)
|
||||||
},
|
},
|
||||||
icon = if (trackingCount == 0) Icons.Default.Sync else Icons.Default.Done,
|
icon = if (trackingCount == 0) Icons.Outlined.Sync else Icons.Outlined.Done,
|
||||||
color = if (trackingCount == 0) defaultActionButtonColor else MaterialTheme.colorScheme.primary,
|
color = if (trackingCount == 0) defaultActionButtonColor else MaterialTheme.colorScheme.primary,
|
||||||
onClick = onTrackingClicked,
|
onClick = onTrackingClicked,
|
||||||
)
|
)
|
||||||
@ -193,7 +193,7 @@ fun MangaActionRow(
|
|||||||
if (onWebViewClicked != null) {
|
if (onWebViewClicked != null) {
|
||||||
MangaActionButton(
|
MangaActionButton(
|
||||||
title = stringResource(R.string.action_web_view),
|
title = stringResource(R.string.action_web_view),
|
||||||
icon = Icons.Default.Public,
|
icon = Icons.Outlined.Public,
|
||||||
color = defaultActionButtonColor,
|
color = defaultActionButtonColor,
|
||||||
onClick = onWebViewClicked,
|
onClick = onWebViewClicked,
|
||||||
)
|
)
|
||||||
@ -345,13 +345,13 @@ private fun MangaAndSourceTitlesLarge(
|
|||||||
) {
|
) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = when (status) {
|
imageVector = when (status) {
|
||||||
SManga.ONGOING.toLong() -> Icons.Default.Schedule
|
SManga.ONGOING.toLong() -> Icons.Outlined.Schedule
|
||||||
SManga.COMPLETED.toLong() -> Icons.Default.DoneAll
|
SManga.COMPLETED.toLong() -> Icons.Outlined.DoneAll
|
||||||
SManga.LICENSED.toLong() -> Icons.Default.AttachMoney
|
SManga.LICENSED.toLong() -> Icons.Outlined.AttachMoney
|
||||||
SManga.PUBLISHING_FINISHED.toLong() -> Icons.Default.Done
|
SManga.PUBLISHING_FINISHED.toLong() -> Icons.Outlined.Done
|
||||||
SManga.CANCELLED.toLong() -> Icons.Default.Close
|
SManga.CANCELLED.toLong() -> Icons.Outlined.Close
|
||||||
SManga.ON_HIATUS.toLong() -> Icons.Default.Pause
|
SManga.ON_HIATUS.toLong() -> Icons.Outlined.Pause
|
||||||
else -> Icons.Default.Block
|
else -> Icons.Outlined.Block
|
||||||
},
|
},
|
||||||
contentDescription = null,
|
contentDescription = null,
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
@ -375,7 +375,7 @@ private fun MangaAndSourceTitlesLarge(
|
|||||||
DotSeparatorText()
|
DotSeparatorText()
|
||||||
if (isStubSource) {
|
if (isStubSource) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Warning,
|
imageVector = Icons.Filled.Warning,
|
||||||
contentDescription = null,
|
contentDescription = null,
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
.padding(end = 4.dp)
|
.padding(end = 4.dp)
|
||||||
@ -478,13 +478,13 @@ private fun MangaAndSourceTitlesSmall(
|
|||||||
) {
|
) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = when (status) {
|
imageVector = when (status) {
|
||||||
SManga.ONGOING.toLong() -> Icons.Default.Schedule
|
SManga.ONGOING.toLong() -> Icons.Outlined.Schedule
|
||||||
SManga.COMPLETED.toLong() -> Icons.Default.DoneAll
|
SManga.COMPLETED.toLong() -> Icons.Outlined.DoneAll
|
||||||
SManga.LICENSED.toLong() -> Icons.Default.AttachMoney
|
SManga.LICENSED.toLong() -> Icons.Outlined.AttachMoney
|
||||||
SManga.PUBLISHING_FINISHED.toLong() -> Icons.Default.Done
|
SManga.PUBLISHING_FINISHED.toLong() -> Icons.Outlined.Done
|
||||||
SManga.CANCELLED.toLong() -> Icons.Default.Close
|
SManga.CANCELLED.toLong() -> Icons.Outlined.Close
|
||||||
SManga.ON_HIATUS.toLong() -> Icons.Default.Pause
|
SManga.ON_HIATUS.toLong() -> Icons.Outlined.Pause
|
||||||
else -> Icons.Default.Block
|
else -> Icons.Outlined.Block
|
||||||
},
|
},
|
||||||
contentDescription = null,
|
contentDescription = null,
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
@ -508,7 +508,7 @@ private fun MangaAndSourceTitlesSmall(
|
|||||||
DotSeparatorText()
|
DotSeparatorText()
|
||||||
if (isStubSource) {
|
if (isStubSource) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Warning,
|
imageVector = Icons.Filled.Warning,
|
||||||
contentDescription = null,
|
contentDescription = null,
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
.padding(end = 4.dp)
|
.padding(end = 4.dp)
|
||||||
|
@ -5,13 +5,13 @@ import androidx.compose.foundation.layout.Column
|
|||||||
import androidx.compose.foundation.layout.WindowInsets
|
import androidx.compose.foundation.layout.WindowInsets
|
||||||
import androidx.compose.foundation.layout.statusBars
|
import androidx.compose.foundation.layout.statusBars
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.ArrowBack
|
import androidx.compose.material.icons.outlined.ArrowBack
|
||||||
import androidx.compose.material.icons.filled.Close
|
import androidx.compose.material.icons.outlined.Close
|
||||||
import androidx.compose.material.icons.filled.FlipToBack
|
|
||||||
import androidx.compose.material.icons.filled.MoreVert
|
|
||||||
import androidx.compose.material.icons.filled.SelectAll
|
|
||||||
import androidx.compose.material.icons.outlined.Download
|
import androidx.compose.material.icons.outlined.Download
|
||||||
import androidx.compose.material.icons.outlined.FilterList
|
import androidx.compose.material.icons.outlined.FilterList
|
||||||
|
import androidx.compose.material.icons.outlined.FlipToBack
|
||||||
|
import androidx.compose.material.icons.outlined.MoreVert
|
||||||
|
import androidx.compose.material.icons.outlined.SelectAll
|
||||||
import androidx.compose.material3.DropdownMenuItem
|
import androidx.compose.material3.DropdownMenuItem
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
import androidx.compose.material3.IconButton
|
import androidx.compose.material3.IconButton
|
||||||
@ -71,7 +71,7 @@ fun MangaToolbar(
|
|||||||
navigationIcon = {
|
navigationIcon = {
|
||||||
IconButton(onClick = onBackClicked) {
|
IconButton(onClick = onBackClicked) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = if (isActionMode) Icons.Default.Close else Icons.Default.ArrowBack,
|
imageVector = if (isActionMode) Icons.Outlined.Close else Icons.Outlined.ArrowBack,
|
||||||
contentDescription = stringResource(R.string.abc_action_bar_up_description),
|
contentDescription = stringResource(R.string.abc_action_bar_up_description),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@ -80,13 +80,13 @@ fun MangaToolbar(
|
|||||||
if (isActionMode) {
|
if (isActionMode) {
|
||||||
IconButton(onClick = onSelectAll) {
|
IconButton(onClick = onSelectAll) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.SelectAll,
|
imageVector = Icons.Outlined.SelectAll,
|
||||||
contentDescription = stringResource(R.string.action_select_all),
|
contentDescription = stringResource(R.string.action_select_all),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
IconButton(onClick = onInvertSelection) {
|
IconButton(onClick = onInvertSelection) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.FlipToBack,
|
imageVector = Icons.Outlined.FlipToBack,
|
||||||
contentDescription = stringResource(R.string.action_select_inverse),
|
contentDescription = stringResource(R.string.action_select_inverse),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@ -161,7 +161,7 @@ fun MangaToolbar(
|
|||||||
Box {
|
Box {
|
||||||
IconButton(onClick = { onMoreExpanded(!moreExpanded) }) {
|
IconButton(onClick = { onMoreExpanded(!moreExpanded) }) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.MoreVert,
|
imageVector = Icons.Outlined.MoreVert,
|
||||||
contentDescription = stringResource(R.string.abc_action_menu_overflow_description),
|
contentDescription = stringResource(R.string.abc_action_menu_overflow_description),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -3,7 +3,7 @@ package eu.kanade.presentation.more.settings
|
|||||||
import androidx.annotation.StringRes
|
import androidx.annotation.StringRes
|
||||||
import androidx.compose.foundation.layout.RowScope
|
import androidx.compose.foundation.layout.RowScope
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.ArrowBack
|
import androidx.compose.material.icons.outlined.ArrowBack
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
import androidx.compose.material3.IconButton
|
import androidx.compose.material3.IconButton
|
||||||
import androidx.compose.material3.Text
|
import androidx.compose.material3.Text
|
||||||
@ -28,7 +28,7 @@ fun PreferenceScaffold(
|
|||||||
if (onBackPressed != null) {
|
if (onBackPressed != null) {
|
||||||
IconButton(onClick = onBackPressed) {
|
IconButton(onClick = onBackPressed) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.ArrowBack,
|
imageVector = Icons.Outlined.ArrowBack,
|
||||||
contentDescription = stringResource(R.string.abc_action_bar_up_description),
|
contentDescription = stringResource(R.string.abc_action_bar_up_description),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -81,7 +81,7 @@ class ClearDatabaseScreen : Screen {
|
|||||||
},
|
},
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = model::hideConfirmation) {
|
TextButton(onClick = model::hideConfirmation) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
text = {
|
text = {
|
||||||
|
@ -345,7 +345,7 @@ class SettingsAdvancedScreen : SearchableSettings {
|
|||||||
text = { Text(text = stringResource(R.string.ext_installer_shizuku_unavailable_dialog)) },
|
text = { Text(text = stringResource(R.string.ext_installer_shizuku_unavailable_dialog)) },
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = dismiss) {
|
TextButton(onClick = dismiss) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
confirmButton = {
|
confirmButton = {
|
||||||
|
@ -192,7 +192,7 @@ class SettingsBackupScreen : SearchableSettings {
|
|||||||
},
|
},
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
confirmButton = {
|
confirmButton = {
|
||||||
@ -252,7 +252,7 @@ class SettingsBackupScreen : SearchableSettings {
|
|||||||
onDismissRequest()
|
onDismissRequest()
|
||||||
},
|
},
|
||||||
) {
|
) {
|
||||||
Text(text = stringResource(R.string.copy))
|
Text(text = stringResource(android.R.string.copy))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
confirmButton = {
|
confirmButton = {
|
||||||
|
@ -326,7 +326,7 @@ class SettingsLibraryScreen : SearchableSettings {
|
|||||||
},
|
},
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
confirmButton = {
|
confirmButton = {
|
||||||
|
@ -8,7 +8,7 @@ import androidx.compose.foundation.lazy.itemsIndexed
|
|||||||
import androidx.compose.foundation.lazy.rememberLazyListState
|
import androidx.compose.foundation.lazy.rememberLazyListState
|
||||||
import androidx.compose.foundation.shape.RoundedCornerShape
|
import androidx.compose.foundation.shape.RoundedCornerShape
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.ArrowBack
|
import androidx.compose.material.icons.outlined.ArrowBack
|
||||||
import androidx.compose.material.icons.outlined.ChromeReaderMode
|
import androidx.compose.material.icons.outlined.ChromeReaderMode
|
||||||
import androidx.compose.material.icons.outlined.Code
|
import androidx.compose.material.icons.outlined.Code
|
||||||
import androidx.compose.material.icons.outlined.CollectionsBookmark
|
import androidx.compose.material.icons.outlined.CollectionsBookmark
|
||||||
@ -98,7 +98,7 @@ object SettingsMainScreen : Screen {
|
|||||||
navigationIcon = {
|
navigationIcon = {
|
||||||
IconButton(onClick = backPress::invoke) {
|
IconButton(onClick = backPress::invoke) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.ArrowBack,
|
imageVector = Icons.Outlined.ArrowBack,
|
||||||
contentDescription = stringResource(R.string.abc_action_bar_up_description),
|
contentDescription = stringResource(R.string.abc_action_bar_up_description),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -17,8 +17,8 @@ import androidx.compose.foundation.text.BasicTextField
|
|||||||
import androidx.compose.foundation.text.KeyboardActions
|
import androidx.compose.foundation.text.KeyboardActions
|
||||||
import androidx.compose.foundation.text.KeyboardOptions
|
import androidx.compose.foundation.text.KeyboardOptions
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.ArrowBack
|
import androidx.compose.material.icons.outlined.ArrowBack
|
||||||
import androidx.compose.material.icons.filled.Close
|
import androidx.compose.material.icons.outlined.Close
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
import androidx.compose.material3.IconButton
|
import androidx.compose.material3.IconButton
|
||||||
import androidx.compose.material3.MaterialTheme
|
import androidx.compose.material3.MaterialTheme
|
||||||
@ -95,8 +95,8 @@ class SettingsSearchScreen : Screen {
|
|||||||
if (canPop) {
|
if (canPop) {
|
||||||
IconButton(onClick = navigator::pop) {
|
IconButton(onClick = navigator::pop) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.ArrowBack,
|
imageVector = Icons.Outlined.ArrowBack,
|
||||||
contentDescription = null,
|
contentDescription = stringResource(R.string.abc_action_bar_up_description),
|
||||||
tint = MaterialTheme.colorScheme.onSurfaceVariant,
|
tint = MaterialTheme.colorScheme.onSurfaceVariant,
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@ -131,7 +131,7 @@ class SettingsSearchScreen : Screen {
|
|||||||
if (textFieldValue.text.isNotEmpty()) {
|
if (textFieldValue.text.isNotEmpty()) {
|
||||||
IconButton(onClick = { textFieldValue = TextFieldValue() }) {
|
IconButton(onClick = { textFieldValue = TextFieldValue() }) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Close,
|
imageVector = Icons.Outlined.Close,
|
||||||
contentDescription = null,
|
contentDescription = null,
|
||||||
tint = MaterialTheme.colorScheme.onSurfaceVariant,
|
tint = MaterialTheme.colorScheme.onSurfaceVariant,
|
||||||
)
|
)
|
||||||
|
@ -10,10 +10,10 @@ import androidx.compose.foundation.layout.RowScope
|
|||||||
import androidx.compose.foundation.layout.fillMaxWidth
|
import androidx.compose.foundation.layout.fillMaxWidth
|
||||||
import androidx.compose.foundation.text.KeyboardOptions
|
import androidx.compose.foundation.text.KeyboardOptions
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.Close
|
|
||||||
import androidx.compose.material.icons.filled.HelpOutline
|
|
||||||
import androidx.compose.material.icons.filled.Visibility
|
import androidx.compose.material.icons.filled.Visibility
|
||||||
import androidx.compose.material.icons.filled.VisibilityOff
|
import androidx.compose.material.icons.filled.VisibilityOff
|
||||||
|
import androidx.compose.material.icons.outlined.Close
|
||||||
|
import androidx.compose.material.icons.outlined.HelpOutline
|
||||||
import androidx.compose.material3.AlertDialog
|
import androidx.compose.material3.AlertDialog
|
||||||
import androidx.compose.material3.Button
|
import androidx.compose.material3.Button
|
||||||
import androidx.compose.material3.ButtonDefaults
|
import androidx.compose.material3.ButtonDefaults
|
||||||
@ -71,7 +71,7 @@ class SettingsTrackingScreen : SearchableSettings {
|
|||||||
val uriHandler = LocalUriHandler.current
|
val uriHandler = LocalUriHandler.current
|
||||||
IconButton(onClick = { uriHandler.openUri("https://tachiyomi.org/help/guides/tracking/") }) {
|
IconButton(onClick = { uriHandler.openUri("https://tachiyomi.org/help/guides/tracking/") }) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.HelpOutline,
|
imageVector = Icons.Outlined.HelpOutline,
|
||||||
contentDescription = stringResource(R.string.tracking_guide),
|
contentDescription = stringResource(R.string.tracking_guide),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@ -199,7 +199,7 @@ class SettingsTrackingScreen : SearchableSettings {
|
|||||||
)
|
)
|
||||||
IconButton(onClick = onDismissRequest) {
|
IconButton(onClick = onDismissRequest) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Close,
|
imageVector = Icons.Outlined.Close,
|
||||||
contentDescription = stringResource(R.string.action_close),
|
contentDescription = stringResource(R.string.action_close),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@ -227,9 +227,9 @@ class SettingsTrackingScreen : SearchableSettings {
|
|||||||
IconButton(onClick = { hidePassword = !hidePassword }) {
|
IconButton(onClick = { hidePassword = !hidePassword }) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = if (hidePassword) {
|
imageVector = if (hidePassword) {
|
||||||
Icons.Default.Visibility
|
Icons.Filled.Visibility
|
||||||
} else {
|
} else {
|
||||||
Icons.Default.VisibilityOff
|
Icons.Filled.VisibilityOff
|
||||||
},
|
},
|
||||||
contentDescription = null,
|
contentDescription = null,
|
||||||
)
|
)
|
||||||
@ -317,7 +317,7 @@ class SettingsTrackingScreen : SearchableSettings {
|
|||||||
modifier = Modifier.weight(1f),
|
modifier = Modifier.weight(1f),
|
||||||
onClick = onDismissRequest,
|
onClick = onDismissRequest,
|
||||||
) {
|
) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
Button(
|
Button(
|
||||||
modifier = Modifier.weight(1f),
|
modifier = Modifier.weight(1f),
|
||||||
|
@ -45,6 +45,7 @@ import eu.kanade.presentation.components.DIVIDER_ALPHA
|
|||||||
import eu.kanade.presentation.components.MangaCover
|
import eu.kanade.presentation.components.MangaCover
|
||||||
import eu.kanade.presentation.theme.TachiyomiTheme
|
import eu.kanade.presentation.theme.TachiyomiTheme
|
||||||
import eu.kanade.presentation.util.secondaryItemAlpha
|
import eu.kanade.presentation.util.secondaryItemAlpha
|
||||||
|
import eu.kanade.tachiyomi.R
|
||||||
import eu.kanade.tachiyomi.util.system.DeviceUtil
|
import eu.kanade.tachiyomi.util.system.DeviceUtil
|
||||||
import eu.kanade.tachiyomi.util.system.isDynamicColorAvailable
|
import eu.kanade.tachiyomi.util.system.isDynamicColorAvailable
|
||||||
|
|
||||||
@ -168,8 +169,8 @@ fun AppThemePreviewItem(
|
|||||||
) {
|
) {
|
||||||
if (selected) {
|
if (selected) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.CheckCircle,
|
imageVector = Icons.Filled.CheckCircle,
|
||||||
contentDescription = null,
|
contentDescription = stringResource(R.string.selected),
|
||||||
tint = MaterialTheme.colorScheme.primary,
|
tint = MaterialTheme.colorScheme.primary,
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -17,6 +17,7 @@ import androidx.compose.ui.graphics.vector.ImageVector
|
|||||||
import androidx.compose.ui.res.stringResource
|
import androidx.compose.ui.res.stringResource
|
||||||
import androidx.compose.ui.text.input.TextFieldValue
|
import androidx.compose.ui.text.input.TextFieldValue
|
||||||
import androidx.compose.ui.window.DialogProperties
|
import androidx.compose.ui.window.DialogProperties
|
||||||
|
import eu.kanade.tachiyomi.R
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
@ -71,7 +72,7 @@ fun EditTextPreferenceWidget(
|
|||||||
},
|
},
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
@ -25,6 +25,7 @@ import eu.kanade.presentation.components.ScrollbarLazyColumn
|
|||||||
import eu.kanade.presentation.util.isScrolledToEnd
|
import eu.kanade.presentation.util.isScrolledToEnd
|
||||||
import eu.kanade.presentation.util.isScrolledToStart
|
import eu.kanade.presentation.util.isScrolledToStart
|
||||||
import eu.kanade.presentation.util.minimumTouchTargetSize
|
import eu.kanade.presentation.util.minimumTouchTargetSize
|
||||||
|
import eu.kanade.tachiyomi.R
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun <T> ListPreferenceWidget(
|
fun <T> ListPreferenceWidget(
|
||||||
@ -72,7 +73,7 @@ fun <T> ListPreferenceWidget(
|
|||||||
},
|
},
|
||||||
confirmButton = {
|
confirmButton = {
|
||||||
TextButton(onClick = { showDialog(false) }) {
|
TextButton(onClick = { showDialog(false) }) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
@ -22,6 +22,7 @@ import androidx.compose.ui.unit.dp
|
|||||||
import androidx.compose.ui.window.DialogProperties
|
import androidx.compose.ui.window.DialogProperties
|
||||||
import eu.kanade.presentation.more.settings.Preference
|
import eu.kanade.presentation.more.settings.Preference
|
||||||
import eu.kanade.presentation.util.minimumTouchTargetSize
|
import eu.kanade.presentation.util.minimumTouchTargetSize
|
||||||
|
import eu.kanade.tachiyomi.R
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun MultiSelectListPreferenceWidget(
|
fun MultiSelectListPreferenceWidget(
|
||||||
@ -98,7 +99,7 @@ fun MultiSelectListPreferenceWidget(
|
|||||||
},
|
},
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = { showDialog(false) }) {
|
TextButton(onClick = { showDialog(false) }) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
@ -44,7 +44,7 @@ private fun SwitchPreferenceWidgetPreview() {
|
|||||||
SwitchPreferenceWidget(
|
SwitchPreferenceWidget(
|
||||||
title = "Text preference with icon",
|
title = "Text preference with icon",
|
||||||
subtitle = "Text preference summary",
|
subtitle = "Text preference summary",
|
||||||
icon = Icons.Default.Preview,
|
icon = Icons.Filled.Preview,
|
||||||
checked = true,
|
checked = true,
|
||||||
onCheckedChanged = {},
|
onCheckedChanged = {},
|
||||||
)
|
)
|
||||||
|
@ -67,7 +67,7 @@ private fun TextPreferenceWidgetPreview() {
|
|||||||
TextPreferenceWidget(
|
TextPreferenceWidget(
|
||||||
title = "Text preference with icon",
|
title = "Text preference with icon",
|
||||||
subtitle = "Text preference summary",
|
subtitle = "Text preference summary",
|
||||||
icon = Icons.Default.Preview,
|
icon = Icons.Filled.Preview,
|
||||||
onPreferenceClick = {},
|
onPreferenceClick = {},
|
||||||
)
|
)
|
||||||
TextPreferenceWidget(
|
TextPreferenceWidget(
|
||||||
|
@ -11,7 +11,7 @@ import androidx.compose.foundation.layout.fillMaxWidth
|
|||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.foundation.layout.size
|
import androidx.compose.foundation.layout.size
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.Check
|
import androidx.compose.material.icons.outlined.Done
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
import androidx.compose.material3.MaterialTheme
|
import androidx.compose.material3.MaterialTheme
|
||||||
import androidx.compose.material3.Text
|
import androidx.compose.material3.Text
|
||||||
@ -20,8 +20,10 @@ import androidx.compose.ui.Alignment
|
|||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.graphics.Color
|
import androidx.compose.ui.graphics.Color
|
||||||
import androidx.compose.ui.res.painterResource
|
import androidx.compose.ui.res.painterResource
|
||||||
|
import androidx.compose.ui.res.stringResource
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import eu.kanade.presentation.more.settings.LocalPreferenceHighlighted
|
import eu.kanade.presentation.more.settings.LocalPreferenceHighlighted
|
||||||
|
import eu.kanade.tachiyomi.R
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun TrackingPreferenceWidget(
|
fun TrackingPreferenceWidget(
|
||||||
@ -64,12 +66,12 @@ fun TrackingPreferenceWidget(
|
|||||||
)
|
)
|
||||||
if (checked) {
|
if (checked) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Check,
|
imageVector = Icons.Outlined.Done,
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
.padding(4.dp)
|
.padding(4.dp)
|
||||||
.size(32.dp),
|
.size(32.dp),
|
||||||
tint = Color(0xFF4CAF50),
|
tint = Color(0xFF4CAF50),
|
||||||
contentDescription = null,
|
contentDescription = stringResource(R.string.login_success),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -102,7 +102,13 @@ fun <T> TriStateListDialog(
|
|||||||
} else {
|
} else {
|
||||||
MaterialTheme.colorScheme.primary
|
MaterialTheme.colorScheme.primary
|
||||||
},
|
},
|
||||||
contentDescription = null,
|
contentDescription = stringResource(
|
||||||
|
when (state) {
|
||||||
|
State.UNCHECKED -> R.string.not_selected
|
||||||
|
State.CHECKED -> R.string.selected
|
||||||
|
State.INVERSED -> R.string.disabled
|
||||||
|
},
|
||||||
|
),
|
||||||
)
|
)
|
||||||
Text(text = itemLabel(item))
|
Text(text = itemLabel(item))
|
||||||
}
|
}
|
||||||
@ -116,7 +122,7 @@ fun <T> TriStateListDialog(
|
|||||||
},
|
},
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
confirmButton = {
|
confirmButton = {
|
||||||
|
@ -27,7 +27,7 @@ fun UpdatesDeleteConfirmationDialog(
|
|||||||
},
|
},
|
||||||
dismissButton = {
|
dismissButton = {
|
||||||
TextButton(onClick = onDismissRequest) {
|
TextButton(onClick = onDismissRequest) {
|
||||||
Text(text = stringResource(android.R.string.cancel))
|
Text(text = stringResource(R.string.action_cancel))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
@ -8,9 +8,9 @@ import androidx.compose.foundation.layout.fillMaxWidth
|
|||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.foundation.lazy.rememberLazyListState
|
import androidx.compose.foundation.lazy.rememberLazyListState
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.FlipToBack
|
import androidx.compose.material.icons.outlined.FlipToBack
|
||||||
import androidx.compose.material.icons.filled.Refresh
|
import androidx.compose.material.icons.outlined.Refresh
|
||||||
import androidx.compose.material.icons.filled.SelectAll
|
import androidx.compose.material.icons.outlined.SelectAll
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
import androidx.compose.material3.IconButton
|
import androidx.compose.material3.IconButton
|
||||||
import androidx.compose.material3.TopAppBarScrollBehavior
|
import androidx.compose.material3.TopAppBarScrollBehavior
|
||||||
@ -215,7 +215,7 @@ private fun UpdatesAppBar(
|
|||||||
actions = {
|
actions = {
|
||||||
IconButton(onClick = onUpdateLibrary) {
|
IconButton(onClick = onUpdateLibrary) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Refresh,
|
imageVector = Icons.Outlined.Refresh,
|
||||||
contentDescription = stringResource(R.string.action_update_library),
|
contentDescription = stringResource(R.string.action_update_library),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@ -225,13 +225,13 @@ private fun UpdatesAppBar(
|
|||||||
actionModeActions = {
|
actionModeActions = {
|
||||||
IconButton(onClick = onSelectAll) {
|
IconButton(onClick = onSelectAll) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.SelectAll,
|
imageVector = Icons.Outlined.SelectAll,
|
||||||
contentDescription = stringResource(R.string.action_select_all),
|
contentDescription = stringResource(R.string.action_select_all),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
IconButton(onClick = onInvertSelection) {
|
IconButton(onClick = onInvertSelection) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.FlipToBack,
|
imageVector = Icons.Outlined.FlipToBack,
|
||||||
contentDescription = stringResource(R.string.action_select_inverse),
|
contentDescription = stringResource(R.string.action_select_inverse),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -205,7 +205,7 @@ fun UpdatesUiItem(
|
|||||||
var textHeight by remember { mutableStateOf(0) }
|
var textHeight by remember { mutableStateOf(0) }
|
||||||
if (bookmark) {
|
if (bookmark) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Default.Bookmark,
|
imageVector = Icons.Filled.Bookmark,
|
||||||
contentDescription = stringResource(R.string.action_filter_bookmarked),
|
contentDescription = stringResource(R.string.action_filter_bookmarked),
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
.sizeIn(maxHeight = with(LocalDensity.current) { textHeight.toDp() - 2.dp }),
|
.sizeIn(maxHeight = with(LocalDensity.current) { textHeight.toDp() - 2.dp }),
|
||||||
|
@ -7,9 +7,9 @@ import androidx.compose.foundation.layout.Box
|
|||||||
import androidx.compose.foundation.layout.fillMaxWidth
|
import androidx.compose.foundation.layout.fillMaxWidth
|
||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.ArrowBack
|
import androidx.compose.material.icons.outlined.ArrowBack
|
||||||
import androidx.compose.material.icons.filled.ArrowForward
|
import androidx.compose.material.icons.outlined.ArrowForward
|
||||||
import androidx.compose.material.icons.filled.Close
|
import androidx.compose.material.icons.outlined.Close
|
||||||
import androidx.compose.material3.LinearProgressIndicator
|
import androidx.compose.material3.LinearProgressIndicator
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.runtime.remember
|
import androidx.compose.runtime.remember
|
||||||
@ -48,13 +48,13 @@ fun WebViewScreen(
|
|||||||
title = state.pageTitle ?: initialTitle,
|
title = state.pageTitle ?: initialTitle,
|
||||||
subtitle = state.content.getCurrentUrl(),
|
subtitle = state.content.getCurrentUrl(),
|
||||||
navigateUp = onNavigateUp,
|
navigateUp = onNavigateUp,
|
||||||
navigationIcon = Icons.Default.Close,
|
navigationIcon = Icons.Outlined.Close,
|
||||||
actions = {
|
actions = {
|
||||||
AppBarActions(
|
AppBarActions(
|
||||||
listOf(
|
listOf(
|
||||||
AppBar.Action(
|
AppBar.Action(
|
||||||
title = stringResource(R.string.action_webview_back),
|
title = stringResource(R.string.action_webview_back),
|
||||||
icon = Icons.Default.ArrowBack,
|
icon = Icons.Outlined.ArrowBack,
|
||||||
onClick = {
|
onClick = {
|
||||||
if (navigator.canGoBack) {
|
if (navigator.canGoBack) {
|
||||||
navigator.navigateBack()
|
navigator.navigateBack()
|
||||||
@ -64,7 +64,7 @@ fun WebViewScreen(
|
|||||||
),
|
),
|
||||||
AppBar.Action(
|
AppBar.Action(
|
||||||
title = stringResource(R.string.action_webview_forward),
|
title = stringResource(R.string.action_webview_forward),
|
||||||
icon = Icons.Default.ArrowForward,
|
icon = Icons.Outlined.ArrowForward,
|
||||||
onClick = {
|
onClick = {
|
||||||
if (navigator.canGoForward) {
|
if (navigator.canGoForward) {
|
||||||
navigator.navigateForward()
|
navigator.navigateForward()
|
||||||
|
@ -59,7 +59,7 @@ class LibraryUpdateNotifier(private val context: Context) {
|
|||||||
setLargeIcon(notificationBitmap)
|
setLargeIcon(notificationBitmap)
|
||||||
setOngoing(true)
|
setOngoing(true)
|
||||||
setOnlyAlertOnce(true)
|
setOnlyAlertOnce(true)
|
||||||
addAction(R.drawable.ic_close_24dp, context.getString(android.R.string.cancel), cancelIntent)
|
addAction(R.drawable.ic_close_24dp, context.getString(R.string.action_cancel), cancelIntent)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -13,9 +13,9 @@ import androidx.compose.foundation.layout.Row
|
|||||||
import androidx.compose.foundation.layout.navigationBarsPadding
|
import androidx.compose.foundation.layout.navigationBarsPadding
|
||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.Pause
|
|
||||||
import androidx.compose.material.icons.filled.PlayArrow
|
import androidx.compose.material.icons.filled.PlayArrow
|
||||||
import androidx.compose.material.icons.outlined.MoreVert
|
import androidx.compose.material.icons.outlined.MoreVert
|
||||||
|
import androidx.compose.material.icons.outlined.Pause
|
||||||
import androidx.compose.material3.DropdownMenuItem
|
import androidx.compose.material3.DropdownMenuItem
|
||||||
import androidx.compose.material3.Icon
|
import androidx.compose.material3.Icon
|
||||||
import androidx.compose.material3.IconButton
|
import androidx.compose.material3.IconButton
|
||||||
@ -152,7 +152,7 @@ class DownloadController :
|
|||||||
IconButton(onClick = { onExpanded(!expanded) }) {
|
IconButton(onClick = { onExpanded(!expanded) }) {
|
||||||
Icon(
|
Icon(
|
||||||
imageVector = Icons.Outlined.MoreVert,
|
imageVector = Icons.Outlined.MoreVert,
|
||||||
contentDescription = stringResource(R.string.label_more),
|
contentDescription = stringResource(R.string.abc_action_menu_overflow_description),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
CascadeDropdownMenu(
|
CascadeDropdownMenu(
|
||||||
@ -234,9 +234,9 @@ class DownloadController :
|
|||||||
},
|
},
|
||||||
icon = {
|
icon = {
|
||||||
val icon = if (isRunning) {
|
val icon = if (isRunning) {
|
||||||
Icons.Default.Pause
|
Icons.Outlined.Pause
|
||||||
} else {
|
} else {
|
||||||
Icons.Default.PlayArrow
|
Icons.Filled.PlayArrow
|
||||||
}
|
}
|
||||||
Icon(imageVector = icon, contentDescription = null)
|
Icon(imageVector = icon, contentDescription = null)
|
||||||
},
|
},
|
||||||
|
@ -48,7 +48,7 @@ class SetChapterSettingsDialog(bundle: Bundle? = null) : DialogController(bundle
|
|||||||
|
|
||||||
activity?.toast(R.string.chapter_settings_updated)
|
activity?.toast(R.string.chapter_settings_updated)
|
||||||
}
|
}
|
||||||
.setNegativeButton(android.R.string.cancel, null)
|
.setNegativeButton(R.string.action_cancel, null)
|
||||||
.create()
|
.create()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -59,7 +59,7 @@ class SetTrackChaptersDialog<T> : DialogController
|
|||||||
np.clearFocus()
|
np.clearFocus()
|
||||||
listener.setChaptersRead(item, np.value)
|
listener.setChaptersRead(item, np.value)
|
||||||
}
|
}
|
||||||
.setNegativeButton(android.R.string.cancel, null)
|
.setNegativeButton(R.string.action_cancel, null)
|
||||||
.create()
|
.create()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -59,7 +59,7 @@ class SetTrackScoreDialog<T> : DialogController
|
|||||||
np.clearFocus()
|
np.clearFocus()
|
||||||
listener.setScore(item, np.value)
|
listener.setScore(item, np.value)
|
||||||
}
|
}
|
||||||
.setNegativeButton(android.R.string.cancel, null)
|
.setNegativeButton(R.string.action_cancel, null)
|
||||||
.create()
|
.create()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -48,7 +48,7 @@ class SetTrackStatusDialog<T> : DialogController
|
|||||||
.setPositiveButton(android.R.string.ok) { _, _ ->
|
.setPositiveButton(android.R.string.ok) { _, _ ->
|
||||||
listener.setStatus(item, selectedIndex)
|
listener.setStatus(item, selectedIndex)
|
||||||
}
|
}
|
||||||
.setNegativeButton(android.R.string.cancel, null)
|
.setNegativeButton(R.string.action_cancel, null)
|
||||||
.create()
|
.create()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -40,7 +40,7 @@ class ReaderPageSheet(
|
|||||||
.setPositiveButton(android.R.string.ok) { _, _ ->
|
.setPositiveButton(android.R.string.ok) { _, _ ->
|
||||||
activity.setAsCover(page)
|
activity.setAsCover(page)
|
||||||
}
|
}
|
||||||
.setNegativeButton(android.R.string.cancel, null)
|
.setNegativeButton(R.string.action_cancel, null)
|
||||||
.show()
|
.show()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -46,7 +46,7 @@
|
|||||||
android:id="@+id/title_more_icon"
|
android:id="@+id/title_more_icon"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:contentDescription="@string/label_more"
|
android:contentDescription="@string/all"
|
||||||
android:padding="16dp"
|
android:padding="16dp"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
@ -68,7 +68,7 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="?selectableItemBackgroundBorderless"
|
||||||
android:contentDescription="@string/label_more"
|
android:contentDescription="@string/abc_action_menu_overflow_description"
|
||||||
android:padding="8dp"
|
android:padding="8dp"
|
||||||
android:src="@drawable/ic_more_vert_24" />
|
android:src="@drawable/ic_more_vert_24" />
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user