Skip to content

Commit

Permalink
add notes
Browse files Browse the repository at this point in the history
  • Loading branch information
cl199793 committed Sep 9, 2019
1 parent b8a6077 commit 73f9e34
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/image/src/image-viewer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,8 @@ export default {
},
mounted() {
this.deviceSupportInstall();
// add tabindex then wrapper can be focusable via Javascript
// focus wrapper so arrow key can't cause inner scroll behavior underneath
this.$refs['el-image-viewer__wrapper'].focus();
}
};
Expand Down
1 change: 1 addition & 0 deletions packages/image/src/main.vue
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@
}
},
clickHandler() {
// prevent body scroll
prevOverflow = document.body.style.overflow;
document.body.style.overflow = 'hidden';
this.showViewer = true;
Expand Down

0 comments on commit 73f9e34

Please sign in to comment.