Skip to content

Commit

Permalink
fix: ignore side panel focusout b4 click on safari (#1060)
Browse files Browse the repository at this point in the history
Co-authored-by: Lee Chase <[email protected]>
  • Loading branch information
lee-chase and lee-chase authored Nov 2, 2020
1 parent f380ac6 commit ae9bf76
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ export default {
this.$parent.$emit('cv:panel-focusout', this, ev);
},
onMouseDown(ev) {
if (this.$el === ev.target) {
if (this.$el == ev.target || this.$el.contains(ev.target)) {
// ignore mousedown on panel can cause focus event
ev.preventDefault();
}
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/components/cv-ui-shell/cv-side-nav.vue
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export default {
this.$parent.$emit('cv:panel-focusout', this, ev);
},
onMouseDown(ev) {
if (this.$el === ev.target) {
if (this.$el == ev.target || this.$el.contains(ev.target)) {
// ignore mousedown on panel can cause focus event
ev.preventDefault();
}
Expand Down

0 comments on commit ae9bf76

Please sign in to comment.