swap method
Opens the panel if it's currently closed, or closes the panel if it's currently open
Implementation
void swap({double velocity = 1.0}) {
if (isOpen) {
close(velocity: velocity);
} else if (isClosed) {
open(velocity: velocity);
}
}