瀏覽代碼

feat: 优化动画展示

year 2 天之前
父節點
當前提交
926bfb3895
共有 2 個文件被更改,包括 3 次插入4 次删除
  1. 2 2
      src/feedback/WrapHoc/index.tsx
  2. 1 2
      src/feedback/dialog/component.module.scss

+ 2 - 2
src/feedback/WrapHoc/index.tsx

@@ -35,10 +35,10 @@ const WrapHoc: React.FC<Props> = ({
         if (animateTime) {
             setTimeout(() => {
                 setMaskVisible(false);
-            }, animateTime - 100);
+            }, animateTime);
             setTimeout(() => {
                 doClose(resData);
-            }, animateTime);
+            }, animateTime + 50);
             return;
         }
         setMaskVisible(false);

+ 1 - 2
src/feedback/dialog/component.module.scss

@@ -5,11 +5,10 @@
     position: relative;
     transform: translateY(-50px) scale(0.98);
     transition: all 0.2s ease-in-out;
-    opacity: 0.2;
+    opacity: 0;
     &.bottom {
         transform: translateY(100%) scale(1);
     }
-
     &.showed {
         transform: translateY(0) scale(1);
         opacity: 1;