skiptools / skiptools/skip-ui

ScrollView doesn't scroll all contents when it contains LazyVGrid

Open
#138 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

compose
Dominant language
Swift
Stars
330
Forks
76
Avg merge
3h 6m
Merged PRs (30d)
1

Description

Hey, I've noticed that ScrollView doesn't scroll all items inside of it when it contains LazyVGrid and only scrolls the grid on Android, iOS is working fine.

e.g

public struct ContentView: View {
    public var body: some View {
        ScrollView {
            Text("Title Text")
            LazyVGrid(columns: [GridItem(.adaptive(minimum: 100))], spacing: 6) {
                ForEach(0..<200) { i in
                    Button("\(i)") {
                        print(i)
                    }
                }
            }
        }
    }
}
Image

Any ideas how to fix this? I want to create a view with some scrollable items on the top and after that have the LazyVGrid

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the example with ScrollView, LazyVGrid, and 200 items on Android, then compare its behavior with iOS. Trace the Android implementations of those entry points and verify that scrolling reaches every grid item; done means the full grid scrolls while preserving the surrounding title and layout.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.