Skip to content

Commit

Permalink
Bug-2854067808781568: fix popover and abs layout (#279)
Browse files Browse the repository at this point in the history
* Bug-2854067808781568: fix popover and abs layout

* fix: temp

---------

Co-authored-by: 刘一奇 <[email protected]>
  • Loading branch information
lewis617 and 刘一奇 committed May 8, 2024
1 parent c6d1daa commit 7501d27
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 24 deletions.
8 changes: 4 additions & 4 deletions src/dialog/index.less
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
@import '../style/var';

.van-dialog {
position: fixed;
top: 45%;
left: 50%;
width: @dialog-width;
position: fixed !important;
top: 45% !important;
left: 50% !important;
width: @dialog-width !important;
font-size: @dialog-font-size;

transform: translate3d(-50%, -50%, 0);
Expand Down
40 changes: 20 additions & 20 deletions src/popup/index.less
Original file line number Diff line number Diff line change
Expand Up @@ -6,57 +6,57 @@
}

&-popup {
position: fixed;
position: fixed !important;
max-height: 100%;
overflow-y: auto;
background-color: @popup-background-color;
transition: @popup-transition;
-webkit-overflow-scrolling: touch;

&--center {
top: 50%;
left: 50%;
transform: translate3d(-50%, -50%, 0);
top: 50% !important;
left: 50% !important;
transform: translate3d(-50%, -50%, 0) !important;

&.van-popup--round {
border-radius: @popup-round-border-radius;
}
}

&--top {
top: 0;
left: 0;
width: 100%;
top: 0 !important;
left: 0 !important;
width: 100% !important;

&.van-popup--round {
border-radius: 0 0 @popup-round-border-radius @popup-round-border-radius;
}
}

&--right {
top: 50%;
right: 0;
transform: translate3d(0, -50%, 0);
top: 50% !important;
right: 0 !important;
transform: translate3d(0, -50%, 0) !important;

&.van-popup--round {
border-radius: @popup-round-border-radius 0 0 @popup-round-border-radius;
}
}

&--bottom {
bottom: 0;
left: 0;
width: 100%;
bottom: 0 !important;
left: 0 !important;
width: 100% !important;

&.van-popup--round {
border-radius: @popup-round-border-radius @popup-round-border-radius 0 0;
}
}

&--left {
top: 50%;
left: 0;
transform: translate3d(0, -50%, 0);
top: 50% !important;
left: 0 !important;
transform: translate3d(0, -50%, 0) !important;

&.van-popup--round {
border-radius: 0 @popup-round-border-radius @popup-round-border-radius 0;
Expand Down Expand Up @@ -84,22 +84,22 @@

&-slide-top-enter,
&-slide-top-leave-active {
transform: translate3d(0, -100%, 0);
transform: translate3d(0, -100%, 0) !important;
}

&-slide-right-enter,
&-slide-right-leave-active {
transform: translate3d(100%, -50%, 0);
transform: translate3d(100%, -50%, 0) !important;
}

&-slide-bottom-enter,
&-slide-bottom-leave-active {
transform: translate3d(0, 100%, 0);
transform: translate3d(0, 100%, 0) !important;
}

&-slide-left-enter,
&-slide-left-leave-active {
transform: translate3d(-100%, -50%, 0);
transform: translate3d(-100%, -50%, 0) !important;
}

&__close-icon {
Expand Down

0 comments on commit 7501d27

Please sign in to comment.