Boilerplate
This commit is contained in:
46
ui.html
46
ui.html
@@ -3,39 +3,25 @@
|
||||
|
||||
<head>
|
||||
<title>leafblade Minecraft Server</title>
|
||||
|
||||
<meta charset="UTF-8" />
|
||||
|
||||
<style type="text/css">
|
||||
html,
|
||||
body {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
#map {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
@media (max-width:768px) {
|
||||
#overlay { width: 100% }
|
||||
}
|
||||
</style>
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
</script>
|
||||
|
||||
<meta charset="UTF-8"/>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="container"></div>
|
||||
this is the UI
|
||||
</div>
|
||||
this is the UI
|
||||
|
||||
<button id="test_api">Test API</button>
|
||||
|
||||
<script src="/static/renderer.js"></script>
|
||||
<script>
|
||||
document.getElementById("test_api").onclick = async function (e) {
|
||||
let data = {foo: 'bar'};
|
||||
|
||||
await fetch('api', {
|
||||
method: 'POST',
|
||||
body: JSON.stringify(data),
|
||||
})
|
||||
};
|
||||
</script>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user