fix(chat): image viewer icons invisible on light backgrounds (#882)
The save/share/close icons and the busy spinner were tinted with colorScheme.onPrimary, which stays white under dynamic light schemes, against the viewer's scrim-colored background. Switch to onSurface, the token designed for content over non-primary surfaces. Co-authored-by: hy4ri <hy4ri@users.noreply.github.com>
This commit is contained in:
1 parent
345d2e4e89
commit
1ea1596e4e
1 file changed
+4
-4
@@ -204,7 +204,7 @@ fun ImageViewerDialog(
|
||||
Icon(
|
||||
imageVector = Icons.AutoMirrored.Filled.ArrowBack,
|
||||
contentDescription = stringResource(R.string.image_viewer_close),
|
||||
tint = MaterialTheme.colorScheme.onPrimary,
|
||||
tint = MaterialTheme.colorScheme.onSurface,
|
||||
)
|
||||
}
|
||||
Row {
|
||||
@@ -212,21 +212,21 @@ fun ImageViewerDialog(
|
||||
CircularProgressIndicator(
|
||||
modifier = Modifier.size(24.dp).padding(horizontal = 8.dp),
|
||||
strokeWidth = 2.dp,
|
||||
color = MaterialTheme.colorScheme.onPrimary,
|
||||
color = MaterialTheme.colorScheme.onSurface,
|
||||
)
|
||||
} else {
|
||||
IconButton(onClick = onSave, enabled = !isBusy) {
|
||||
Icon(
|
||||
imageVector = Icons.Filled.Download,
|
||||
contentDescription = stringResource(R.string.image_viewer_save),
|
||||
tint = MaterialTheme.colorScheme.onPrimary,
|
||||
tint = MaterialTheme.colorScheme.onSurface,
|
||||
)
|
||||
}
|
||||
IconButton(onClick = onShare, enabled = !isBusy) {
|
||||
Icon(
|
||||
imageVector = Icons.Filled.Share,
|
||||
contentDescription = stringResource(R.string.image_viewer_share),
|
||||
tint = MaterialTheme.colorScheme.onPrimary,
|
||||
tint = MaterialTheme.colorScheme.onSurface,
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user