aboutsummaryrefslogtreecommitdiff
path: root/static
diff options
context:
space:
mode:
Diffstat (limited to 'static')
-rw-r--r--static/css/txt/bbs.css4
-rw-r--r--static/js/weabotxt.js60
2 files changed, 38 insertions, 26 deletions
diff --git a/static/css/txt/bbs.css b/static/css/txt/bbs.css
index 03de99f..cc90ff0 100644
--- a/static/css/txt/bbs.css
+++ b/static/css/txt/bbs.css
@@ -325,9 +325,11 @@ form .msg {
#threads a:hover {
text-decoration: underline;
}
-.minisjis {
+.sjis-mob {
font-size: 10px;
line-height: 12px;
+ overflow-x: auto;
+ white-space: nowrap;
}
.end {
margin-top: 0.5em;
diff --git a/static/js/weabotxt.js b/static/js/weabotxt.js
index 734a5ae..93850d9 100644
--- a/static/js/weabotxt.js
+++ b/static/js/weabotxt.js
@@ -234,35 +234,45 @@ document.addEventListener("DOMContentLoaded", function() {
}
}
- if (document.body.clientWidth < 600 && head) {
- var navlink = head.getElementsByTagName("a");
+ if (document.body.clientWidth < 600) {
+ if (head) {
+ var navlink = head.getElementsByTagName("a");
+
+ var sel = document.createElement("select");
+ sel.id = head.id + "_sel";
+ sel.addEventListener("change", function(e){
+ window.location.href = this.value;
+ });
+
+ for (var i=1; i<navlink.length; i++) {
+ var c = document.createElement("option");
+ c.text = navlink[i].textContent;
+ c.value = navlink[i].href;
+ if (navlink[i].className == "cur_brd") {
+ c.selected = true;
+ }
+ sel.options.add(c);
+ }
- var sel = document.createElement("select");
- sel.id = head.id + "_sel";
- sel.addEventListener("change", function(e){
- window.location.href = this.value;
- });
+ head.textContent = ""
+ var home = document.createElement("a");
+ home.text = "Bienvenido a Internet";
+ home.href = "/home.html";
+ head.appendChild(home);
+ head.appendChild(document.createTextNode(" ★ "));
+ head.appendChild(sel);
- for (var i=1; i<navlink.length; i++) {
- var c = document.createElement("option");
- c.text = navlink[i].textContent;
- c.value = navlink[i].href;
- if (navlink[i].className == "cur_brd") {
- c.selected = true;
- }
- sel.options.add(c);
+ head.className = "mob";
+ document.body.style.marginTop = "2em";
}
- head.textContent = ""
- var home = document.createElement("a");
- home.text = "Bienvenido a Internet";
- home.href = "/home.html";
- head.appendChild(home);
- head.appendChild(document.createTextNode(" ★ "));
- head.appendChild(sel);
-
- head.className = "mob";
- document.body.style.marginTop = "2em";
+ var sjis = /(  \|  /|\  |/  | ̄ ̄||  |  ||\|  |  \|)/;
+ var msg = document.getElementsByClassName("msg");
+ for (var i=0; i < msg.length; i++) {
+ if (msg[i].textContent.match(sjis)) {
+ msg[i].classList.add("sjis-mob");
+ }
+ }
}
var forms = document.getElementsByTagName("form");