-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
38 lines (31 loc) · 1.13 KB
/
index.html
File metadata and controls
38 lines (31 loc) · 1.13 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>demo</title>
<link rel="icon" type="image/x-icon" href ="/favicon.ico">
<link rel="stylesheet" href="./index.css">
</head>
<body>
<div>
Demo
</div>
<canvas style="border-style: dashed; width: 100%; height: 700px; margin-top: 40px; touch-action: none;" id="canvas"></canvas>
<div
style="padding-left: 20px; padding-top: 20px; margin-top: 40px; width: 300px; height: 100px; border-style: double; color:aliceblue; background-color: brown;"
id="dropzone"
>
drag n drop obj here
</div>
<input type="file" id="input">
<button id="export" style="float: right;">save scene</button>
<script type="module" >
import { main } from '/src/index.ts'
const canvas = document.querySelector("#canvas");
const dropZoneEl = document.querySelector("#dropzone");
const inputEl = document.querySelector('#input');
const exportEl = document.querySelector('#export');
main(canvas, dropZoneEl, inputEl, exportEl);
</script>
</body>
</html>