diff --git a/CHANGELOG.md b/CHANGELOG.md index 8356aa85a..baa0860ea 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ Sometimes the changelog has notes (not comprehensive) acknowledging people's wor ### v1.11.12 +**v1.11.12.7** *(2015-10-13)* - [[Firefox](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.12.7/builds/4chan-X-noupdate.user.js "Firefox version")] [[Chromium](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.12.7/builds/4chan-X-noupdate.crx "Chromium version")] +- Add keybind for `[sjis]` tags (default: `Alt+a`). +- Update max comment length on /jp/ (now 5000, read from board). + **v1.11.12.6** *(2015-10-12)* - [[Firefox](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.12.6/builds/4chan-X-noupdate.user.js "Firefox version")] [[Chromium](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.12.6/builds/4chan-X-noupdate.crx "Chromium version")] - (fgts) Update archive list: Add /gd/, /out/, /po/ to fgts. diff --git a/builds/4chan-X-beta.crx b/builds/4chan-X-beta.crx index 1b23e0293..8a02c2b29 100644 Binary files a/builds/4chan-X-beta.crx and b/builds/4chan-X-beta.crx differ diff --git a/builds/4chan-X-beta.meta.js b/builds/4chan-X-beta.meta.js index 3ca124a4d..2504291f1 100644 --- a/builds/4chan-X-beta.meta.js +++ b/builds/4chan-X-beta.meta.js @@ -1,6 +1,6 @@ // ==UserScript== // @name 4chan X beta -// @version 1.11.12.6 +// @version 1.11.12.7 // @minGMVer 1.14 // @minFFVer 26 // @namespace 4chan-X diff --git a/builds/4chan-X-beta.user.js b/builds/4chan-X-beta.user.js index 65278230c..27080a9ef 100644 --- a/builds/4chan-X-beta.user.js +++ b/builds/4chan-X-beta.user.js @@ -1,7 +1,7 @@ // Generated by CoffeeScript // ==UserScript== // @name 4chan X beta -// @version 1.11.12.6 +// @version 1.11.12.7 // @minGMVer 1.14 // @minFFVer 26 // @namespace 4chan-X @@ -356,6 +356,7 @@ 'Code tags': ['Alt+c', 'Insert code tags.'], 'Eqn tags': ['Alt+e', 'Insert eqn tags.'], 'Math tags': ['Alt+m', 'Insert math tags.'], + 'SJIS tags': ['Alt+a', 'Insert SJIS tags.'], 'Toggle sage': ['Alt+s', 'Toggle sage in options field.'], 'Submit QR': ['Ctrl+Enter', 'Submit post.'], 'Watch': ['w', 'Watch thread.'], @@ -413,7 +414,7 @@ doc = d.documentElement; g = { - VERSION: '1.11.12.6', + VERSION: '1.11.12.7', NAMESPACE: '4chan X.', boards: {} }; @@ -7230,8 +7231,8 @@ counter = QR.nodes.charCount; count = QR.nodes.com.value.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g, '_').length; counter.textContent = count; - counter.hidden = count < 1000; - return (count > 2000 ? $.addClass : $.rmClass)(counter, 'warning'); + counter.hidden = count < QR.max_comment / 2; + return (count > QR.max_comment ? $.addClass : $.rmClass)(counter, 'warning'); }, getFile: function() { var ref; @@ -7399,7 +7400,7 @@ return (g.VIEW === 'thread' ? $.addClass : $.rmClass)(QR.nodes.el, 'reply-to-thread'); }, dialog: function() { - var dialog, event, i, items, m, match_max, match_min, name, node, nodes, ref, rules, save, setNode; + var dialog, event, i, items, m, match_max, match_min, name, node, nodes, ref, rules, save, scriptData, setNode; QR.nodes = nodes = { el: dialog = UI.dialog('qr', 'top: 50px; right: 0px;', { innerHTML: "
" @@ -7442,7 +7443,9 @@ QR.max_width = +(match_max != null ? match_max[1] : void 0) || 10000; QR.max_height = +(match_max != null ? match_max[2] : void 0) || 10000; nodes.fileInput.max = $('input[name=MAX_FILE_SIZE]').value; - QR.max_size_video = (m = Get.scriptData().match(/\bmaxWebmFilesize *= *(\d+)\b/)) ? +m[1] : +nodes.fileInput.max; + scriptData = Get.scriptData(); + QR.max_size_video = (m = scriptData.match(/\bmaxWebmFilesize *= *(\d+)\b/)) ? +m[1] : +nodes.fileInput.max; + QR.max_comment = (m = scriptData.match(/\bcomlen *= *(\d+)\b/)) ? +m[1] : 2000; QR.max_width_video = QR.max_height_video = 2048; QR.max_duration_video = (ref = g.BOARD.ID) === 'gif' || ref === 'wsg' ? 300 : 120; if (Conf['Show New Thread Option in Threads']) { @@ -15654,6 +15657,12 @@ } Keybinds.tags('math', target); break; + case Conf['SJIS tags']: + if (target.nodeName !== 'TEXTAREA') { + return; + } + Keybinds.tags('sjis', target); + break; case Conf['Toggle sage']: if (!(QR.nodes && !QR.nodes.el.hidden)) { return; @@ -15942,6 +15951,8 @@ case 'math': case 'eqn': return g.BOARD.ID === 'sci'; + case 'sjis': + return g.BOARD.ID === 'jp'; } })(); if (!supported) { diff --git a/builds/4chan-X-noupdate.crx b/builds/4chan-X-noupdate.crx index d5e394089..ab1e36ce8 100644 Binary files a/builds/4chan-X-noupdate.crx and b/builds/4chan-X-noupdate.crx differ diff --git a/builds/4chan-X-noupdate.user.js b/builds/4chan-X-noupdate.user.js index 943ce1a5e..474b56b45 100644 --- a/builds/4chan-X-noupdate.user.js +++ b/builds/4chan-X-noupdate.user.js @@ -1,7 +1,7 @@ // Generated by CoffeeScript // ==UserScript== // @name 4chan X -// @version 1.11.12.6 +// @version 1.11.12.7 // @minGMVer 1.14 // @minFFVer 26 // @namespace 4chan-X @@ -356,6 +356,7 @@ 'Code tags': ['Alt+c', 'Insert code tags.'], 'Eqn tags': ['Alt+e', 'Insert eqn tags.'], 'Math tags': ['Alt+m', 'Insert math tags.'], + 'SJIS tags': ['Alt+a', 'Insert SJIS tags.'], 'Toggle sage': ['Alt+s', 'Toggle sage in options field.'], 'Submit QR': ['Ctrl+Enter', 'Submit post.'], 'Watch': ['w', 'Watch thread.'], @@ -413,7 +414,7 @@ doc = d.documentElement; g = { - VERSION: '1.11.12.6', + VERSION: '1.11.12.7', NAMESPACE: '4chan X.', boards: {} }; @@ -7230,8 +7231,8 @@ counter = QR.nodes.charCount; count = QR.nodes.com.value.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g, '_').length; counter.textContent = count; - counter.hidden = count < 1000; - return (count > 2000 ? $.addClass : $.rmClass)(counter, 'warning'); + counter.hidden = count < QR.max_comment / 2; + return (count > QR.max_comment ? $.addClass : $.rmClass)(counter, 'warning'); }, getFile: function() { var ref; @@ -7399,7 +7400,7 @@ return (g.VIEW === 'thread' ? $.addClass : $.rmClass)(QR.nodes.el, 'reply-to-thread'); }, dialog: function() { - var dialog, event, i, items, m, match_max, match_min, name, node, nodes, ref, rules, save, setNode; + var dialog, event, i, items, m, match_max, match_min, name, node, nodes, ref, rules, save, scriptData, setNode; QR.nodes = nodes = { el: dialog = UI.dialog('qr', 'top: 50px; right: 0px;', { innerHTML: " " @@ -7442,7 +7443,9 @@ QR.max_width = +(match_max != null ? match_max[1] : void 0) || 10000; QR.max_height = +(match_max != null ? match_max[2] : void 0) || 10000; nodes.fileInput.max = $('input[name=MAX_FILE_SIZE]').value; - QR.max_size_video = (m = Get.scriptData().match(/\bmaxWebmFilesize *= *(\d+)\b/)) ? +m[1] : +nodes.fileInput.max; + scriptData = Get.scriptData(); + QR.max_size_video = (m = scriptData.match(/\bmaxWebmFilesize *= *(\d+)\b/)) ? +m[1] : +nodes.fileInput.max; + QR.max_comment = (m = scriptData.match(/\bcomlen *= *(\d+)\b/)) ? +m[1] : 2000; QR.max_width_video = QR.max_height_video = 2048; QR.max_duration_video = (ref = g.BOARD.ID) === 'gif' || ref === 'wsg' ? 300 : 120; if (Conf['Show New Thread Option in Threads']) { @@ -15654,6 +15657,12 @@ } Keybinds.tags('math', target); break; + case Conf['SJIS tags']: + if (target.nodeName !== 'TEXTAREA') { + return; + } + Keybinds.tags('sjis', target); + break; case Conf['Toggle sage']: if (!(QR.nodes && !QR.nodes.el.hidden)) { return; @@ -15942,6 +15951,8 @@ case 'math': case 'eqn': return g.BOARD.ID === 'sci'; + case 'sjis': + return g.BOARD.ID === 'jp'; } })(); if (!supported) { diff --git a/builds/4chan-X.crx b/builds/4chan-X.crx index 18c777c79..5e003b7e9 100644 Binary files a/builds/4chan-X.crx and b/builds/4chan-X.crx differ diff --git a/builds/4chan-X.meta.js b/builds/4chan-X.meta.js index 594ee7343..b82e27011 100644 --- a/builds/4chan-X.meta.js +++ b/builds/4chan-X.meta.js @@ -1,6 +1,6 @@ // ==UserScript== // @name 4chan X -// @version 1.11.12.6 +// @version 1.11.12.7 // @minGMVer 1.14 // @minFFVer 26 // @namespace 4chan-X diff --git a/builds/4chan-X.user.js b/builds/4chan-X.user.js index f03b7f849..18c1fa8e8 100644 --- a/builds/4chan-X.user.js +++ b/builds/4chan-X.user.js @@ -1,7 +1,7 @@ // Generated by CoffeeScript // ==UserScript== // @name 4chan X -// @version 1.11.12.6 +// @version 1.11.12.7 // @minGMVer 1.14 // @minFFVer 26 // @namespace 4chan-X @@ -356,6 +356,7 @@ 'Code tags': ['Alt+c', 'Insert code tags.'], 'Eqn tags': ['Alt+e', 'Insert eqn tags.'], 'Math tags': ['Alt+m', 'Insert math tags.'], + 'SJIS tags': ['Alt+a', 'Insert SJIS tags.'], 'Toggle sage': ['Alt+s', 'Toggle sage in options field.'], 'Submit QR': ['Ctrl+Enter', 'Submit post.'], 'Watch': ['w', 'Watch thread.'], @@ -413,7 +414,7 @@ doc = d.documentElement; g = { - VERSION: '1.11.12.6', + VERSION: '1.11.12.7', NAMESPACE: '4chan X.', boards: {} }; @@ -7230,8 +7231,8 @@ counter = QR.nodes.charCount; count = QR.nodes.com.value.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g, '_').length; counter.textContent = count; - counter.hidden = count < 1000; - return (count > 2000 ? $.addClass : $.rmClass)(counter, 'warning'); + counter.hidden = count < QR.max_comment / 2; + return (count > QR.max_comment ? $.addClass : $.rmClass)(counter, 'warning'); }, getFile: function() { var ref; @@ -7399,7 +7400,7 @@ return (g.VIEW === 'thread' ? $.addClass : $.rmClass)(QR.nodes.el, 'reply-to-thread'); }, dialog: function() { - var dialog, event, i, items, m, match_max, match_min, name, node, nodes, ref, rules, save, setNode; + var dialog, event, i, items, m, match_max, match_min, name, node, nodes, ref, rules, save, scriptData, setNode; QR.nodes = nodes = { el: dialog = UI.dialog('qr', 'top: 50px; right: 0px;', { innerHTML: " " @@ -7442,7 +7443,9 @@ QR.max_width = +(match_max != null ? match_max[1] : void 0) || 10000; QR.max_height = +(match_max != null ? match_max[2] : void 0) || 10000; nodes.fileInput.max = $('input[name=MAX_FILE_SIZE]').value; - QR.max_size_video = (m = Get.scriptData().match(/\bmaxWebmFilesize *= *(\d+)\b/)) ? +m[1] : +nodes.fileInput.max; + scriptData = Get.scriptData(); + QR.max_size_video = (m = scriptData.match(/\bmaxWebmFilesize *= *(\d+)\b/)) ? +m[1] : +nodes.fileInput.max; + QR.max_comment = (m = scriptData.match(/\bcomlen *= *(\d+)\b/)) ? +m[1] : 2000; QR.max_width_video = QR.max_height_video = 2048; QR.max_duration_video = (ref = g.BOARD.ID) === 'gif' || ref === 'wsg' ? 300 : 120; if (Conf['Show New Thread Option in Threads']) { @@ -15654,6 +15657,12 @@ } Keybinds.tags('math', target); break; + case Conf['SJIS tags']: + if (target.nodeName !== 'TEXTAREA') { + return; + } + Keybinds.tags('sjis', target); + break; case Conf['Toggle sage']: if (!(QR.nodes && !QR.nodes.el.hidden)) { return; @@ -15942,6 +15951,8 @@ case 'math': case 'eqn': return g.BOARD.ID === 'sci'; + case 'sjis': + return g.BOARD.ID === 'jp'; } })(); if (!supported) { diff --git a/builds/4chan-X.zip b/builds/4chan-X.zip index 71051b887..9cc4ef2d2 100644 Binary files a/builds/4chan-X.zip and b/builds/4chan-X.zip differ diff --git a/builds/updates-beta.xml b/builds/updates-beta.xml index 672a5edad..401c849a4 100644 --- a/builds/updates-beta.xml +++ b/builds/updates-beta.xml @@ -1,7 +1,7 @@