mounted() {
    document.addEventListener("click", (e) => {
      let that = this
      if (!this.$el.contains(e.target)) {
        that.videoShow = false; //点击其他区域关闭
      } else {
        that.videoShow = true;
      }
    });
  },
Logo

前往低代码交流专区

更多推荐