temp remove comments

Signed-off-by: Ari Archer <ari.web.xyz@gmail.com>
This commit is contained in:
Ari Archer 2023-12-01 02:29:32 +02:00
parent f65a0a22e0
commit 02fdb75852
2 changed files with 23 additions and 21 deletions

View file

@ -1,5 +1,7 @@
"use strict";
/* TODO comments ( us.ari.lt ) */
function resize_term() {
document.getElementById("term-wrap").style.width = `${
document.querySelector("article").offsetWidth
@ -11,7 +13,7 @@ async function main() {
resize_term();
let blog = document.getElementById("blog-posts");
let comment = document.getElementById("latest-comments");
// let comment = document.getElementById("latest-comments");
let more = document.getElementById("discover");
let site = document.getElementById("site");
@ -64,27 +66,27 @@ async function main() {
});
});
FETCH_COMMENTS().then((j) => {
comment.innerText = "";
// FETCH_COMMENTS().then((j) => {
// comment.innerText = "";
Object.entries(j)
.reverse()
.forEach((post) => {
let id = post[0];
post = post[1];
// Object.entries(j)
// .reverse()
// .forEach((post) => {
// let id = post[0];
// post = post[1];
mkelem(
"li",
[
mkelem("a", `#${id} by ${post[0]}`, null, {
href: `${COMMENT_SITE}/#${id}`,
}),
mkelem("pre", linkify(post[1], COMMENT_SITE)),
],
comment,
);
});
});
// mkelem(
// "li",
// [
// mkelem("a", `#${id} by ${post[0]}`, null, {
// href: `${COMMENT_SITE}/#${id}`,
// }),
// mkelem("pre", linkify(post[1], COMMENT_SITE)),
// ],
// comment,
// );
// });
// });
FETCH_PAGES().then((j) => {
more.innerText = "";

View file

@ -97,7 +97,7 @@
<div id="comments">
<h2>latest <a id="comments-link">comments</a></h2>
<ul id="latest-comments">
loading comments ...
loading comments ( TODO as the server is down ) ...
</ul>
</div>