83 lines
2.9 KiB
HTML
83 lines
2.9 KiB
HTML
<!doctype html>
|
|
<html lang="en" style="height:100%;margin:0;">
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta name="viewport" content="width=device-width,initial-scale=1.0">
|
|
<title>{{ title }}</title>
|
|
|
|
<!-- Load main stylesheet asynchronously -->
|
|
<link rel="preload" as="style" href="/css/main.css" onload="this.rel='stylesheet'">
|
|
<link rel="preload" as="style" href="/css/prism.css" onload="this.rel='stylesheet'">
|
|
<noscript><link rel="stylesheet" href="/css/main.css"></noscript>
|
|
|
|
<link rel="icon" type="image/x-icon" href="/css/favicon/favicon.ico">
|
|
|
|
<!-- Local JS -->
|
|
<script src="/js/shared/theme.js"></script>
|
|
<script src="/js/post/download.js" defer></script>
|
|
|
|
<!-- Prism (code highlighting) -->
|
|
<script src="/js/post/prism.js" defer></script>
|
|
|
|
<!-- Dynamic MathJax loader -->
|
|
<script>
|
|
document.addEventListener('DOMContentLoaded', () => {
|
|
const hasMath = /\$\$(.|[\r\n])*?\$\$|\$(?!\$)(.*?)\$/.test(document.body.innerHTML);
|
|
if (hasMath) {
|
|
const mj = document.createElement('script');
|
|
mj.src = '/package/js/mathjax.js';
|
|
mj.defer = true;
|
|
document.head.appendChild(mj);
|
|
}
|
|
});
|
|
</script>
|
|
|
|
<!-- Service worker registration -->
|
|
<script>
|
|
if ('serviceWorker' in navigator) {
|
|
navigator.serviceWorker.register('/js/post/sw.js').catch(console.error);
|
|
}
|
|
</script>
|
|
</head>
|
|
|
|
<body>
|
|
<main class="container">
|
|
<h1 onclick="window.location.href=window.location.origin" style="cursor:pointer;display:flex;align-items:center;gap:8px;font-size:1.5em;margin:0;">
|
|
<img src="/css/icons/back.webp" width="32" height="32" alt="⬅" loading="lazy">
|
|
{{ title }} <noscript>(Enable JavaScript!)</noscript>
|
|
</h1>
|
|
<img src="/css/icons/written.webp" width="32" height="32" alt="📄" loading="lazy" style="vertical-align:middle;padding-left:40px;cursor:pointer;" onclick="toggleDarkMode();" />
|
|
<div class="meta" style="display:inline;cursor:pointer;" onclick="toggleDarkMode();">
|
|
Written @{{ now }}
|
|
</div>
|
|
<hr style="margin:10px 0;">
|
|
<div class="html-content">
|
|
{{ html_body | safe }}
|
|
</div>
|
|
</main>
|
|
|
|
<footer style="margin-top:auto;width:100%;">
|
|
<hr style="margin:10px 0;">
|
|
<img src="/css/icons/date.webp" width="16" height="16" alt="date" loading="lazy">
|
|
{{ timestamp }}<br>
|
|
|
|
<img src="/css/icons/magnifier.webp" width="16" height="16" alt="Hash1" loading="lazy">
|
|
Hash 1 (<b>UTF-8</b>)<i>:{{ hash1 }}</i><br>
|
|
|
|
<img src="/css/icons/magnifier.webp" width="16" height="16" alt="Hash2" loading="lazy">
|
|
Hash 2 (<b>Windows-1252</b>)<i>:{{ hash2 }}</i><br>
|
|
|
|
<span style="display:inline-flex;align-items:center;gap:8px;">
|
|
<img src="/css/icons/save.webp" width="16" height="16" alt="Save" loading="lazy">
|
|
<a id="download-md">Download as Markdown</a>
|
|
|
|
<span style="border-left:1px solid #888;height:16px;"></span>
|
|
|
|
<img src="/css/icons/script.webp" width="16" height="16" alt="Script" loading="lazy">
|
|
<a id="download-html">Download as HTML</a>
|
|
</span>
|
|
</footer>
|
|
</body>
|
|
</html>
|
|
|