Close the sliding panel if expanded or anchored