我正在尝试做一个 SegmentedRow。在每个部分中,都有 TextRows。这些 TextRows 在数量上是动态的。我试过了:
+++ Section()
<<< SegmentedRow<String>("segments"){
$0.options = ["Assets", "Notes", "Photos"]
$0.value = "Assets"
}
+++ Section(){
$0.tag = "assets_s"
$0.hidden = "$segments != 'Assets'" // .Predicate(NSPredicate(format: "$segments != 'Sport'"))
}
for t in myarray{
<<< TextRow(){
$0.title = "Which is your favourite soccer player?"
}
}
我尝试将 for 循环放在那里,但在随后的行中出现错误。