don't deselect radio buttons in data-toggle

Incorporates the code from PR 10787 and the test from PR 10385