Skip to content

Commit 933db6f

Browse files
committed
fix(core): fix issue with custom page transitions
1 parent c556300 commit 933db6f

File tree

3 files changed

+41
-24
lines changed

3 files changed

+41
-24
lines changed

src/core/components/page/page-transitions/circle.less

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,22 +20,28 @@
2020
border-radius: 50%;
2121
animation: f7-circle-circle-in 400ms forwards;
2222
}
23-
.page-next {
24-
opacity: 0 !important;
25-
transform: scale(0.9) !important;
26-
animation: f7-circle-next-to-current 300ms forwards;
27-
animation-delay: 300ms;
28-
z-index: 150;
23+
.ios &,
24+
.md & {
25+
.page-next {
26+
opacity: 0;
27+
transform: scale(0.9);
28+
animation: f7-circle-next-to-current 300ms forwards;
29+
animation-delay: 300ms;
30+
z-index: 150;
31+
}
2932
}
3033
}
3134
.router-transition-f7-circle-backward {
3235
&:after {
3336
animation: f7-circle-circle-out 300ms forwards;
3437
animation-delay: 350ms;
3538
}
36-
.page-current {
37-
animation: f7-circle-current-to-next 700ms forwards;
38-
z-index: 150;
39+
.ios &,
40+
.md & {
41+
.page-current {
42+
animation: f7-circle-current-to-next 700ms forwards;
43+
z-index: 150;
44+
}
3945
}
4046
}
4147
@keyframes f7-circle-circle-in {

src/core/components/page/page-transitions/fade.less

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,26 @@
44
background: var(--f7-page-bg-color);
55
}
66
.router-transition-f7-fade-forward {
7-
.page-next {
8-
opacity: 0 !important;
9-
animation: f7-fade-in var(--f7-page-fade-transition-duration) forwards;
10-
}
11-
.page-current {
12-
animation: f7-fade-out var(--f7-page-fade-transition-duration) forwards;
7+
.ios &,
8+
.md & {
9+
.page-next {
10+
opacity: 0;
11+
animation: f7-fade-in var(--f7-page-fade-transition-duration) forwards;
12+
}
13+
.page-current {
14+
animation: f7-fade-out var(--f7-page-fade-transition-duration) forwards;
15+
}
1316
}
1417
}
1518
.router-transition-f7-fade-backward {
16-
.page-current {
17-
animation: f7-fade-out var(--f7-page-fade-transition-duration) forwards;
18-
}
19-
.page-previous {
20-
animation: f7-fade-in var(--f7-page-fade-transition-duration) forwards;
19+
.ios &,
20+
.md & {
21+
.page-current {
22+
animation: f7-fade-out var(--f7-page-fade-transition-duration) forwards;
23+
}
24+
.page-previous {
25+
animation: f7-fade-in var(--f7-page-fade-transition-duration) forwards;
26+
}
2127
}
2228
}
2329
@keyframes f7-fade-in {

src/core/components/page/page-transitions/flip.less

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,27 +5,32 @@
55
perspective: 1200px;
66
.page {
77
backface-visibility: hidden;
8+
overflow: hidden;
89
}
910
}
1011
.router-transition-f7-flip-forward {
1112
.page-next {
13+
transform-style: preserve-3d;
1214
animation: f7-flip-next-to-current var(--f7-page-flip-transition-duration) forwards;
1315
}
1416
.page-current {
17+
transform-style: preserve-3d;
1518
animation: f7-flip-current-to-prev var(--f7-page-flip-transition-duration) forwards;
1619
}
1720
}
1821
.router-transition-f7-flip-backward {
1922
.page-current {
23+
transform-style: preserve-3d;
2024
animation: f7-flip-current-to-next var(--f7-page-flip-transition-duration) forwards;
2125
}
2226
.page-previous {
27+
transform-style: preserve-3d;
2328
animation: f7-flip-prev-to-current var(--f7-page-flip-transition-duration) forwards;
2429
}
2530
}
2631
@keyframes f7-flip-next-to-current {
2732
from {
28-
border-radius: 30px;
33+
border-radius: 32px;
2934
.ltr({
3035
transform: translateZ(-100vmax) rotateY(180deg);
3136
});
@@ -44,7 +49,7 @@
4449
transform: translateZ(0px) rotateY(0deg);
4550
}
4651
to {
47-
border-radius: 30px;
52+
border-radius: 32px;
4853
.ltr({
4954
transform: translateZ(-100vmax) rotateY(180deg);
5055
});
@@ -59,7 +64,7 @@
5964
transform: translateZ(0px) rotateY(0deg);
6065
}
6166
to {
62-
border-radius: 30px;
67+
border-radius: 32px;
6368
.ltr({
6469
transform: translateZ(-100vmax) rotateY(-180deg);
6570
});
@@ -70,7 +75,7 @@
7075
}
7176
@keyframes f7-flip-prev-to-current {
7277
from {
73-
border-radius: 30px;
78+
border-radius: 32px;
7479
.ltr({
7580
transform: translateZ(-100vmax) rotateY(-180deg);
7681
});

0 commit comments

Comments
 (0)