Skip to content

Commit

Permalink
switch to the official FlowRow composable
Browse files Browse the repository at this point in the history
  • Loading branch information
frett committed Oct 4, 2023
1 parent 537ad03 commit 07e4b5f
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
1 change: 0 additions & 1 deletion app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,6 @@ dependencies {
implementation(libs.godtoolsShared.common)

api(libs.eventbus)
implementation(libs.accompanist.flowlayout)
implementation(libs.coil.compose)
implementation(libs.compose.reorderable)
implementation(libs.hilt)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ package org.cru.godtools.ui.account.activity

import androidx.compose.foundation.Image
import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.ExperimentalLayoutApi
import androidx.compose.foundation.layout.FlowRow
import androidx.compose.foundation.layout.Spacer
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.padding
Expand All @@ -25,8 +28,6 @@ import androidx.compose.ui.text.ParagraphStyle
import androidx.compose.ui.text.style.LineBreak
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import com.google.accompanist.flowlayout.FlowRow
import com.google.accompanist.flowlayout.SizeMode
import org.ccci.gto.android.common.androidx.compose.foundation.text.minLinesHeight
import org.ccci.gto.android.common.androidx.compose.material3.isLight
import org.ccci.gto.android.common.androidx.compose.ui.text.computeHeightForDefaultText
Expand All @@ -40,6 +41,7 @@ import org.cru.godtools.shared.user.activity.model.UserActivity
private val BADGE_SIZE = 48.dp

@Composable
@OptIn(ExperimentalLayoutApi::class)
internal fun AccountActivityBadges(
activity: UserActivity,
modifier: Modifier = Modifier
Expand All @@ -50,9 +52,8 @@ internal fun AccountActivityBadges(
)

FlowRow(
mainAxisSize = SizeMode.Wrap,
mainAxisSpacing = 16.dp,
crossAxisSpacing = 16.dp,
horizontalArrangement = Arrangement.spacedBy(16.dp),
verticalArrangement = Arrangement.spacedBy(16.dp),
modifier = Modifier
.padding(top = 16.dp)
.fillMaxWidth()
Expand Down
1 change: 0 additions & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ scarlet = "0.1.12"
splitties = "3.0.0"

[libraries]
accompanist-flowlayout = { module = "com.google.accompanist:accompanist-flowlayout", version.ref = "accompanist" }
accompanist-pager-indicators = { module = "com.google.accompanist:accompanist-pager-indicators", version.ref = "accompanist" }
advrecyclerview = "com.h6ah4i.android.widget.advrecyclerview:advrecyclerview:1.0.0"
android-desugaring = "com.android.tools:desugar_jdk_libs:2.0.3"
Expand Down

0 comments on commit 07e4b5f

Please sign in to comment.