-
Notifications
You must be signed in to change notification settings - Fork 28
/
example.html
93 lines (88 loc) · 2.67 KB
/
example.html
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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>Cassette</title>
<link rel="stylesheet" href="dist/css/cassette-player.css">
<style>
html,
body {
margin: 0;
background: gold;
}
#media_player_container {
width: 500px;
margin: 1rem;
max-width: calc(100% - 2rem);
}
.demo {
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}
.header {
margin: 2rem;
color: #222;
font-size: 42px;
}
.source {
margin-top: 2rem;
margin-left: 2.6rem;
margin-right: 1rem;
font-style: italic;
font-size: 18px;
}
.mute_message {
margin-left: 2.6rem;
margin-right: 1rem;
}
.mute_message.hidden {
display: none;
}
.video_display {
height: 250px;
border: 1px solid #333;
margin-left: 2rem;
}
@media (max-width: 330px) {
.cassette__shuffle_btn {
display: none;
}
}
@media (max-width: 400px) {
.cassette__repeat_btn {
display: none;
}
}
</style>
</head>
<body>
<main class="demo">
<h1 class="header">Cassette</h1>
<div id="media_player_container"></div>
</main>
<script src="https://unpkg.com/react@16.3.0/umd/react.development.js"></script>
<script src="https://unpkg.com/react-dom@16.3.0/umd/react-dom.development.js"></script>
<script src="https://unpkg.com/prop-types/prop-types.js"></script>
<script src="https://unpkg.com/resize-observer-polyfill"></script>
<script type="module" src="dist/esm/cassette-core.js"></script>
<script nomodule src="dist/es5/cassette-core.js"></script>
<script type="module" src="dist/esm/cassette-components.js"></script>
<script nomodule src="dist/es5/cassette-components.js"></script>
<script type="module" src="dist/esm/cassette-player.js"></script>
<script nomodule src="dist/es5/cassette-player.js"></script>
<script src="example/playlist.js"></script>
<script src="example/ExampleApp.js"></script>
<script src="example/ExamplePlayerContextProvider.js"></script>
<script src="example/ExampleMediaPlayer.js"></script>
<script src="example/ExampleMediaInfo.js"></script>
<script src="example/ExampleMuteMessage.js"></script>
<script>
window.onload = function() {
ReactDOM.render(
React.createElement(ExampleApp, { playlist: playlist }),
document.getElementById('media_player_container')
);
}
</script>
</body>
</html>