various fixes

This commit is contained in:
Simon 2025-05-05 22:41:53 +02:00
parent 9ff5506607
commit 72f964373e
6 changed files with 48 additions and 57 deletions

View File

@ -1,4 +1,11 @@
{
"tasks": {
"copy-static": "cp -r static/* build/",
"build": {
"command": "deno run -RWN main.ts",
"dependencies": ["copy-static"],
},
},
"fmt": {
"indentWidth": 4,
},

View File

@ -117,7 +117,9 @@ function renderIndex(articles: ArticleInfo[]): string {
</a>
</td>
<td>${article.author}</td>
<td>${new Date(article.dateAdded).toUTCString()}</td>
<td class="article-date">${
new Date(article.dateAdded).toUTCString()
}</td>
<td>${(
article.tags.map((tag) => `
<a href="categories.html#${tag}">

25
static/articles/style.css Normal file
View File

@ -0,0 +1,25 @@
:root {
color-scheme: light dark;
}
body {
margin: 0 auto;
padding: 2rem;
line-height: 1.6em;
}
body.index {
max-width: 1400px;
}
body.article {
max-width: 1000px;
}
table {
border-collapse: collapse;
}
td.article-date {
white-space: nowrap;
}

View File

@ -5,28 +5,13 @@
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="author" content="$author">
<meta name="description" content="$title">
<style>
:root {
color-scheme: light dark;
}
body {
margin: 0 auto;
padding: 2rem;
max-width: 1000px;
line-height: 1.6em;
}
table {
border-collapse: collapse;
}
</style>
<link rel="stylesheet" href="style.css">
</head>
<body>
<body class="article">
<header>
Mirror website of
<a href="https://proletarianrevolution.net/">
PROLETARIANREVOLTION.NET
PROLETARIANREVOLUTION.NET
</a>
</header>
<nav>
@ -48,7 +33,8 @@
<li>Author: <span id="author">$author</span></li>
<li>Tags: <span id="tags">$tags</span></li>
<li>
Link to original: <a href="$originalLink">$originalLink</a>
Link to original:
<a href="$originalLink" target="_blank">$originalLink</a>
</li>
</ul>
<article id="article-body">$body</article>

View File

@ -5,28 +5,13 @@
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="author" content="PROLETARIANREVOLUTION.NET">
<meta name="description" content="Categories">
<style>
:root {
color-scheme: light dark;
}
body {
margin: 0 auto;
padding: 2rem;
max-width: 1400px;
line-height: 1.6em;
}
table {
border-collapse: collapse;
}
</style>
<link rel="stylesheet" href="style.css">
</head>
<body>
<body class="index">
<header>
Mirror website of
<a href="https://proletarianrevolution.net/">
PROLETARIANREVOLTION.NET
PROLETARIANREVOLUTION.NET
</a>
</header>
<nav>

View File

@ -5,28 +5,13 @@
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="author" content="PROLETARIANREVOLUTION.NET">
<meta name="description" content="All articles (A-Z)">
<style>
:root {
color-scheme: light dark;
}
body {
margin: 0 auto;
padding: 2rem;
max-width: 1400px;
line-height: 1.6em;
}
table {
border-collapse: collapse;
}
</style>
<link rel="stylesheet" href="style.css">
</head>
<body>
<body class="index">
<header>
Mirror website of
<a href="https://proletarianrevolution.net/">
PROLETARIANREVOLTION.NET
PROLETARIANREVOLUTION.NET
</a>
</header>
<main>
@ -35,7 +20,8 @@
</h1>
<p>The articles were downloaded $downloadDate.</p>
<p>
See also the <a href="categories.html">list over categories</a>.
See also the articles <a href="categories.html"
>organized by categories</a>.
</p>
<table>
<tr>