Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.height
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.statusBars
import androidx.compose.foundation.text.selection.SelectionContainer
import androidx.compose.runtime.Composable
import androidx.compose.runtime.remember
import androidx.compose.ui.Alignment
Expand Down Expand Up @@ -172,32 +173,34 @@ internal fun CommonProfileHeader(
}.padding(horizontal = screenHorizontalPadding, vertical = 8.dp),
verticalArrangement = Arrangement.spacedBy(8.dp),
) {
Column {
RichText(
text = displayName,
textStyle = PlatformTheme.typography.title,
SelectionContainer {
Column {
RichText(
text = displayName,
textStyle = PlatformTheme.typography.title,
// modifier =
// Modifier
// .sharedElement(
// rememberSharedContentState(key = "profile-display-name-$userKey"),
// animatedVisibilityScope = this@AnimatedVisibilityScope,
// ),
)
Row(
horizontalArrangement = Arrangement.spacedBy(4.dp),
verticalAlignment = Alignment.CenterVertically,
) {
PlatformText(
text = handle,
style = PlatformTheme.typography.caption,
)
Row(
horizontalArrangement = Arrangement.spacedBy(4.dp),
verticalAlignment = Alignment.CenterVertically,
) {
PlatformText(
text = handle,
style = PlatformTheme.typography.caption,
// modifier =
// Modifier
// .sharedElement(
// rememberSharedContentState(key = "profile-handle-$userKey"),
// animatedVisibilityScope = this@AnimatedVisibilityScope,
// ),
)
handleTrailing.invoke(this)
)
handleTrailing.invoke(this)
}
}
}
content()
Expand Down
2 changes: 2 additions & 0 deletions iosApp/flare/UI/Component/CommonProfileHeader.swift
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,12 @@ struct CommonProfileHeader: View {
RichText(text: user.name)
.font(.headline)
.frame(maxWidth: .infinity, alignment: .leading)
.textSelection(.enabled)
HStack {
Text(user.handle)
.font(.subheadline)
.foregroundColor(.gray)
.textSelection(.enabled)
ForEach(0..<user.mark.count, id: \.self) { index in
let mark = user.mark[index]
switch mark {
Expand Down
Loading