Post

Replies

Boosts

Views

Activity

Lists onMove works os on iPadOS but not in iOS
Can't make onMove to work on iOS, it is just not triggered. Is this an iOS bug or I'm missing something? On the iPad is working like a charm.        List{         ForEach(names, id: \.self) {name in           Text(name)         }.onMove(perform: { indices, newOffset in           names.move(fromOffsets: indices, toOffset: newOffset)         })       } Thanks!
2
1
1.8k
Aug ’20
Spacer not working correctly inside Toolbar?
I have a toolbar in which I want to place two buttons in leading and trailing positions, inside an HStack. When adding a Spacer the buttons are no longer visible. Without the Spacer it works (with the buttons being centred in the HStack) Am I doing something wrong? Text("Any View")       .toolbar {         ToolbarItem(placement: .bottomBar) {           HStack {             Spacer()             Button(action: {}, label: {               Text("Backlog")             })             Button(action: {}, label: {               Text("Add New")             })           }         }       }
2
0
2.1k
Jul ’20