30 lines
No EOL
1,021 B
HTML
30 lines
No EOL
1,021 B
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<script src="draw.js"></script>
|
|
<script src="button.js"></script>
|
|
<script>
|
|
const urlParams = new URLSearchParams(window.location.search);
|
|
let path = urlParams.get('path');
|
|
if(path === null) {
|
|
const fileID = urlParams.get('id'); // legacy support
|
|
path = "/data/assets/" + fileID + ".svg";
|
|
}
|
|
|
|
document.addEventListener('DOMContentLoaded', async () => {
|
|
const editLink = document.createElement('a');
|
|
editLink.href = getEditLink(path);
|
|
document.body.appendChild(editLink);
|
|
|
|
const htmlContainer = document.createElement('div');
|
|
htmlContainer.innerHTML = await getSVG(path);
|
|
editLink.appendChild(htmlContainer);
|
|
|
|
addButton(document, path);
|
|
});
|
|
</script>
|
|
<link rel="stylesheet" href="index.css">
|
|
</head>
|
|
<body>
|
|
</body>
|
|
</html> |