-
Notifications
You must be signed in to change notification settings - Fork 1
/
App4.vue
105 lines (91 loc) · 1.61 KB
/
App4.vue
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
<template>
<div class="root-container">
<router-view v-slot="{ Component }">
<sk-transition name='slide-left' back_name='slide-right'>
<stack-keep-alive v-slot="{ key }">
<component :is="Component" :key='key'/>
</stack-keep-alive>
</sk-transition>
</router-view>
</div>
</template>
<script>
</script>
<style>
#app {
font-family: Avenir, Helvetica, Arial, sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-align: center;
color: #2c3e50;
}
#nav {
padding: 30px;
}
#nav a {
font-weight: bold;
color: #2c3e50;
}
#nav a.router-link-exact-active {
color: #42b983;
}
.root-container {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
}
* {
margin: 0;
padding: 0;
}
html,
body {
width: 100%;
height: 100%;
}
html {
height: 100%;
}
body {
height: inherit;
padding: 0;
margin: 0;
}
.app {
width: 100%;
height: 100%;
overflow: hidden;
}
.slide-right-enter-active,
.slide-right-leave-active,
.slide-left-enter-active,
.slide-left-leave-active {
will-change: transform;
transition: transform 350ms;
position: fixed;
pointer-events: none;
width: 100%;
height: 100%;
}
.slide-left-enter-active,
.slide-right-leave-active {
z-index: 99;
}
.slide-right-enter-from {
z-index: 1;
transform: translate3d(-100%, 0, 0);
}
.slide-right-leave-active {
transition-delay: 100ms;
transform: translate3d(100%, 0, 0);
}
.slide-left-enter-from {
transform: translate3d(100%, 0, 0);
}
.slide-left-leave-active {
transition-delay: 100ms;
transform: translate3d(-100%, 0, 0);
}
</style>