mirror of
https://github.com/arabine/open-story-teller.git
synced 2025-12-07 01:15:14 +01:00
84 lines
2.9 KiB
HTML
84 lines
2.9 KiB
HTML
<!doctype html>
|
|
<html lang="en-us">
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
|
<meta name="title" content="OpenStoryTeller Web Player">
|
|
<meta name="description" content="OpenStoryTeller Web Player">
|
|
<meta name="keywords" content="story, player, teller">
|
|
|
|
<title>OpenStoryTeller Web Player</title>
|
|
|
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;700&display=swap" rel="stylesheet">
|
|
|
|
<link rel="stylesheet" href="style.css">
|
|
<link rel="stylesheet" href="main.css">
|
|
|
|
<script type="importmap">
|
|
{
|
|
"imports": {
|
|
"preact": "https://esm.sh/preact@10.23.1",
|
|
"preact/hooks": "https://esm.sh/preact@10.23.1/hooks",
|
|
"htm/preact": "https://esm.sh/htm@3.1.1/preact?external=preact"
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<!-- Favicon -->
|
|
<link rel="shortcut icon" href="https://www.raylib.com/favicon.ico">
|
|
<style>
|
|
body {
|
|
line-height: 1;
|
|
font-family: 'Inter', sans-serif;
|
|
margin: 0;
|
|
padding: 0;
|
|
line-height: 1.6;
|
|
}
|
|
|
|
canvas.emscripten { border: 0px none; background-color: black; display: inline; }
|
|
#canvas-container {
|
|
width: 100%;
|
|
text-align:center;
|
|
}
|
|
</style>
|
|
</head>
|
|
<body style="min-width: min-content;">
|
|
<main>
|
|
<div id="app"></div>
|
|
|
|
<div id="canvas-container" class="block fixed">
|
|
<canvas class=emscripten id=canvas oncontextmenu=event.preventDefault() tabindex=-1></canvas>
|
|
</div>
|
|
<p id="output" />
|
|
|
|
</main>
|
|
|
|
<script>
|
|
var Module = {
|
|
print: (function() {
|
|
var element = document.getElementById('output');
|
|
if (element) element.value = ''; // clear browser cache
|
|
return function(text) {
|
|
if (arguments.length > 1) text = Array.prototype.slice.call(arguments).join(' ');
|
|
console.log(text);
|
|
if (element) {
|
|
element.value += text + "\n";
|
|
element.scrollTop = element.scrollHeight; // focus on bottom
|
|
}
|
|
};
|
|
})(),
|
|
canvas: (function() {
|
|
var canvas = document.getElementById('canvas');
|
|
return canvas;
|
|
})(),
|
|
locateFile: function(s) {
|
|
return 'bin/' + s;
|
|
}
|
|
};
|
|
</script>
|
|
<script async type="text/javascript" src="bin/story-player.js"></script>
|
|
<script src="app.js" type="module"></script>
|
|
</body>
|
|
</html> |