-
Notifications
You must be signed in to change notification settings - Fork 7
/
media.html
43 lines (38 loc) · 1.33 KB
/
media.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
<!DOCTYPE html>
<html>
<head>
<title>My Music Encoding Project</title>
<meta charset="utf-8">
<meta name="description" content="My project">
<meta name="author" content="Me">
<link rel="stylesheet" href="css/style.css" media="all" />
<script src="js/utils.js"></script>
</head>
<body>
<!-- 1. The <iframe> (and video player) will replace this <div> tag. -->
<div id="player"></div>
<div id="app">Verovio is loading...</div>
<script type="module">
import 'https://www.verovio.org/javascript/app/verovio-app.js';
const options = {
defaultView: 'responsive', // default is 'responsive', alternative is 'document'
defaultZoom: 3, // 0-7, default is 4
enableResponsive: true, // default is true
enableDocument: true // default is true
}
// A MusicXML file
var file = 'data/example.mei';
// A MEI file
//var file = 'https://www.verovio.org/editor/brahms.mei';
const app = new Verovio.App(document.getElementById("app"), options);
fetch(file)
.then(function(response) {
return response.text();
})
.then(function(text) {
app.loadData(text);
});
</script>
<script src="js/youtube.js"></script>
</body>
</html>