-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
29 lines (27 loc) · 1.02 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
<html lang="en">
<head>
<meta content="text/html;charset=utf-8" http-equiv="Content-Type"/>
<meta name="viewport" content="initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,width=320,height=device-height,user-scalable=yes"/>
<title>SDF Viewer</title>
<style>
body {
margin: 0;
overflow: hidden;
}
</style>
</head>
<body>
<canvas id="sdf-viewer" style="position: absolute;top:0;bottom: 0;left: 0;right: 0;margin:auto;"></canvas>
<script type="module">
import * as SDFViewer from './sdf_viewer_lib.js';
SDFViewer.default().then( // Async initialization
() => SDFViewer.run_app("sdf-viewer")); // Run the actual App
// Start a toggleable web console for mobile devices only (to help with debugging)
if (/Mobi|Android/i.test(navigator.userAgent)) {
var src = '//cdn.jsdelivr.net/npm/eruda';
document.write('<scr' + 'ipt src="' + src + '"></scr' + 'ipt>');
document.write('<scr' + 'ipt>eruda.init();</scr' + 'ipt>');
}
</script>
</body>
</html>