Reduce height of invite button, and improve click effect.

This commit is contained in:
Benoit Marty 2023-06-28 17:54:59 +02:00 committed by Benoit Marty
parent 2f544fd27a
commit b8c95045b3

View file

@ -24,10 +24,12 @@ import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.heightIn import androidx.compose.foundation.layout.heightIn
import androidx.compose.foundation.layout.padding import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.width import androidx.compose.foundation.layout.width
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material3.MaterialTheme import androidx.compose.material3.MaterialTheme
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.draw.clip
import androidx.compose.ui.res.stringResource import androidx.compose.ui.res.stringResource
import androidx.compose.ui.semantics.Role import androidx.compose.ui.semantics.Role
import androidx.compose.ui.tooling.preview.Preview import androidx.compose.ui.tooling.preview.Preview
@ -51,10 +53,11 @@ fun InvitesEntryPointView(
) { ) {
Row( Row(
modifier = Modifier modifier = Modifier
.clip(RoundedCornerShape(8.dp))
.clickable(role = Role.Button, onClick = onInvitesClicked) .clickable(role = Role.Button, onClick = onInvitesClicked)
.padding(horizontal = 16.dp) .padding(start = 24.dp, end = 16.dp, top = 4.dp, bottom = 4.dp)
.align(Alignment.CenterEnd) .align(Alignment.CenterEnd)
.heightIn(min = 48.dp), .heightIn(min = 40.dp),
verticalAlignment = Alignment.CenterVertically, verticalAlignment = Alignment.CenterVertically,
) { ) {
Text( Text(