Created
June 10, 2024 20:57
-
-
Save arriolac/a4573c062a1352cb2dbd08ce85372d09 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Copyright 2023 Google LLC. | |
// SPDX-License-Identifier: Apache-2.0 | |
@Composable | |
private fun HomeContentGrid(/* ... */) { | |
LazyVerticalGrid( | |
// Adapt number of columns wherein each column has at least 362.dp of space | |
columns = GridCells.Adaptive(362.dp), | |
modifier = modifier.fillMaxSize() | |
) { | |
if (featuredPodcasts.isNotEmpty()) { | |
item(span = { GridItemSpan(this.maxLineSpan) }) { | |
FollowedPodcastItem( | |
pagerState = pagerState, | |
items = featuredPodcasts, | |
onPodcastUnfollowed = onPodcastUnfollowed, | |
navigateToPodcastDetails = navigateToPodcastDetails, | |
modifier = Modifier | |
.fillMaxWidth() | |
) | |
} | |
} | |
// Additional Grid items here | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment