1
0
Fork 0
mirror of https://github.com/Eggbertx/gochan.git synced 2025-09-03 21:46:22 -07:00

Move CSS stuff from javascript to global CSS

This commit is contained in:
Eggbertx 2022-09-14 14:45:59 -07:00
parent 6bd8482ad0
commit 7d70fac114
5 changed files with 23 additions and 5 deletions

View file

@ -33,9 +33,8 @@ function addThreadToMenu(thread) {
class: "watcher-item"
}).append(
$("<a/>").prop({
id: "threadlink",
href: `${webroot}${thread.board}/res/${thread.id}.html`
}).css({
"font-weight": "bold"
}).text(`/${thread.board}/${thread.id}`)," ",
$replyCounter," ",
$("<a/>").prop({
@ -46,6 +45,8 @@ function addThreadToMenu(thread) {
unwatchThread(thread.id, thread.board);
}).text("X"), " "
);
let $threadLinks = $watcherItem.find("a#threadlink");
console.log($threadLinks.css("font-size"));
if(thread.err !== undefined)
$watcherItem.append($("<span/>")
.css({color: "red"})
@ -82,9 +83,8 @@ function updateThreadInWatcherMenu(thread) {
$replyCounter.append(
"(Replies: ", thread.newNumPosts - 1,", ",
$("<a/>").prop({
id: "newposts",
href: `${webroot}${thread.board}/res/${thread.op}.html#${thread.newPosts[0].no}`
}).css({
"font-weight": "bold"
}).text(`${thread.newPosts.length} new`),
") "
);

View file

@ -22,7 +22,7 @@
"test": "jest --verbose",
"build-sass": "sass --no-source-map sass:../html/css",
"minify-sass": "sass --no-source-map sass:../html/css",
"watch-sass": "sass --watch sass:../html/css"
"watch-sass": "sass --no-source-map --watch sass:../html/css"
},
"author": "Eggbertx",
"license": "BSD-2-Clause",

View file

@ -3,6 +3,7 @@
@import 'global/manage';
@import 'global/lightbox';
@import 'global/qr';
@import "global/watcher";
header {
margin-top:50px;

View file

@ -0,0 +1,9 @@
.watcher-item {
a#threadlink {
font-weight: bold;
font-size: 18px;
}
a#newposts {
font-weight: bold;
}
}

View file

@ -477,6 +477,14 @@ table#qr-postbox textarea {
color: #000;
}
.watcher-item a#threadlink {
font-weight: bold;
font-size: 18px;
}
.watcher-item a#newposts {
font-weight: bold;
}
header {
margin-top: 50px;
text-align: center;