Commit 1e8fab3fe5dcac78e9d2c53682527259234f95ce
Committed by
GitHub
1 parent
7e0456cc
perf: 优化modal弹窗样式 (#2824)
Showing
1 changed file
with
8 additions
and
8 deletions
src/components/Modal/src/index.less
... | ... | @@ -2,10 +2,7 @@ |
2 | 2 | overflow: hidden; |
3 | 3 | |
4 | 4 | .ant-modal { |
5 | - top: 0 !important; | |
6 | - right: 0 !important; | |
7 | - bottom: 0 !important; | |
8 | - left: 0 !important; | |
5 | + inset: 0 !important; | |
9 | 6 | width: 100% !important; |
10 | 7 | height: 100%; |
11 | 8 | |
... | ... | @@ -63,8 +60,8 @@ |
63 | 60 | } |
64 | 61 | |
65 | 62 | &-close { |
66 | - font-weight: normal; | |
67 | 63 | outline: none; |
64 | + font-weight: normal; | |
68 | 65 | } |
69 | 66 | |
70 | 67 | &-close-x { |
... | ... | @@ -110,17 +107,20 @@ |
110 | 107 | .ant-modal-confirm .ant-modal-body { |
111 | 108 | padding: 24px !important; |
112 | 109 | } |
113 | -@media screen and (max-height: 600px) { | |
110 | + | |
111 | +@media screen and (height <= 600px) { | |
114 | 112 | .ant-modal { |
115 | 113 | top: 60px; |
116 | 114 | } |
117 | 115 | } |
118 | -@media screen and (max-height: 540px) { | |
116 | + | |
117 | +@media screen and (height <= 540px) { | |
119 | 118 | .ant-modal { |
120 | 119 | top: 30px; |
121 | 120 | } |
122 | 121 | } |
123 | -@media screen and (max-height: 480px) { | |
122 | + | |
123 | +@media screen and (height <= 480px) { | |
124 | 124 | .ant-modal { |
125 | 125 | top: 10px; |
126 | 126 | } | ... | ... |