Skip to content

Commit

Permalink
Remove report problem state dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
Rawa committed Oct 4, 2023
1 parent d14923c commit 1a980f4
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 234 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -49,27 +49,27 @@ import net.mullvad.mullvadvpn.viewmodel.SendingReportUiState

@Preview
@Composable
private fun ReportProblemScreenPreview() {
private fun PreviewReportProblemScreen() {
AppTheme { ReportProblemScreen(uiState = ReportProblemUiState()) }
}

@Preview
@Composable
private fun ReportProblemSendingScreenPreview() {
private fun PreviewReportProblemSendingScreen() {
AppTheme {
ReportProblemScreen(uiState = ReportProblemUiState(false, SendingReportUiState.Sending))
}
}

@Preview
@Composable
private fun ReportProblemConfirmNoEmailScreenPreview() {
private fun PreviewReportProblemConfirmNoEmailScreen() {
AppTheme { ReportProblemScreen(uiState = ReportProblemUiState(true)) }
}

@Preview
@Composable
private fun ReportProblemSuccessScreenPreview() {
private fun PreviewReportProblemSuccessScreen() {
AppTheme {
ReportProblemScreen(
uiState = ReportProblemUiState(false, SendingReportUiState.Success("email@mail.com"))
Expand All @@ -79,7 +79,7 @@ private fun ReportProblemSuccessScreenPreview() {

@Preview
@Composable
private fun ReportProblemErrorScreenPreview() {
private fun PreviewReportProblemErrorScreen() {
AppTheme {
ReportProblemScreen(
uiState =
Expand Down Expand Up @@ -127,7 +127,7 @@ fun ReportProblemScreen(
var email by rememberSaveable { mutableStateOf("") }
var description by rememberSaveable { mutableStateOf("") }

// Dialog to show sending states
// Show sending states
if (uiState.sendingState != null) {
Column(
modifier =
Expand All @@ -140,15 +140,6 @@ fun ReportProblemScreen(
ErrorContent({ onSendReport(email, description) }, onClearSendResult)
is SendingReportUiState.Success -> SentContent(uiState.sendingState)
}
// ShowReportProblemState(
// uiState.sendingState,
// onDismiss = onClearSendResult,
// onClearForm = {
// email = ""
// description = ""
// },
// retry = { onSendReport(email, description) }
// )
return@CollapsingToolbarScaffold
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@ import net.mullvad.mullvadvpn.viewmodel.ViewLogsUiState

@Preview
@Composable
private fun ViewLogsScreenPreview() {
private fun PreviewViewLogsScreen() {
AppTheme { ViewLogsScreen(uiState = ViewLogsUiState("Lorem ipsum")) }
}

@Preview
@Composable
private fun ViewLogsLoadingScreenPreview() {
private fun PreviewViewLogsLoadingScreen() {
AppTheme { ViewLogsScreen(uiState = ViewLogsUiState()) }
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ data class Dimensions(
val countryRowPadding: Dp = 18.dp,
val customPortBoxMinWidth: Dp = 80.dp,
val dialogIconHeight: Dp = 44.dp,
val dialogIconSize: Dp = 48.dp,
val expandableCellChevronSize: Dp = 30.dp,
val iconFailSuccessSize: Dp = 60.dp,
val iconFailSuccessTopMargin: Dp = 30.dp,
Expand Down Expand Up @@ -58,7 +59,6 @@ data class Dimensions(
val topBarHeight: Dp = 64.dp,
val verticalSpace: Dp = 20.dp,
val verticalSpacer: Dp = 1.dp,
val dialogIconSize: Dp = 48.dp
)

val defaultDimensions = Dimensions()
Expand Down

0 comments on commit 1a980f4

Please sign in to comment.