mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-02 21:32:34 +00:00
Lambda parameters in a composable function should be in present tense, not past tense.
https://mrmans0n.github.io/compose-rules/rules/#naming-parameters-properly
This commit is contained in:
+3
-3
@@ -47,7 +47,7 @@ import io.element.android.libraries.ui.strings.CommonStrings
|
||||
fun UserProfileView(
|
||||
state: UserProfileState,
|
||||
onShareUser: () -> Unit,
|
||||
onDmStarted: (RoomId) -> Unit,
|
||||
onOpenDm: (RoomId) -> Unit,
|
||||
onStartCall: (RoomId) -> Unit,
|
||||
goBack: () -> Unit,
|
||||
openAvatarPreview: (username: String, url: String) -> Unit,
|
||||
@@ -96,7 +96,7 @@ fun UserProfileView(
|
||||
progressText = stringResource(CommonStrings.common_starting_chat),
|
||||
)
|
||||
},
|
||||
onSuccess = onDmStarted,
|
||||
onSuccess = onOpenDm,
|
||||
errorMessage = { stringResource(R.string.screen_start_chat_error_starting_chat) },
|
||||
onRetry = { state.eventSink(UserProfileEvents.StartDM) },
|
||||
onErrorDismiss = { state.eventSink(UserProfileEvents.ClearStartDMState) },
|
||||
@@ -114,7 +114,7 @@ internal fun UserProfileViewPreview(
|
||||
state = state,
|
||||
onShareUser = {},
|
||||
goBack = {},
|
||||
onDmStarted = {},
|
||||
onOpenDm = {},
|
||||
onStartCall = {},
|
||||
openAvatarPreview = { _, _ -> }
|
||||
)
|
||||
|
||||
+2
-2
@@ -63,7 +63,7 @@ private fun BlockConfirmationDialog(
|
||||
title = stringResource(R.string.screen_dm_details_block_user),
|
||||
content = stringResource(R.string.screen_dm_details_block_alert_description),
|
||||
submitText = stringResource(R.string.screen_dm_details_block_alert_action),
|
||||
onSubmitClicked = onBlockAction,
|
||||
onSubmitClick = onBlockAction,
|
||||
onDismiss = onDismiss
|
||||
)
|
||||
}
|
||||
@@ -77,7 +77,7 @@ private fun UnblockConfirmationDialog(
|
||||
title = stringResource(R.string.screen_dm_details_unblock_user),
|
||||
content = stringResource(R.string.screen_dm_details_unblock_alert_description),
|
||||
submitText = stringResource(R.string.screen_dm_details_unblock_alert_action),
|
||||
onSubmitClicked = onUnblockAction,
|
||||
onSubmitClick = onUnblockAction,
|
||||
onDismiss = onDismiss
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user