list may accept any iterable

This commit is contained in:
InsanusMokrassar 2022-11-16 00:45:10 +06:00
parent 0c281aa653
commit eefdb5fda1

View File

@ -10,7 +10,7 @@ import org.w3c.dom.HTMLUListElement
@Composable @Composable
fun <T> List( fun <T> List(
data: SnapshotStateList<T>, data: Iterable<T>,
ukAttrs: Attrs<HTMLUListElement> = Attrs.empty(), ukAttrs: Attrs<HTMLUListElement> = Attrs.empty(),
elementAllocator: @Composable ElementScope<HTMLUListElement>.(T) -> Unit elementAllocator: @Composable ElementScope<HTMLUListElement>.(T) -> Unit
) { ) {
@ -29,7 +29,7 @@ fun <T> List(
@Composable @Composable
fun <T> ListWithTitle( fun <T> ListWithTitle(
title: String, title: String,
data: SnapshotStateList<T>, data: Iterable<T>,
vararg titleModifiers: UIKitModifier, vararg titleModifiers: UIKitModifier,
ulModifiers: Array<UIKitModifier> = emptyArray(), ulModifiers: Array<UIKitModifier> = emptyArray(),
besidesTitleAndList: (@Composable () -> Unit)? = null, besidesTitleAndList: (@Composable () -> Unit)? = null,