From 0746b7bbe6aa3d9f02e03654a2cd4fde2081c335 Mon Sep 17 00:00:00 2001 From: riku <risaku@163.com> Date: 星期一, 21 四月 2025 09:29:40 +0800 Subject: [PATCH] bug修复 --- miniprogram_npm/tdesign-miniprogram/popup/popup.wxml | 22 ++++++++++++++-------- 1 files changed, 14 insertions(+), 8 deletions(-) diff --git a/miniprogram_npm/tdesign-miniprogram/popup/popup.wxml b/miniprogram_npm/tdesign-miniprogram/popup/popup.wxml index 87cb78d..3bb4b94 100644 --- a/miniprogram_npm/tdesign-miniprogram/popup/popup.wxml +++ b/miniprogram_npm/tdesign-miniprogram/popup/popup.wxml @@ -1,15 +1,18 @@ -<wxs src="./popup.wxs" module="utils" /> +<wxs src="./popup.wxs" module="popup" /> <wxs src="../common/utils.wxs" module="_" /> <view wx:if="{{realVisible}}" - style="{{_._style([utils.getPopupStyles(zIndex), style, customStyle])}}" + style="{{_._style([popup.getPopupStyles(zIndex, distanceTop, placement), style, customStyle])}}" class="{{_.cls(classPrefix, [placement])}} {{transitionClass}} class {{prefix}}-class" bind:transitionend="onTransitionEnd" - aria-role="dialog" - aria-modal="{{ true }}" > - <view class="{{classPrefix}}__content {{prefix}}-class-content"> + <!-- 鏆傛椂绉婚櫎锛歛ria-role="dialog" aria-modal="{{ true }}"锛屽叧鑱旓細https://github.com/Tencent/tdesign-miniprogram/issues/2142 --> + <view + data-prevention="{{preventScrollThrough || (overlayProps ? !!overlayProps.preventScrollThrough : false)}}" + bind:touchmove="{{popup.onContentTouchMove}}" + class="{{classPrefix}}__content {{prefix}}-class-content" + > <slot name="content" /> <slot /> <view class="{{classPrefix}}__close" bind:tap="handleClose"> @@ -23,8 +26,11 @@ id="popup-overlay" wx:if="{{showOverlay}}" visible="{{visible}}" - z-index="{{overlayProps.zIndex || 11000}}" - prevent-scroll-through="{{preventScrollThrough || overlayProps.preventScrollThrough}}" + usingCustomNavbar="{{usingCustomNavbar}}" + z-index="{{overlayProps && overlayProps.zIndex || 11000}}" + duration="{{overlayProps && overlayProps.duration || 300}}" + background-color="{{overlayProps && overlayProps.backgroundColor || ''}}" + prevent-scroll-through="{{preventScrollThrough || (overlayProps ? !!overlayProps.preventScrollThrough : false)}}" bind:tap="handleOverlayClick" - custom-style="{{overlayProps.style || ''}}" + custom-style="{{overlayProps && overlayProps.style || ''}}" /> -- Gitblit v1.9.3