Skip to content

Commit 8149cc0

Browse files
committed
Format - no other change.
1 parent 24c2139 commit 8149cc0

File tree

2 files changed

+63
-63
lines changed
  • features/messages/impl/src/main/kotlin/io/element/android/features/messages/impl
  • libraries/textcomposer/impl/src/main/kotlin/io/element/android/libraries/textcomposer

2 files changed

+63
-63
lines changed

features/messages/impl/src/main/kotlin/io/element/android/features/messages/impl/MessagesView.kt

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -183,27 +183,27 @@ fun MessagesView(
183183
Scaffold(
184184
contentWindowInsets = WindowInsets.statusBars,
185185
topBar = {
186-
if (state.timelineState.timelineMode is Timeline.Mode.Thread) {
187-
ThreadTopBar(
188-
roomName = state.roomName,
189-
roomAvatarData = state.roomAvatar,
190-
heroes = state.heroes,
191-
isTombstoned = state.isTombstoned,
192-
onBackClick = onBackClick,
193-
)
194-
} else {
195-
MessagesViewTopBar(
196-
roomName = state.roomName,
197-
roomAvatar = state.roomAvatar,
198-
isTombstoned = state.isTombstoned,
199-
heroes = state.heroes,
200-
roomCallState = state.roomCallState,
201-
dmUserIdentityState = state.dmUserVerificationState,
202-
onBackClick = { hidingKeyboard { onBackClick() } },
203-
onRoomDetailsClick = { hidingKeyboard { onRoomDetailsClick() } },
204-
onJoinCallClick = onJoinCallClick,
205-
)
206-
}
186+
if (state.timelineState.timelineMode is Timeline.Mode.Thread) {
187+
ThreadTopBar(
188+
roomName = state.roomName,
189+
roomAvatarData = state.roomAvatar,
190+
heroes = state.heroes,
191+
isTombstoned = state.isTombstoned,
192+
onBackClick = onBackClick,
193+
)
194+
} else {
195+
MessagesViewTopBar(
196+
roomName = state.roomName,
197+
roomAvatar = state.roomAvatar,
198+
isTombstoned = state.isTombstoned,
199+
heroes = state.heroes,
200+
roomCallState = state.roomCallState,
201+
dmUserIdentityState = state.dmUserVerificationState,
202+
onBackClick = { hidingKeyboard { onBackClick() } },
203+
onRoomDetailsClick = { hidingKeyboard { onRoomDetailsClick() } },
204+
onJoinCallClick = onJoinCallClick,
205+
)
206+
}
207207
},
208208
content = { padding ->
209209
Box(

libraries/textcomposer/impl/src/main/kotlin/io/element/android/libraries/textcomposer/TextComposer.kt

Lines changed: 42 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -140,8 +140,8 @@ fun TextComposer(
140140
}
141141

142142
val layoutModifier = modifier
143-
.fillMaxSize()
144-
.height(IntrinsicSize.Min)
143+
.fillMaxSize()
144+
.height(IntrinsicSize.Min)
145145

146146
val composerOptionsButton: @Composable () -> Unit = remember(composerMode) {
147147
@Composable {
@@ -178,18 +178,18 @@ fun TextComposer(
178178
@Composable {
179179
TextInputBox(
180180
modifier = Modifier
181-
.clickable(
182-
interactionSource = remember { MutableInteractionSource() },
183-
indication = null,
184-
) {
185-
coroutineScope.launch {
186-
state.requestFocus()
187-
view.showKeyboard()
188-
}
181+
.clickable(
182+
interactionSource = remember { MutableInteractionSource() },
183+
indication = null,
184+
) {
185+
coroutineScope.launch {
186+
state.requestFocus()
187+
view.showKeyboard()
189188
}
190-
.semantics {
191-
hideFromAccessibility()
192-
},
189+
}
190+
.semantics {
191+
hideFromAccessibility()
192+
},
193193
composerMode = composerMode,
194194
onResetComposerMode = onResetComposerMode,
195195
isTextEmpty = state.richTextEditorState.messageHtml.isEmpty(),
@@ -199,8 +199,8 @@ fun TextComposer(
199199
placeholder = placeholder,
200200
registerStateUpdates = true,
201201
modifier = Modifier
202-
.padding(top = 6.dp, bottom = 6.dp)
203-
.fillMaxWidth(),
202+
.padding(top = 6.dp, bottom = 6.dp)
203+
.fillMaxWidth(),
204204
style = ElementRichTextEditorStyle.composerStyle(hasFocus = state.richTextEditorState.hasFocus),
205205
resolveMentionDisplay = resolveMentionDisplay,
206206
resolveRoomMentionDisplay = resolveAtRoomMentionDisplay,
@@ -420,8 +420,8 @@ private fun StandardLayout(
420420
if (voiceMessageState is VoiceMessageState.Preview || voiceMessageState is VoiceMessageState.Recording) {
421421
Box(
422422
modifier = Modifier
423-
.padding(bottom = 5.dp, top = 5.dp, end = 3.dp, start = 3.dp)
424-
.size(48.dp),
423+
.padding(bottom = 5.dp, top = 5.dp, end = 3.dp, start = 3.dp)
424+
.size(48.dp),
425425
contentAlignment = Alignment.Center,
426426
) {
427427
voiceDeleteButton()
@@ -431,8 +431,8 @@ private fun StandardLayout(
431431
}
432432
Box(
433433
modifier = Modifier
434-
.padding(bottom = 8.dp, top = 8.dp)
435-
.weight(1f)
434+
.padding(bottom = 8.dp, top = 8.dp)
435+
.weight(1f)
436436
) {
437437
voiceRecording()
438438
}
@@ -445,17 +445,17 @@ private fun StandardLayout(
445445
}
446446
Box(
447447
modifier = Modifier
448-
.padding(bottom = 8.dp, top = 8.dp)
449-
.weight(1f)
448+
.padding(bottom = 8.dp, top = 8.dp)
449+
.weight(1f)
450450
) {
451451
textInput()
452452
}
453453
}
454454
Box(
455455
Modifier
456-
.padding(bottom = 5.dp, top = 5.dp, end = 6.dp, start = 6.dp)
457-
.size(48.dp)
458-
.clearAndSetSemantics(endButtonA11y),
456+
.padding(bottom = 5.dp, top = 5.dp, end = 6.dp, start = 6.dp)
457+
.size(48.dp)
458+
.clearAndSetSemantics(endButtonA11y),
459459
contentAlignment = Alignment.Center,
460460
) {
461461
endButton()
@@ -506,8 +506,8 @@ private fun TextFormattingLayout(
506506
}
507507
Box(
508508
modifier = Modifier
509-
.weight(1f)
510-
.padding(horizontal = 12.dp)
509+
.weight(1f)
510+
.padding(horizontal = 12.dp)
511511
) {
512512
textInput()
513513
}
@@ -526,11 +526,11 @@ private fun TextFormattingLayout(
526526
}
527527
Box(
528528
modifier = Modifier
529-
.padding(
530-
start = 14.dp,
531-
end = 6.dp,
532-
)
533-
.clearAndSetSemantics(endButtonA11y)
529+
.padding(
530+
start = 14.dp,
531+
end = 6.dp,
532+
)
533+
.clearAndSetSemantics(endButtonA11y)
534534
) {
535535
sendButton()
536536
}
@@ -552,12 +552,12 @@ private fun TextInputBox(
552552

553553
Column(
554554
modifier = Modifier
555-
.clip(roundedCorners)
556-
.border(0.5.dp, borderColor, roundedCorners)
557-
.background(color = bgColor)
558-
.requiredHeightIn(min = 42.dp)
559-
.fillMaxSize()
560-
.then(modifier),
555+
.clip(roundedCorners)
556+
.border(0.5.dp, borderColor, roundedCorners)
557+
.background(color = bgColor)
558+
.requiredHeightIn(min = 42.dp)
559+
.fillMaxSize()
560+
.then(modifier),
561561
) {
562562
if (composerMode is MessageComposerMode.Special) {
563563
ComposerModeView(
@@ -567,18 +567,18 @@ private fun TextInputBox(
567567
}
568568
Box(
569569
modifier = Modifier
570-
.padding(top = 4.dp, bottom = 4.dp, start = 12.dp, end = 12.dp)
571-
.then(Modifier.testTag(TestTags.textEditor)),
570+
.padding(top = 4.dp, bottom = 4.dp, start = 12.dp, end = 12.dp)
571+
.then(Modifier.testTag(TestTags.textEditor)),
572572
contentAlignment = Alignment.CenterStart,
573573
) {
574574
textInput()
575575
if (isTextEmpty && composerMode.showCaptionCompatibilityWarning()) {
576576
var showBottomSheet by remember { mutableStateOf(false) }
577577
Icon(
578578
modifier = Modifier
579-
.clickable { showBottomSheet = true }
580-
.padding(horizontal = 8.dp, vertical = 4.dp)
581-
.align(Alignment.CenterEnd),
579+
.clickable { showBottomSheet = true }
580+
.padding(horizontal = 8.dp, vertical = 4.dp)
581+
.align(Alignment.CenterEnd),
582582
imageVector = CompoundIcons.InfoSolid(),
583583
tint = ElementTheme.colors.iconCriticalPrimary,
584584
contentDescription = null,

0 commit comments

Comments
 (0)