chore(variable/modal): close variable modal dialog on location change