Post

Replies

Boosts

Views

Activity

How to change the color and symbol of a Reorder icon in editable List?
I have an editable List which items can be re-ordered. I want to change the Reorder icon color and symbol. How to do that? struct DummyList: View { @State private var items = ["item 1", "item 2", "item 3"] @State private var editMode = EditMode.active var body: some View { List { ForEach(items, id: \.self) { item in Text(item) } .onMove(perform: move) } .toolbar { EditButton() } .environment(\.editMode, $editMode) } func move(from source: IndexSet, to destination: Int) { items.move(fromOffsets: source, toOffset: destination) } }
0
0
387
Aug ’23