mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-04-09 04:18:11 +02:00
Removes the element that was forcing everything to be right aligned
This commit is contained in:
parent
5f98a54452
commit
ea905ef6ed
@ -46,7 +46,7 @@ fun ExpandableRichTextViewer(
|
||||
val text = if (showFullText) content else content.take(350)
|
||||
|
||||
Box(contentAlignment = Alignment.BottomCenter) {
|
||||
CompositionLocalProvider(LocalLayoutDirection provides LayoutDirection.Rtl) {
|
||||
//CompositionLocalProvider(LocalLayoutDirection provides LayoutDirection.Rtl) {
|
||||
RichTextViewer(
|
||||
text,
|
||||
canPreview,
|
||||
@ -56,7 +56,7 @@ fun ExpandableRichTextViewer(
|
||||
accountViewModel,
|
||||
navController
|
||||
)
|
||||
}
|
||||
//}
|
||||
|
||||
if (content.length > 350 && !showFullText) {
|
||||
Row(
|
||||
|
@ -133,9 +133,7 @@ fun RichTextViewer(
|
||||
// FlowRow doesn't work well with paragraphs. So we need to split them
|
||||
content.split('\n').forEach { paragraph ->
|
||||
FlowRow() {
|
||||
// Did not work: if (isArabic(paragraph)) paragraph.split(' ').reversed() else
|
||||
// English is not Right side
|
||||
val s = paragraph.split(' ');
|
||||
val s = if (isArabic(paragraph)) paragraph.split(' ').reversed() else paragraph.split(' ');
|
||||
s.forEach { word: String ->
|
||||
if (canPreview) {
|
||||
// Explicit URL
|
||||
|
Loading…
x
Reference in New Issue
Block a user