Skip to content
This repository has been archived by the owner on Jun 3, 2021. It is now read-only.

Commit

Permalink
Merge pull request #505 from ReedSun/wxc-mask-bug-fix
Browse files Browse the repository at this point in the history
[!] wxc-mask: fix bug that inconsistent behavior between clicking close button and clicking overlay
  • Loading branch information
tw93 authored Oct 26, 2020
2 parents 19a7859 + e2ba3e6 commit 06a5fe0
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions packages/wxc-mask/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ under the License.

<template>
<div class="container">
<wxc-overlay :show="show && hasOverlay"
<wxc-overlay ref="overlay"
:show="show && hasOverlay"
v-if="show"
v-bind="mergeOverlayCfg"
:can-auto-close="overlayCanClose"
Expand Down Expand Up @@ -191,7 +192,10 @@ under the License.
},
methods: {
closeIconClicked () {
this.appearMask(false);
this.$refs.overlay.appearOverlay(false);
if (!this.overlayCanClose) {
this.appearMask(false);
}
},
wxcOverlayBodyClicking () {
if (this.hasAnimation) {
Expand Down

0 comments on commit 06a5fe0

Please sign in to comment.