Section headers only render their first element
Nobody has claimed this yet.
- Dominant language
- Swift
- Stars
- 330
- Forks
- 76
- Avg merge
- 3h 6m
- Merged PRs (30d)
- 1
Description
In https://github.com/skiptools/skipapp-showcase/blob/main/Sources/Showcase/GridPlayground.swift
private struct LazyVGridSectionedView: View {
var body: some View {
ScrollView {
LazyVGrid(columns: [GridItem(.adaptive(minimum: 80))]) {
ForEach(0..<5) { index in
Section {
VGridCellsView(start: index * 100, count: 10, color: .yellow)
} header: {
Text("Section \(index) Header")
} footer: {
Text("Section footer")
}
.border(.orange)
}
}
}
}
}
Copy and paste Text("Section \(index) Header"), so there are two Text views in the header.
Expected: You should see both views, aligned vertically. (In LazyHGrid, they should be aligned horizontally.)
Actual: Only the first Text view renders.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with Sources/Showcase/GridPlayground.swift in the linked showcase and reproduce the issue by placing two Text views in the Section header. Compare the LazyVGrid and LazyHGrid examples; done means both header views render, vertically aligned in LazyVGrid and horizontally aligned in LazyHGrid.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- swift
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100