moved some stuff around and made luxon local
All checks were successful
/ weblog.lol (push) Successful in 13s
All checks were successful
/ weblog.lol (push) Successful in 13s
This commit is contained in:
parent
c4649e2386
commit
8942d2b4f3
8 changed files with 112 additions and 93 deletions
|
@ -38,7 +38,6 @@
|
|||
<hr>
|
||||
|
||||
<h2>Recent posts</h2>
|
||||
|
||||
{recent-posts}
|
||||
|
||||
</main>
|
||||
|
@ -47,8 +46,8 @@
|
|||
<p>Made with <a href="https://weblog.lol">weblog.lol</a>.</p>
|
||||
</footer>
|
||||
|
||||
<script src="https://cdn.jsdelivr.net/npm/luxon/build/global/luxon.min.js" crossorigin="anonymous"></script>
|
||||
<script src="/fediverse.js"></script>
|
||||
<script src="/js/luxon.min.js" crossorigin="anonymous"></script>
|
||||
<script src="/js/fediverse.js"></script>
|
||||
<script>
|
||||
document.querySelectorAll('time:not(.dt-start):not(.dt-end)').forEach(time => {
|
||||
const datetime = luxon.DateTime.fromISO(time.getAttribute('datetime'))
|
||||
|
|
1
js/luxon.min.js
vendored
Symbolic link
1
js/luxon.min.js
vendored
Symbolic link
|
@ -0,0 +1 @@
|
|||
./weblog/B0. Template/luxon.min.js.md
|
|
@ -2,7 +2,7 @@
|
|||
Type: file
|
||||
Content-Type: application/javascript
|
||||
Title: Fediverse script
|
||||
Location: /fediverse.js
|
||||
Location: /js/fediverse.js
|
||||
/**/
|
||||
|
||||
const SUBSCRIBE_LINK_REL = 'http://ostatus.org/schema/1.0/subscribe'
|
8
weblog/B0. Template/js/luxon.min.js.md
Normal file
8
weblog/B0. Template/js/luxon.min.js.md
Normal file
File diff suppressed because one or more lines are too long
|
@ -14,7 +14,7 @@ Title: Landing Page Template
|
|||
|
||||
<div class="header">
|
||||
<header>
|
||||
<img class="avatar" src="https://cdn.some.pics/deathau/663da4619fdb6.svg" alt="My avatar — A pixelated self-portrait in the style of the 'bitizens' in the mobile game Tiny Tower">
|
||||
<img class="avatar" src="https://cdn.some.pics/deathau/663da4619fdb6.svg" alt="My avatar — A pixelated self-portrait in the style of the 'bitizens' in the mobile game Tiny Tower" />
|
||||
<h1 class="weblog-title"><a href="{base-path}">{weblog-title}</a></h1>
|
||||
{navigation}
|
||||
<fedi-social></fedi-social>
|
||||
|
@ -36,8 +36,8 @@ Title: Landing Page Template
|
|||
<p>Made with <a href="https://weblog.lol">weblog.lol</a>.</p>
|
||||
</footer>
|
||||
|
||||
<script src="https://cdn.jsdelivr.net/npm/luxon/build/global/luxon.min.js" crossorigin="anonymous"></script>
|
||||
<script src="/fediverse.js"></script>
|
||||
<script src="/js/luxon.min.js" crossorigin="anonymous"></script>
|
||||
<script src="/js/fediverse.js"></script>
|
||||
<script>
|
||||
document.querySelectorAll('time:not(.dt-start):not(.dt-end)').forEach(time => {
|
||||
const datetime = luxon.DateTime.fromISO(time.getAttribute('datetime'))
|
||||
|
|
|
@ -12,22 +12,33 @@ Title: Page Template
|
|||
</head>
|
||||
<body>
|
||||
|
||||
<div class="header">
|
||||
<header>
|
||||
<img class="avatar" src="https://cdn.some.pics/deathau/663da4619fdb6.svg" alt="My avatar — A pixelated self-portrait in the style of the 'bitizens' in the mobile game Tiny Tower" />
|
||||
<h1 class="weblog-title"><a href="{base-path}">{weblog-title}</a></h1>
|
||||
{navigation}
|
||||
<fedi-social></fedi-social>
|
||||
</header>
|
||||
</div>
|
||||
|
||||
<main class="page">
|
||||
|
||||
{body}
|
||||
|
||||
<hr>
|
||||
|
||||
</main>
|
||||
|
||||
<footer>
|
||||
<p>Made with <a href="https://weblog.lol">weblog.lol</a>.</p>
|
||||
</footer>
|
||||
|
||||
<script src="/js/luxon.min.js" crossorigin="anonymous"></script>
|
||||
<script src="/js/fediverse.js"></script>
|
||||
<script>
|
||||
document.querySelectorAll('time:not(.dt-start):not(.dt-end)').forEach(time => {
|
||||
const datetime = luxon.DateTime.fromISO(time.getAttribute('datetime'))
|
||||
time.innerText = datetime.toRelative()
|
||||
})
|
||||
fediverse()
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
|
Loading…
Reference in a new issue