-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathIndex.html
More file actions
80 lines (73 loc) · 2.41 KB
/
Copy pathIndex.html
File metadata and controls
80 lines (73 loc) · 2.41 KB
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
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, viewport-fit=cover"
/>
<title>Bloomspace</title>
<meta name="theme-color" content="#05070f" />
<!-- Derive a relative base from the current URL so the app works deployed under a
subpath (e.g. /bloomspace/). All other URLs are relative to this base. -->
<script>
(function () {
var path = location.pathname;
var dir = path.slice(0, path.lastIndexOf("/") + 1);
var base = document.createElement("base");
base.href = dir;
document.head.appendChild(base);
})();
</script>
<link rel="manifest" href="Manifest.webmanifest" />
<link rel="icon" href="Icons/Icon.svg" type="image/svg+xml" />
<!-- Vendored stylesheets (relative). -->
<link rel="stylesheet" href="Vendor/FontAwesome/Css/All.min.css" />
<link rel="stylesheet" href="Vendor/WebAwesome/styles/webawesome.css" />
<style>
html,
body {
margin: 0;
height: 100%;
background: #05070f;
overflow: hidden;
}
#Canvas {
position: fixed;
inset: 0;
width: 100vw;
height: 100vh;
display: block;
touch-action: none;
}
#Ui {
position: fixed;
inset: 0;
pointer-events: none; /* UI children opt back in as needed */
z-index: 10;
}
</style>
<!-- Import map: bare specifiers -> vendored three. Paths are relative so they
resolve under the deploy subpath via <base>. -->
<script type="importmap">
{
"imports": {
"three": "./Vendor/Three/Three.module.js",
"three/addons/": "./Vendor/Three/Jsm/"
}
}
</script>
<!-- Web Awesome: point the loader at the vendored folder so components lazy-load
offline with NO CDN fetch and NO kit token. -->
<script type="module">
import { setBasePath } from "./Vendor/WebAwesome/webawesome.loader.js";
setBasePath(new URL("./Vendor/WebAwesome/", document.baseURI).href);
</script>
</head>
<body>
<!-- The game <canvas id="Canvas"> is created fresh per match by Ui/App.js (a reused
canvas can't be re-used after its WebGL context is force-lost on teardown). -->
<div id="Ui"></div>
<script type="module" src="./Main.js"></script>
</body>
</html>