소스 검색

fix: 移除菜单选中动画 可能会引发卡顿

xyh 2 년 전
부모
커밋
98e377f83c
1개의 변경된 파일3개의 추가작업 그리고 11개의 파일을 삭제
  1. 3 11
      packages/app/src/styles/antd.css

+ 3 - 11
packages/app/src/styles/antd.css

@@ -25,25 +25,17 @@
   border-radius: unset !important;
 }
 
-.ant-menu-item {
+.ant-menu-item-selected {
   position: relative;
 
   &::before {
     position: absolute;
-    top: 50%;
+    top: 0;
     right: 0;
-    bottom: 50%;
+    bottom: 0;
     width: 4px;
     content: '';
     background: var(--primary-color);
-    transition: top 150ms ease-in-out, bottom 150ms ease-in-out;
-  }
-}
-
-.ant-menu-item-selected {
-  &::before {
-    top: 0;
-    bottom: 0;
   }
 }