diff --git a/CHANGELOG.md b/CHANGELOG.md index dba35eaf..df973e09 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,10 @@ ##### 0.1.2 - Merge webring and local board list and improve webring search and filter functionality - New stat section of homepage - - Replaced fatchan styled/branded spoiler image + - Replaced and removed some fatchan-specific media - Fixed undefined hcaptcha site key bug - Updated README with info about nginx CSP for 3rd party captcha providers + - Update socket-io 2.x to 4.x + +##### 0.1.3 + - Script optimizations, improve page load speed diff --git a/gulp/res/css/style.css b/gulp/res/css/style.css index eb364abc..924fe3c8 100644 --- a/gulp/res/css/style.css +++ b/gulp/res/css/style.css @@ -755,7 +755,7 @@ span.captchacheckbox { padding: 0px 2px; border: 1px solid rgba(0, 0, 0, 0.4); border-radius: 1px; - /*cursor: pointer;*/ + cursor: pointer; } .user-id:hover::after { diff --git a/gulp/res/js/threadstat.js b/gulp/res/js/threadstat.js index d266ba12..eed46c6f 100644 --- a/gulp/res/js/threadstat.js +++ b/gulp/res/js/threadstat.js @@ -1,15 +1,7 @@ window.addEventListener('DOMContentLoaded', (event) => { - const mainStyleSheet = document.querySelector('link[rel="stylesheet"]').sheet; - const rulesKey = mainStyleSheet.rules != null ? 'rules' : 'cssRules'; - for (rule of mainStyleSheet[rulesKey]) { - if(rule.selectorText == '.user-id') { - rule.style.cursor = 'pointer'; //make ids like a link when hovering - } - } - const statsElem = document.getElementById('threadstats'); - const idElems = []; + const idElems = document.getElementsByClassName('user-id'); const idMap = new Map(); const isHighlightedSet = new Set(); @@ -38,14 +30,9 @@ window.addEventListener('DOMContentLoaded', (event) => { } } - //fetch starting ids - const startElems = document.getElementsByClassName('user-id'); - for (let i = 0; i < startElems.length; i++) { - idElems.push(startElems[i]); - startElems[i].addEventListener('dblclick', toggleHighlightPosts); - } - //set counts + //map count of starting ids for (let i = 0; i < idElems.length; i++) { + idElems[i].addEventListener('dblclick', toggleHighlightPosts); incrementMap(idElems[i].innerText); } diff --git a/package.json b/package.json index be917c69..1c615a8b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "jschan", - "version": "0.1.2", + "version": "0.1.3", "migrateVersion": "0.1.2", "description": "", "main": "server.js", diff --git a/views/includes/head.pug b/views/includes/head.pug index 0ac75028..483abe7e 100644 --- a/views/includes/head.pug +++ b/views/includes/head.pug @@ -7,7 +7,7 @@ if isBoard if board.settings.tags meta(name='keywords' content=board.settings.tags.join(',')) noscript - style .jsonly { display: none!important; } + style .jsonly { display: none!important; } .user-id { cursor: auto!important; } link(rel='stylesheet' href=`/css/style.css?v=${commit}&ct=${captchaType}`) - const theme = isBoard ? board.settings.theme : defaultTheme; - const codeTheme = isBoard ? board.settings.codeTheme : defaultCodeTheme;