mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-03 06:55:41 +00:00
Add start padding to the send icon to make it visually centered.
This commit is contained in:
committed by
Benoit Marty
parent
c00d06d7c6
commit
3e90f59604
+5
@@ -593,6 +593,10 @@ private fun SendButton(
|
|||||||
// CommonDrawables.ic_september_send is too big... reduce its size.
|
// CommonDrawables.ic_september_send is too big... reduce its size.
|
||||||
else -> 18.dp
|
else -> 18.dp
|
||||||
}
|
}
|
||||||
|
val iconStartPadding = when (composerMode) {
|
||||||
|
is MessageComposerMode.Edit -> 0.dp
|
||||||
|
else -> 2.dp
|
||||||
|
}
|
||||||
val contentDescription = when (composerMode) {
|
val contentDescription = when (composerMode) {
|
||||||
is MessageComposerMode.Edit -> stringResource(CommonStrings.action_edit)
|
is MessageComposerMode.Edit -> stringResource(CommonStrings.action_edit)
|
||||||
else -> stringResource(CommonStrings.action_send)
|
else -> stringResource(CommonStrings.action_send)
|
||||||
@@ -606,6 +610,7 @@ private fun SendButton(
|
|||||||
Icon(
|
Icon(
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
.height(iconSize.applyScaleUp())
|
.height(iconSize.applyScaleUp())
|
||||||
|
.padding(start = iconStartPadding)
|
||||||
.align(Alignment.Center),
|
.align(Alignment.Center),
|
||||||
resourceId = iconId,
|
resourceId = iconId,
|
||||||
contentDescription = contentDescription,
|
contentDescription = contentDescription,
|
||||||
|
|||||||
Reference in New Issue
Block a user