From 95dfe14528663923ca2a88ec928f1d8d9df2402b Mon Sep 17 00:00:00 2001 From: bai Date: Fri, 29 Mar 2019 02:14:43 +0000 Subject: Init --- static/js/aquiencitas.js | 168 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 168 insertions(+) create mode 100644 static/js/aquiencitas.js (limited to 'static/js/aquiencitas.js') diff --git a/static/js/aquiencitas.js b/static/js/aquiencitas.js new file mode 100644 index 0000000..0cf860f --- /dev/null +++ b/static/js/aquiencitas.js @@ -0,0 +1,168 @@ +var cur_url; +var linklist; +var linki; +var is_bbs; +var plimit = 5; +function getPostRange(t, n) { + var posts, replies, s, ss, ee, rev = false; + posts = []; + replies = t.getElementsByClassName("reply"); + s = n.split('-'); + ss = parseInt(s[0]); + ee = ss; + if(s.length == 2) ee = parseInt(s[1]); + if(ee ee) break; + if(num >= ss && num <= ee) { + if(rev) posts.unshift(replies[j]); + else posts.push(replies[j]); + } + } + return posts; +} +function findAncestor (el) { + while ((el = el.parentElement) && !el.className.startsWith("thread") && !el.className.startsWith("cont")); + return el; +} +function getPostDivs(e) { + if(is_bbs) { + divs = []; + t = findAncestor(e); + s = e.getAttribute('href').split('/'); + r = s[s.length-1]; + rs = r.split(','); + linki = 0; + for(i=0;i maxWidth) { + width = maxWidth; + } + + for(i=0;i>")) continue; + + if(localStorage.getItem("shobon_preview") != "false") { + q.addEventListener('mouseover', who_are_you_quoting, false); + q.addEventListener('mouseout', remove_quote_preview, false); + } + + if(localStorage.getItem("shobon_backlink") != "false") { + fill_links(q); + } + } + } +/* if (document.body.className === "threadpage") { + for (x = 0; x < replies.length; x++) { + var q = replies[x].getElementsByTagName("a"); + for(var j=0;j>")) q[j].addEventListener("click", goTo, false); + } + } + }*/ +} +document.addEventListener('DOMContentLoaded', quotePreview, false); \ No newline at end of file -- cgit v1.2.1-18-gbd029