Selection was jumping around after clicking the collapse toggle button