Skip to content

Commit

Permalink
Rounded corners for change password dialog
Browse files Browse the repository at this point in the history
Signed-off-by: sowjanyakch <sowjanya.kch@gmail.com>
  • Loading branch information
sowjanyakch authored and mahibi committed Sep 26, 2024
1 parent 8c967c4 commit ebace87
Showing 1 changed file with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,19 +38,20 @@ import androidx.compose.foundation.layout.size
import androidx.compose.foundation.layout.width
import androidx.compose.foundation.rememberScrollState
import androidx.compose.foundation.shape.CircleShape
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.foundation.verticalScroll
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.automirrored.filled.ArrowBack
import androidx.compose.material3.AlertDialog
import androidx.compose.material3.Button
import androidx.compose.material3.Card
import androidx.compose.material3.ExperimentalMaterial3Api
import androidx.compose.material3.HorizontalDivider
import androidx.compose.material3.Icon
import androidx.compose.material3.IconButton
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.OutlinedTextField
import androidx.compose.material3.Scaffold
import androidx.compose.material3.Surface
import androidx.compose.material3.Switch
import androidx.compose.material3.Text
import androidx.compose.material3.TextButton
Expand Down Expand Up @@ -580,11 +581,12 @@ fun ShowChangePassword(onDismiss: () -> Unit, conversationCreationViewModel: Con
Dialog(onDismissRequest = {
onDismiss()
}) {
Surface(
Card(
modifier = Modifier
.fillMaxWidth()
.height(375.dp)
.padding(32.dp)
.clip(RoundedCornerShape(16.dp))
.background(color = colorResource(id = R.color.appbar))
) {
Column(
Expand Down Expand Up @@ -666,7 +668,7 @@ fun ShowPasswordDialog(onDismiss: () -> Unit, conversationCreationViewModel: Con
)
},
confirmButton = {
Button(
TextButton(
onClick = {
if (password.isNotEmpty() && password.isNotBlank()) {
conversationCreationViewModel.updatePassword(password)
Expand All @@ -678,7 +680,7 @@ fun ShowPasswordDialog(onDismiss: () -> Unit, conversationCreationViewModel: Con
}
},
dismissButton = {
Button(onClick = { onDismiss() }) {
TextButton(onClick = { onDismiss() }) {
Text(text = stringResource(id = R.string.nc_cancel))
}
}
Expand Down

0 comments on commit ebace87

Please sign in to comment.