From 5036880fc037e5d112206b93a729f60be12bf8ab Mon Sep 17 00:00:00 2001 From: riku <risaku@163.com> Date: 星期四, 07 十一月 2024 17:03:13 +0800 Subject: [PATCH] 2024.11.07 bug修复 --- miniprogram_npm/tdesign-miniprogram/toast/toast.js | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/miniprogram_npm/tdesign-miniprogram/toast/toast.js b/miniprogram_npm/tdesign-miniprogram/toast/toast.js index dbfff03..be660e5 100644 --- a/miniprogram_npm/tdesign-miniprogram/toast/toast.js +++ b/miniprogram_npm/tdesign-miniprogram/toast/toast.js @@ -9,6 +9,7 @@ import props from './props'; import transition from '../mixins/transition'; import { calcIcon } from '../common/utils'; +import useCustomNavbar from '../mixins/using-custom-navbar'; const { prefix } = config; const name = `${prefix}-toast`; let Toast = class Toast extends SuperComponent { @@ -18,7 +19,7 @@ this.options = { multipleSlots: true, }; - this.behaviors = [transition()]; + this.behaviors = [transition(), useCustomNavbar]; this.hideTimer = null; this.data = { prefix, @@ -67,6 +68,8 @@ }, hide() { var _a, _b; + if (!this.data.visible) + return; this.setData({ visible: false }); (_b = (_a = this.data) === null || _a === void 0 ? void 0 : _a.close) === null || _b === void 0 ? void 0 : _b.call(_a); this.triggerEvent('close'); -- Gitblit v1.9.3