-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathindexFlexboxHTTPServer.html
More file actions
39 lines (36 loc) · 956 Bytes
/
indexFlexboxHTTPServer.html
File metadata and controls
39 lines (36 loc) · 956 Bytes
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
<html>
<head>
<style>
body {
display: flex;
}
#left {
background-color: #fdd;
flex-basis: 10rem;
}
#right {
background-color: #ddf;
flex-basis: auto;
flex-grow: 1;
flex-shrink: 1;
max-width: 97vw;
}
</style>
<script src="./opensheetmusicdisplay.min.js"></script>
</head>
<body>
<div id="left">Left</div>
<div id="right"></div>
</body>
<script>
var osmd = new opensheetmusicdisplay.OpenSheetMusicDisplay("right");
osmd.load("http://localhost:8080/Saltarello_sample.musicxml").then(
function() {
osmd.zoom = 0.8;
osmd.render();
window.addEventListener("resize", () => {
osmd.render();
});
});
</script>
</html>