54 questions
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
0
votes
1
answer
174
views
Buggy ScrollView + LazyVStack animation - is it fixable?
The following code will render a list of items and a button to shuffle them and change their height withAnimation.
If you scroll down and shuffle it you will eventually see glitches in the animation, ...
0
votes
1
answer
254
views
Multiple pinned views at the top of a LazyVStack within a ScrollView
I am trying to create a ScrollView with a LazyVStack where two headers are pinned at the top. It should also work within a NavigationStack using large display mode for the title. Both headers should ...
1
vote
0
answers
71
views
How can I scroll a ScrollView to a view nested arbitrarily deeply in a LazyVStack?
I want to set the scroll position of a ScrollView containing a LazyVStack such that it shows a view nested arbitrarily deeply within that stack.
Currently I give the view which should be scrolled to ...
0
votes
1
answer
572
views
Double sticky header in SwiftUI
Here's a full code example of an attempt at a double sticky header view:
struct ContentView: View {
var body: some View {
ScrollView(showsIndicators: false) {
LazyVStack(...
0
votes
0
answers
81
views
Why does LazyVStack footer stutter when section height exceeds screen frame in SwiftUI?
I am having some issues with sticky footers on PinnedScrollableViews in SwiftUI for iOS. I am working on a LazyVStack embedded in a ScrollView with footers on each section of the LazyVStack. The size ...
1
vote
2
answers
278
views
Why doesn't LazyVStack release memory when scrolling
I have a `PhotosPicker` that selects an image. Then, upon pressing the "Save" button, I save it in `FileManager` and store its path in `CoreData`. When I need to retrieve them, I use a `...
0
votes
1
answer
172
views
Update on Parent View list from Child view using SwiftData
My problem is with SwiftData not updating the object which is used with @Query. here are my code
This is my View which used to show list of books,
struct ReadingView: View {
@Environment(\....
0
votes
0
answers
400
views
SwiftUI ScrollView has weird behavior when reseting the content
I'm working with SwiftUI and trying to do a ScrollView that can be filtered (it's basically a list).
The stack looks like this:
class ViewModel: ObservableObject {
@Published
var isRefreshing =...
1
vote
0
answers
221
views
How do I write my own SwiftUI ScrollView that will respect a lazy subview?
I am trying to write my own MyScrollView to manage scroll. I am doing this because I want to have a LazyVStack with items that have varying heights and for which I can scroll to any item inside. So, ...
1
vote
0
answers
225
views
SwiftUI - zIndex change not working for item inside of LazyVStack
I have problem with zIndex in my app with collection of images
I've added pinch zoom to the image, but when image is zoomed it does not get on top of other images which are next in the collection.
...
3
votes
1
answer
1k
views
Keyboard is immediately hidden when focus TextField in LazyVStack (SwiftUI)
I have a stack of cards, each card having a TextField, when focus a text field positioned at the bottom of the screen (on the area where the keyboard will appear) the card disappears, thus the ...
2
votes
1
answer
2k
views
SwiftUI ScrollViewReader scrollTo doesn't fully scroll to element when using LazyVStack with pinned sectionHeaders
I'm trying to create sticky header with manual scroll to functionality (eg. categories bar allowing user to move to chosen section). I have issues with one part of that functionallity. While ...
1
vote
1
answer
773
views
Get current item in LazyVstack inside scrollview when scroll ends
I want to print the currently displayed item in LazyVStack which is inside scrollview with paging enabled.
i have tried printing in onAppear of VerseView
The issues with printing inside onAppear are-
...
3
votes
3
answers
1k
views
scroll indicator incosistent and stutters with LazyVStack
I use LazyVStack because I need to load a big list of elements, LazyVStack helps with loading fewer elements, hence the scroll bar/indicator does not know the real size of the list, causing ...
0
votes
0
answers
217
views
SwiftUI: ViewModifier together with id() on a cell causes ScrollView performance issues
There is very poor performance when pulling scroll bar indicator to bottom and scrolling cells with big ordinal numbers. But if we comment empty ViewModifier applied to cell, everything became ok.
...