Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 89ffd1fd authored by Caitlin Shkuratov's avatar Caitlin Shkuratov Committed by Android (Google) Code Review
Browse files

Merge "[SB][Chips] Only compose the chips if we have chips to show." into main

parents b726153a a3941ec1
Loading
Loading
Loading
Loading
+13 −12
Original line number Diff line number Diff line
@@ -36,6 +36,8 @@ fun OngoingActivityChips(
    iconViewStore: NotificationIconContainerViewBinder.IconViewStore?,
    modifier: Modifier = Modifier,
) {
    val shownChips = chips.active.filter { !it.isHidden }
    if (shownChips.isNotEmpty()) {
        Row(
            modifier =
                modifier
@@ -45,9 +47,7 @@ fun OngoingActivityChips(
            horizontalArrangement =
                Arrangement.spacedBy(dimensionResource(R.dimen.ongoing_activity_chip_margin_start)),
        ) {
        chips.active
            .filter { !it.isHidden }
            .forEach {
            shownChips.forEach {
                key(it.key) {
                    OngoingActivityChip(
                        model = it,
@@ -58,3 +58,4 @@ fun OngoingActivityChips(
            }
        }
    }
}