-
Notifications
You must be signed in to change notification settings - Fork 3
/
index.html
200 lines (184 loc) · 8.92 KB
/
index.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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta charset="UTF-8">
<!--webaudio polyfills-->
<script type="text/javascript" src="js/get-float-time-domain-data.min.js"></script>
<script type="text/javascript" src="js/audioworklet-polyfill.js"></script>
<!--some usefull js stuff-->
<script type="text/javascript" src="js/utils.js"></script>
<script type="text/javascript" src="js/modplayer.js"></script>
<script type="text/javascript" src="js/main.js"></script>
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
<link rel="stylesheet" href="https://code.getmdl.io/1.3.0/material.indigo-deep_purple.min.css">
<style type="text/css">
/* mdl */
.page-content {
display: flex;
justify-content: center;
padding: 40px;
}
a.mdl-navigation__link.selected:before {
font-family: 'Material Icons';
font-weight: 400;
font-style: normal;
font-size: 24px;
line-height: 24px;
letter-spacing: normal;
text-transform: none;
display: inline-block;
word-wrap: normal;
content: 'volume_up';
height: 18px;
color: black;
position: absolute;
left: 11px;
}
.mdl-mini-footer {
justify-content: center;
}
.mdl-card__title h2 {
color: black;
cursor:pointer;
width:95%;
}
.mdl-card__title h2 .title-container{
flex-grow:1;
}
.mdl-card__title h2 span.title{
display:inline-block;
width: 90%;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.mdl-layout__drawer .mdl-navigation .mdl-navigation__link.selected {
padding-left: 40px;
}
.mdl-mini-footer--link-list li, .mdl-mini-footer__link-list li{
margin: 0 16px;
}
.author{
font-style:italic;
}
canvas{
width:100%;
height:100px;
cursor:pointer;
}
</style>
<script defer src="https://code.getmdl.io/1.3.0/material.min.js"></script>
</head>
<body>
<!-- Always shows a header, even in smaller screens. -->
<div class="mdl-layout mdl-js-layout mdl-layout--fixed-header">
<header class="mdl-layout__header">
<div class="mdl-layout__header-row">
<!-- Title -->
<span class="mdl-layout-title">Modplayer-js</span>
<!-- Add spacer, to align navigation to the right -->
<div class="mdl-layout-spacer"></div>
<!-- Navigation. We hide it in small screens. -->
<nav class="mdl-navigation controls">
<!-- <a class="mdl-navigation__link mdl-navigation__link--icon github" href="https://github.com/warpdesign/modplayer-js"><i class="material-icons">link</i><span>GitHub</span></a> -->
<button class="mdl-button mdl-js-button mdl-button--icon play" style="display:none;" onclick="togglePlay()">
<i class="material-icons">play_arrow</i>
</button>
<button class="mdl-button mdl-js-button mdl-button--icon play" style="display:none;" onclick="stop()">
<i class="material-icons">stop</i>
</button>
<div id="loader" class="mdl-spinner mdl-js-spinner is-active"></div>
</nav>
</div>
</header>
<div class="mdl-layout__drawer">
<span class="mdl-layout-title">Choose Module</span>
<nav class="mdl-navigation nav-module">
</nav>
</div>
<main class="mdl-layout__content">
<div class="page-content">
<!-- Wide card with share menu button -->
<style>
.demo-card-wide.mdl-card {
width: 512px;
position:relative;
}
.demo-card-wide>.mdl-card__title {
color: #fff;
height: 196px;
/* Permalink - use to edit and share this gradient: http://colorzilla.com/gradient-editor/#2c2c2c+1,000000+9,2b2b2b+50,bababa+54,ffffff+100 */
background: rgb(44,44,44); /* Old browsers */
background: -moz-linear-gradient(top, rgba(44,44,44,1) 1%, rgba(0,0,0,1) 9%, rgba(43,43,43,1) 50%, rgba(186,186,186,1) 54%, rgba(255,255,255,1) 100%); /* FF3.6-15 */
background: -webkit-linear-gradient(top, rgba(44,44,44,1) 1%,rgba(0,0,0,1) 9%,rgba(43,43,43,1) 50%,rgba(186,186,186,1) 54%,rgba(255,255,255,1) 100%); /* Chrome10-25,Safari5.1-6 */
background: linear-gradient(to bottom, rgba(44,44,44,1) 1%,rgba(0,0,0,1) 9%,rgba(43,43,43,1) 50%,rgba(186,186,186,1) 54%,rgba(255,255,255,1) 100%); /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */
}
.demo-card-wide>.mdl-card__menu, .demo-card-wide>.mdl-card__title {
color: #777;
}
.demo-card-wide canvas{
position:absolute;
z-index:0;
top:0;
left:0;
}
.mdl-card__title{
position:relative;
}
</style>
<div class="demo-card-wide mdl-card mdl-shadow--2dp">
<div class="mdl-card__title">
<canvas width="512" height="128" id="visualizer"></canvas>
<h2 class="mdl-card__title-text" title="Click here to load another module"><div><i class="material-icons">audiotrack</i></div><div class="title-container"><span class="title"></span><br />by <span class="author"></span></div></h2>
</div>
<div class="mdl-card__supporting-text">
<div class="mdl-tabs mdl-js-tabs mdl-js-ripple-effect">
<div class="mdl-tabs__tab-bar">
<a href="#modinfo-panel" class="mdl-tabs__tab is-active">Module Info</a>
<a href="#samples-panel" class="mdl-tabs__tab">Samples</a>
</div>
<div class="mdl-tabs__panel is-active" id="modinfo-panel">
<ul>
<li>Title: <span class="song-title"></span></li>
<li>Length: <span class="song-length"></span></li>
<li>Samples: <span class="song-samples"></span></li>
<li>Positions: <span class="song-positions"></span></li>
<li>Patterns: <span class="song-patterns"></span></li>
</ul>
</div>
<div class="mdl-tabs__panel" id="samples-panel">
<ul class="sample-list">
</ul>
</div>
</div>
</div>
<!-- <div class="mdl-card__actions mdl-card--border">
<a class="mdl-button mdl-button--colored mdl-js-button mdl-js-ripple-effect">
Get Started
</a>
</div> -->
<div class="mdl-card__menu">
<!-- <button class="mdl-button mdl-button--icon mdl-js-button mdl-js-ripple-effect">
<i class="material-icons">attachment</i>
</button> -->
</div>
</div>
</div>
</main>
<footer class="mdl-mini-footer">
<div class="mdl-mini-footer__left-section">
<ul class="mdl-mini-footer__link-list">
<li><a href="https://github.com/warpdesign/modplayer-js">GitHub</a></li>
<li><a href="https://twitter.com/warpdesign_">Twitter</a></li>
<li><a href="https://warpdesign.fr">Warpdesign ❤ WebAudio</a></li>
</ul>
</div>
</footer>
<div id="info-snackbar" class="mdl-js-snackbar mdl-snackbar">
<div class="mdl-snackbar__text content"></div>
<button class="mdl-snackbar__action" type="button"></button>
</div>
</div>
</body>
</html>