mirror of
https://github.com/prurigro/hypothetical.git
synced 2024-11-21 23:52:31 -05:00
Unfocus focused elements before changing the page to reset the tab order
This commit is contained in:
parent
9f8e83624a
commit
8dfb92fd2a
1 changed files with 5 additions and 0 deletions
5
resources/assets/js/app.js
vendored
5
resources/assets/js/app.js
vendored
|
@ -116,6 +116,11 @@ router.beforeEach((to, from, next) => {
|
||||||
if (store.getters.getFirstLoad) {
|
if (store.getters.getFirstLoad) {
|
||||||
next();
|
next();
|
||||||
} else {
|
} else {
|
||||||
|
// Unfocused any focused elements
|
||||||
|
if ("activeElement" in document) {
|
||||||
|
document.activeElement.blur();
|
||||||
|
}
|
||||||
|
|
||||||
// Fade the page out and scroll when moving from one page to another
|
// Fade the page out and scroll when moving from one page to another
|
||||||
TweenMax.to("#router-view", 0.25, {
|
TweenMax.to("#router-view", 0.25, {
|
||||||
opacity: 0,
|
opacity: 0,
|
||||||
|
|
Loading…
Reference in a new issue