-
Notifications
You must be signed in to change notification settings - Fork 53
/
react-video.css
104 lines (104 loc) · 1.79 KB
/
react-video.css
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
/*
* React Video - React component to load video from Vimeo or Youtube across any device
* @version v1.5.3
* @link https://github.com/pedronauck/react-video
* @license MIT
* @author Pedro Nauck (https://github.com/pedronauck)
*/
.video-image,
.video-image:after,
.video-embed {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
.video {
position: relative;
padding-bottom: 56.25%;
background: #e2e2e2;
}
.video iframe {
border: 0;
}
.video-image {
background-position: center center;
background-size: 100% auto;
}
.video-image:after {
z-index: 1;
display: block;
content: '';
background: rgba(0,0,0,0.3);
}
.video-play-button,
.video-loading {
top: 50%;
left: 50%;
transform: translateX(-50%) translateY(-50%);
}
.video-play-button {
z-index: 2;
position: absolute;
padding: 0;
width: 70px;
border: 0;
background: none;
}
.video-play-button:focus {
outline: none;
}
.video-play-button svg {
fill: #fff;
-webkit-filter: drop-shadow(0 1px 1px rgba(0,0,0,0.8));
filter: drop-shadow(0 1px 1px rgba(0,0,0,0.8));
}
.video-loading {
z-index: 4;
position: absolute;
width: 32px;
height: 32px;
}
.video-loading svg {
fill: #000;
transform-origin: 50% 50%;
-webkit-animation: spinner 0.8s infinite linear;
animation: spinner 0.8s infinite linear;
}
.video-embed iframe {
width: 100%;
height: 100%;
}
@-moz-keyframes spinner {
from {
transform: rotate(0deg);
}
to {
transform: rotate(360deg);
}
}
@-webkit-keyframes spinner {
from {
transform: rotate(0deg);
}
to {
transform: rotate(360deg);
}
}
@-o-keyframes spinner {
from {
transform: rotate(0deg);
}
to {
transform: rotate(360deg);
}
}
@keyframes spinner {
from {
transform: rotate(0deg);
}
to {
transform: rotate(360deg);
}
}