-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME.md
73 lines (56 loc) · 1.36 KB
/
README.md
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
# Master Video
[](https://www.npmjs.com/package/master-video) [](https://discord.gg/Z6vgXHU2xQ)
a React Video Player
## Install
```fish
npm install --save master-video
```
## Useage
JavaScript:
```js
import MasterVideo from 'master-video'
import video from 'video.mp4'
const Options = {
loop: true,
masterClass: 'custom-class-name',
iconsColor: '#0f0',
playIconColor: '#0ff',
fullscreenIconColor: '#ff0',
volumeIconColor: '#fff',
timeLine: {
track: '#f00',
thumb: '#0f0',
rail: '#00f',
},
volume: {
rail: '#FFF',
thumb: '#f00',
track: '#00f',
},
}
const App = () => {
return (
<div className='app'>
<MasterVideo
options={Options}
source={video}
/>
</div>
)
}
```
TypeScript:
```tsx
import MasterVideo, { Options } from 'master-video'
const video = 'https://example.com/video.mp4'
const Options: Options = {
loop: true
}
const App = () => {
return (
<div className='app'>
<MasterVideo source={video} options={Options} />
</div>
)
}
```