11
11
{{ typeof progress === 'number' ? Math.round(progress * 100) : 0 }}
12
12
</div >
13
13
14
+ <transition duration =" 500" >
15
+ <div v-if =" status === 'Success'" class =" status-icon done" >
16
+ <div class =" wrapper" >
17
+ <VueIcon icon =" check_circle" />
18
+ </div >
19
+ </div >
20
+ </transition >
21
+
22
+ <transition duration =" 500" >
23
+ <div v-if =" status === 'Failed'" class =" status-icon error" >
24
+ <div class =" wrapper" >
25
+ <VueIcon icon =" error" />
26
+ </div >
27
+ </div >
28
+ </transition >
29
+
14
30
<div class =" operations" >
15
31
<span v-if =" operations" >{{ operations }}</span >
16
32
<VueIcon
@@ -35,6 +51,7 @@ export default {
35
51
36
52
sharedData () {
37
53
return mapSharedData (' webpack-dashboard-' , {
54
+ status: ` ${ this .mode } -status` ,
38
55
progress: ` ${ this .mode } -progress` ,
39
56
operations: ` ${ this .mode } -operations`
40
57
})
@@ -65,7 +82,8 @@ export default {
65
82
& :first -letter
66
83
text-transform uppercase
67
84
68
- .progress
85
+ .progress ,
86
+ .status-icon
69
87
h-box ()
70
88
box-center ()
71
89
flex none
@@ -74,7 +92,68 @@ export default {
74
92
left 0
75
93
width 100%
76
94
height 178px
95
+
96
+ .progress
77
97
color lighten ($vue-ui-color-dark , 60% )
78
98
font-weight lighter
79
99
font-size 42px
100
+
101
+ .status-icon
102
+ .wrapper
103
+ position relative
104
+ .vue-ui-icon
105
+ width 64px
106
+ height @width
107
+ position relative
108
+ z-index 2
109
+ display block
110
+ & ::before ,
111
+ & ::after
112
+ display block
113
+ content ''
114
+ border-radius 50%
115
+ position absolute
116
+ & ::before
117
+ top - 36px
118
+ left @top
119
+ width 136px
120
+ height @width
121
+ & ::after
122
+ background white
123
+ top 7px
124
+ left @top
125
+ width 50px
126
+ height @width
127
+ z-index 1
128
+ & .done
129
+ .wrapper ::before
130
+ background $vue-ui-color-success
131
+ >>> svg
132
+ fill $vue-ui-color-success
133
+ & .error
134
+ .wrapper ::before
135
+ background $vue-ui-color-danger
136
+ >>> svg
137
+ fill $vue-ui-color-danger
138
+ & .v-enter-active ,
139
+ & .v-leave-active
140
+ transition transform .5s cubic-bezier (0 , 1 , .3 , 1 ), opacity .2s
141
+ .wrapper ::after
142
+ transition opacity .2s
143
+ .vue-ui-icon
144
+ transition visibility 0
145
+ & .v-enter-active
146
+ .wrapper ::after ,
147
+ .vue-ui-icon
148
+ transition-delay .3s
149
+ & .v-enter ,
150
+ & .v-leave-to
151
+ transform scale (0 )
152
+ .wrapper ::after
153
+ opacity 0
154
+ & .v-enter
155
+ .vue-ui-icon
156
+ visibility hidden
157
+ & .v-leave-to
158
+ opacity 0
80
159
</style >
0 commit comments