Release 4chan X v1.11.2.0.
This commit is contained in:
parent
72d59eaf27
commit
c448ed5a60
@ -2,6 +2,14 @@ Sometimes the changelog has notes (not comprehensive) acknowledging people's wor
|
|||||||
|
|
||||||
The links to individual versions below are to copies of the script with the update URL removed. If you want automatic updates, install the script from the links on the [main page](https://github.com/ccd0/4chan-x).
|
The links to individual versions below are to copies of the script with the update URL removed. If you want automatic updates, install the script from the links on the [main page](https://github.com/ccd0/4chan-x).
|
||||||
|
|
||||||
|
### v1.11.2
|
||||||
|
|
||||||
|
**v1.11.2.0** *(2015-06-29)* - [[Firefox](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.2.0/builds/4chan-X-noupdate.user.js "Firefox version")] [[Chromium](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.2.0/builds/4chan-X-noupdate.crx "Chromium version")]
|
||||||
|
- Based on v1.11.1.3.
|
||||||
|
- `Use Recaptcha v1` option now works on the original post form.
|
||||||
|
- Captcha section of QR can now be opened with the space bar.
|
||||||
|
- Minor bugfixes.
|
||||||
|
|
||||||
### v1.11.1
|
### v1.11.1
|
||||||
|
|
||||||
**v1.11.1.3** *(2015-06-26)* - [[Firefox](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.1.3/builds/4chan-X-noupdate.user.js "Firefox version")] [[Chromium](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.1.3/builds/4chan-X-noupdate.crx "Chromium version")]
|
**v1.11.1.3** *(2015-06-26)* - [[Firefox](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.1.3/builds/4chan-X-noupdate.user.js "Firefox version")] [[Chromium](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.1.3/builds/4chan-X-noupdate.crx "Chromium version")]
|
||||||
|
|||||||
Binary file not shown.
@ -1,6 +1,6 @@
|
|||||||
// ==UserScript==
|
// ==UserScript==
|
||||||
// @name 4chan X beta
|
// @name 4chan X beta
|
||||||
// @version 1.11.1.3
|
// @version 1.11.2.0
|
||||||
// @minGMVer 1.14
|
// @minGMVer 1.14
|
||||||
// @minFFVer 26
|
// @minFFVer 26
|
||||||
// @namespace 4chan-X
|
// @namespace 4chan-X
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
// Generated by CoffeeScript
|
// Generated by CoffeeScript
|
||||||
// ==UserScript==
|
// ==UserScript==
|
||||||
// @name 4chan X beta
|
// @name 4chan X beta
|
||||||
// @version 1.11.1.3
|
// @version 1.11.2.0
|
||||||
// @minGMVer 1.14
|
// @minGMVer 1.14
|
||||||
// @minFFVer 26
|
// @minFFVer 26
|
||||||
// @namespace 4chan-X
|
// @namespace 4chan-X
|
||||||
@ -242,12 +242,12 @@
|
|||||||
'Hide Original Post Form': [true, 'Hide the normal post form.', 1],
|
'Hide Original Post Form': [true, 'Hide the normal post form.', 1],
|
||||||
'Cooldown': [true, 'Indicate the remaining time before posting again.', 1],
|
'Cooldown': [true, 'Indicate the remaining time before posting again.', 1],
|
||||||
'Posting Success Notifications': [true, 'Show notifications on successful post creation or file uploading.', 1],
|
'Posting Success Notifications': [true, 'Show notifications on successful post creation or file uploading.', 1],
|
||||||
'Use Recaptcha v1': [false, 'Use the old text version of Recaptcha.', 1],
|
|
||||||
'Force Noscript Captcha': [false, 'Use the non-Javascript fallback captcha in the QR even if Javascript is enabled.', 1],
|
'Force Noscript Captcha': [false, 'Use the non-Javascript fallback captcha in the QR even if Javascript is enabled.', 1],
|
||||||
'Auto-load captcha': [false, 'Automatically load the captcha in the QR even if your post is empty.', 1],
|
'Auto-load captcha': [false, 'Automatically load the captcha in the QR even if your post is empty.', 1],
|
||||||
'Post on Captcha Completion': [false, 'Submit the post immediately when the captcha is completed.', 1],
|
'Post on Captcha Completion': [false, 'Submit the post immediately when the captcha is completed.', 1],
|
||||||
'Bottom QR Link': [true, 'Places a link on the bottom of threads to open the QR.', 1],
|
'Bottom QR Link': [true, 'Places a link on the bottom of threads to open the QR.', 1],
|
||||||
'Captcha Fixes': [true, 'Make captcha easier to use, especially with the keyboard.'],
|
'Captcha Fixes': [true, 'Make captcha easier to use, especially with the keyboard.'],
|
||||||
|
'Use Recaptcha v1': [false, 'Use the old text version of Recaptcha.'],
|
||||||
'Use Recaptcha v2 in Reports': [false, 'Use the image selection captcha in the report window.']
|
'Use Recaptcha v2 in Reports': [false, 'Use the image selection captcha in the report window.']
|
||||||
},
|
},
|
||||||
'Quote Links': {
|
'Quote Links': {
|
||||||
@ -299,7 +299,7 @@
|
|||||||
tripcode: "# Filter any tripfag\n#/^!/",
|
tripcode: "# Filter any tripfag\n#/^!/",
|
||||||
capcode: "# Set a custom class for mods:\n#/Mod$/;highlight:mod;op:yes\n# Set a custom class for moot:\n#/Admin$/;highlight:moot;op:yes",
|
capcode: "# Set a custom class for mods:\n#/Mod$/;highlight:mod;op:yes\n# Set a custom class for moot:\n#/Admin$/;highlight:moot;op:yes",
|
||||||
subject: "# Filter Generals on /v/:\n#/general/i;boards:v;op:only",
|
subject: "# Filter Generals on /v/:\n#/general/i;boards:v;op:only",
|
||||||
comment: "# Filter Stallman copypasta on /g/:\n#/what you\'re refer+ing to as linux/i;boards:g",
|
comment: "# Filter Stallman copypasta on /g/:\n#/what you\'re refer+ing to as linux/i;boards:g\n# Filter posts with 10 or more quote links:\n#/(?:>>\\d(?:(?!>>\\d)[^])*){10}/",
|
||||||
flag: '',
|
flag: '',
|
||||||
filename: '',
|
filename: '',
|
||||||
dimensions: "# Highlight potential wallpapers:\n#/1920x1080/;op:yes;highlight;top:no;boards:w,wg",
|
dimensions: "# Highlight potential wallpapers:\n#/1920x1080/;op:yes;highlight;top:no;boards:w,wg",
|
||||||
@ -411,7 +411,7 @@
|
|||||||
doc = d.documentElement;
|
doc = d.documentElement;
|
||||||
|
|
||||||
g = {
|
g = {
|
||||||
VERSION: '1.11.1.3',
|
VERSION: '1.11.2.0',
|
||||||
NAMESPACE: '4chan X.',
|
NAMESPACE: '4chan X.',
|
||||||
boards: {}
|
boards: {}
|
||||||
};
|
};
|
||||||
@ -1523,7 +1523,6 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
Post.prototype.collect = function() {
|
Post.prototype.collect = function() {
|
||||||
this.kill();
|
|
||||||
g.posts.rm(this.fullID);
|
g.posts.rm(this.fullID);
|
||||||
this.thread.posts.rm(this);
|
this.thread.posts.rm(this);
|
||||||
return this.board.posts.rm(this);
|
return this.board.posts.rm(this);
|
||||||
@ -6956,24 +6955,26 @@
|
|||||||
return alert(el.textContent);
|
return alert(el.textContent);
|
||||||
}
|
}
|
||||||
} else if (d.hidden || !(focusOverride || d.hasFocus())) {
|
} else if (d.hidden || !(focusOverride || d.hasFocus())) {
|
||||||
notif = new Notification(el.textContent, {
|
try {
|
||||||
body: el.textContent,
|
notif = new Notification(el.textContent, {
|
||||||
icon: Favicon.logo
|
body: el.textContent,
|
||||||
});
|
icon: Favicon.logo
|
||||||
notif.onclick = function() {
|
});
|
||||||
return window.focus();
|
notif.onclick = function() {
|
||||||
};
|
return window.focus();
|
||||||
if (typeof chrome !== "undefined" && chrome !== null) {
|
|
||||||
notif.onclose = function() {
|
|
||||||
return notice.close();
|
|
||||||
};
|
};
|
||||||
return notif.onshow = function() {
|
if (typeof chrome !== "undefined" && chrome !== null) {
|
||||||
return setTimeout(function() {
|
notif.onclose = function() {
|
||||||
notif.onclose = null;
|
return notice.close();
|
||||||
return notif.close();
|
};
|
||||||
}, 7 * $.SECOND);
|
return notif.onshow = function() {
|
||||||
};
|
return setTimeout(function() {
|
||||||
}
|
notif.onclose = null;
|
||||||
|
return notif.close();
|
||||||
|
}, 7 * $.SECOND);
|
||||||
|
};
|
||||||
|
}
|
||||||
|
} catch (_error) {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
notifications: [],
|
notifications: [],
|
||||||
@ -7820,33 +7821,6 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
Captcha.language = {
|
|
||||||
init: function() {
|
|
||||||
if (!(Conf['captchaLanguage'].trim() && d.cookie.indexOf('pass_enabled=1') < 0 && !Conf['Hide Original Post Form'])) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
return $.onExists(doc, '#captchaFormPart', true, function(node) {
|
|
||||||
return $.onExists(node, 'iframe', true, Captcha.language.fixIframe);
|
|
||||||
});
|
|
||||||
},
|
|
||||||
fixPage: function() {
|
|
||||||
if (!(Conf['captchaLanguage'].trim() && d.cookie.indexOf('pass_enabled=1') < 0)) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
return $.onExists(doc, 'iframe', true, Captcha.language.fixIframe);
|
|
||||||
},
|
|
||||||
fixIframe: function(el) {
|
|
||||||
var lang, src;
|
|
||||||
if (!(lang = Conf['captchaLanguage'].trim())) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
src = /[?&]hl=/.test(el.src) ? el.src.replace(/([?&]hl=)[^&]*/, '$1' + encodeURIComponent(lang)) : el.src + ("&hl=" + (encodeURIComponent(lang)));
|
|
||||||
if (el.src !== src) {
|
|
||||||
return el.src = src;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
Captcha.noscript = {
|
Captcha.noscript = {
|
||||||
lifetime: 30 * $.MINUTE,
|
lifetime: 30 * $.MINUTE,
|
||||||
init: function() {
|
init: function() {
|
||||||
@ -7854,7 +7828,7 @@
|
|||||||
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!(this.isEnabled = !!$.id('g-recaptcha'))) {
|
if (!(this.isEnabled = !!$('#g-recaptcha, #captchaContainerAlt'))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
container = $.el('div', {
|
container = $.el('div', {
|
||||||
@ -8182,24 +8156,97 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
Captcha.v1 = {
|
Captcha.replace = {
|
||||||
init: function() {
|
init: function() {
|
||||||
var captchaContainer, imgContainer, input, script;
|
var jsEnabled;
|
||||||
|
if (!(d.cookie.indexOf('pass_enabled=1') < 0)) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (location.hostname === 'boards.4chan.org' && Conf['Hide Original Post Form']) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
jsEnabled = $.hasClass(doc, 'js-enabled');
|
||||||
|
if (location.hostname === 'sys.4chan.org' && Conf['Use Recaptcha v2 in Reports'] && jsEnabled) {
|
||||||
|
$.ready(Captcha.replace.v2);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (Conf['Use Recaptcha v1'] && jsEnabled && location.hostname !== 'www.4chan.org') {
|
||||||
|
$.ready(Captcha.replace.v1);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (Conf['captchaLanguage'].trim()) {
|
||||||
|
if (location.hostname === 'boards.4chan.org') {
|
||||||
|
return $.onExists(doc, '#captchaFormPart', true, function(node) {
|
||||||
|
return $.onExists(node, 'iframe', true, Captcha.replace.iframe);
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
return $.onExists(doc, 'iframe', true, Captcha.replace.iframe);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
v1: function() {
|
||||||
|
var form, link;
|
||||||
|
if (!$.id('g-recaptcha')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
Captcha.v1.replace();
|
||||||
|
if (link = $.id('form-link')) {
|
||||||
|
return $.on(link, 'click', function() {
|
||||||
|
return Captcha.v1.create();
|
||||||
|
});
|
||||||
|
} else if (location.hostname === 'boards.4chan.org') {
|
||||||
|
form = $.id('postForm');
|
||||||
|
return form.addEventListener('focus', (function() {
|
||||||
|
return Captcha.v1.create();
|
||||||
|
}), true);
|
||||||
|
} else {
|
||||||
|
return Captcha.v1.create();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
v2: function() {
|
||||||
|
var container, lang, old, script, url;
|
||||||
|
if (!(old = $.id('captchaContainerAlt'))) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
container = $.el('div', {
|
||||||
|
className: 'g-recaptcha'
|
||||||
|
});
|
||||||
|
$.extend(container.dataset, {
|
||||||
|
sitekey: '6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc',
|
||||||
|
tabindex: 3
|
||||||
|
});
|
||||||
|
$.replace(old, container);
|
||||||
|
url = 'https://www.google.com/recaptcha/api.js';
|
||||||
|
if (lang = Conf['captchaLanguage'].trim()) {
|
||||||
|
url += "?hl=" + (encodeURIComponent(lang));
|
||||||
|
}
|
||||||
|
script = $.el('script', {
|
||||||
|
src: url
|
||||||
|
});
|
||||||
|
return $.add(d.head, script);
|
||||||
|
},
|
||||||
|
iframe: function(el) {
|
||||||
|
var lang, src;
|
||||||
|
if (!(lang = Conf['captchaLanguage'].trim())) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
src = /[?&]hl=/.test(el.src) ? el.src.replace(/([?&]hl=)[^&]*/, '$1' + encodeURIComponent(lang)) : el.src + ("&hl=" + (encodeURIComponent(lang)));
|
||||||
|
if (el.src !== src) {
|
||||||
|
return el.src = src;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
Captcha.v1 = {
|
||||||
|
blank: "data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='300' height='57'/>",
|
||||||
|
init: function() {
|
||||||
|
var imgContainer, input;
|
||||||
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!(this.isEnabled = !!$.id('g-recaptcha'))) {
|
if (!(this.isEnabled = !!$('#g-recaptcha, #captchaContainerAlt'))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
script = $.el('script', {
|
|
||||||
src: '//www.google.com/recaptcha/api/js/recaptcha_ajax.js'
|
|
||||||
});
|
|
||||||
$.add(d.head, script);
|
|
||||||
captchaContainer = $.el('div', {
|
|
||||||
id: 'captchaContainer',
|
|
||||||
hidden: true
|
|
||||||
});
|
|
||||||
$.add(d.body, captchaContainer);
|
|
||||||
imgContainer = $.el('div', {
|
imgContainer = $.el('div', {
|
||||||
className: 'captcha-img',
|
className: 'captcha-img',
|
||||||
title: 'Reload reCAPTCHA'
|
title: 'Reload reCAPTCHA'
|
||||||
@ -8231,13 +8278,36 @@
|
|||||||
return QR.captcha.clear();
|
return QR.captcha.clear();
|
||||||
});
|
});
|
||||||
$.sync('captchas', this.sync);
|
$.sync('captchas', this.sync);
|
||||||
new MutationObserver(this.afterSetup).observe($.id('captchaContainer'), {
|
|
||||||
childList: true
|
|
||||||
});
|
|
||||||
this.beforeSetup();
|
this.beforeSetup();
|
||||||
if (Conf['Auto-load captcha']) {
|
if (Conf['Auto-load captcha']) {
|
||||||
return this.setup();
|
this.setup();
|
||||||
}
|
}
|
||||||
|
new MutationObserver(this.afterSetup).observe($.id('captchaContainerAlt'), {
|
||||||
|
childList: true
|
||||||
|
});
|
||||||
|
return this.afterSetup();
|
||||||
|
},
|
||||||
|
replace: function() {
|
||||||
|
var container, old;
|
||||||
|
if (this.script) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (!(this.script = $('script[src="//www.google.com/recaptcha/api/js/recaptcha_ajax.js"]', d.head))) {
|
||||||
|
this.script = $.el('script', {
|
||||||
|
src: '//www.google.com/recaptcha/api/js/recaptcha_ajax.js'
|
||||||
|
});
|
||||||
|
$.add(d.head, this.script);
|
||||||
|
}
|
||||||
|
if (old = $.id('g-recaptcha')) {
|
||||||
|
container = $.el('div', {
|
||||||
|
id: 'captchaContainerAlt'
|
||||||
|
});
|
||||||
|
return $.replace(old, container);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
create: function() {
|
||||||
|
this.replace();
|
||||||
|
return $.globalEval('(function() {\n var container = document.getElementById("captchaContainerAlt");\n if (container.firstChild) return;\n var options = {\n theme: "clean",\n tabindex: {"boards.4chan.org": 5, "sys.4chan.org": 3}[location.hostname]\n };\n if (window.Recaptcha) {\n window.Recaptcha.create("6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc", container, options);\n } else {\n var script = document.head.querySelector(\'script[src="//www.google.com/recaptcha/api/js/recaptcha_ajax.js"]\');\n script.addEventListener(\'load\', function() {\n window.Recaptcha.create("6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc", container, options);\n }, false);\n }\n})();');
|
||||||
},
|
},
|
||||||
cb: {
|
cb: {
|
||||||
focus: function() {
|
focus: function() {
|
||||||
@ -8248,6 +8318,7 @@
|
|||||||
var img, input, ref;
|
var img, input, ref;
|
||||||
ref = this.nodes, img = ref.img, input = ref.input;
|
ref = this.nodes, img = ref.img, input = ref.input;
|
||||||
img.parentNode.hidden = true;
|
img.parentNode.hidden = true;
|
||||||
|
img.src = this.blank;
|
||||||
input.value = '';
|
input.value = '';
|
||||||
input.placeholder = 'Focus to load reCAPTCHA';
|
input.placeholder = 'Focus to load reCAPTCHA';
|
||||||
this.count();
|
this.count();
|
||||||
@ -8268,10 +8339,10 @@
|
|||||||
onNewPost: function() {},
|
onNewPost: function() {},
|
||||||
onPostChange: function() {},
|
onPostChange: function() {},
|
||||||
setup: function(focus, force) {
|
setup: function(focus, force) {
|
||||||
if (!(this.isEnabled && (this.needed() || force))) {
|
if (!(this.isEnabled && (force || this.needed()))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$.globalEval('(function() {\n var captchaContainer = document.getElementById("captchaContainer");\n if (captchaContainer.firstChild) return;\n function setup() {\n if (window.Recaptcha) {\n Recaptcha.create(recaptchaKey, captchaContainer, {theme: "clean"});\n } else {\n setTimeout(setup, 25);\n }\n }\n setup();\n})()');
|
this.create();
|
||||||
if (focus) {
|
if (focus) {
|
||||||
return this.nodes.input.focus();
|
return this.nodes.input.focus();
|
||||||
}
|
}
|
||||||
@ -8308,11 +8379,13 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
destroy: function() {
|
destroy: function() {
|
||||||
if (!this.isEnabled) {
|
if (!this.script) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$.globalEval('Recaptcha.destroy()');
|
$.globalEval('window.Recaptcha.destroy();');
|
||||||
return this.beforeSetup();
|
if (this.nodes) {
|
||||||
|
return this.beforeSetup();
|
||||||
|
}
|
||||||
},
|
},
|
||||||
sync: function(captchas) {
|
sync: function(captchas) {
|
||||||
if (captchas == null) {
|
if (captchas == null) {
|
||||||
@ -8380,6 +8453,10 @@
|
|||||||
},
|
},
|
||||||
load: function() {
|
load: function() {
|
||||||
var challenge, challenge_image;
|
var challenge, challenge_image;
|
||||||
|
if ($('#captchaContainerAlt[class~="recaptcha_is_showing_audio"]')) {
|
||||||
|
this.nodes.img.src = this.blank;
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (!this.nodes.challenge.firstChild) {
|
if (!this.nodes.challenge.firstChild) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -8390,7 +8467,7 @@
|
|||||||
challenge = this.nodes.challenge.firstChild.value;
|
challenge = this.nodes.challenge.firstChild.value;
|
||||||
this.nodes.img.alt = challenge;
|
this.nodes.img.alt = challenge;
|
||||||
this.nodes.img.src = challenge_image.src;
|
this.nodes.img.src = challenge_image.src;
|
||||||
this.nodes.input.value = null;
|
this.nodes.input.value = '';
|
||||||
return this.clear();
|
return this.clear();
|
||||||
},
|
},
|
||||||
count: function() {
|
count: function() {
|
||||||
@ -8416,7 +8493,7 @@
|
|||||||
return this.nodes.input.alt = count;
|
return this.nodes.input.alt = count;
|
||||||
},
|
},
|
||||||
reload: function(focus) {
|
reload: function(focus) {
|
||||||
$.globalEval('Recaptcha.reload(); Recaptcha.should_focus = false;');
|
$.globalEval('if (window.Recaptcha.type === "image") {\n window.Recaptcha.reload();\n} else {\n window.Recaptcha.switch_type("image");\n}\nwindow.Recaptcha.should_focus = false;');
|
||||||
if (focus) {
|
if (focus) {
|
||||||
return this.nodes.input.focus();
|
return this.nodes.input.focus();
|
||||||
}
|
}
|
||||||
@ -8440,7 +8517,7 @@
|
|||||||
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!(this.isEnabled = !!$.id('g-recaptcha'))) {
|
if (!(this.isEnabled = !!$('#g-recaptcha, #captchaContainerAlt'))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (this.noscript = Conf['Force Noscript Captcha'] || !$.hasClass(doc, 'js-enabled')) {
|
if (this.noscript = Conf['Force Noscript Captcha'] || !$.hasClass(doc, 'js-enabled')) {
|
||||||
@ -8475,6 +8552,16 @@
|
|||||||
$.addClass(QR.nodes.el, 'has-captcha', 'captcha-v2');
|
$.addClass(QR.nodes.el, 'has-captcha', 'captcha-v2');
|
||||||
$.after(QR.nodes.com.parentNode, root);
|
$.after(QR.nodes.com.parentNode, root);
|
||||||
$.on(counter, 'click', this.toggle.bind(this));
|
$.on(counter, 'click', this.toggle.bind(this));
|
||||||
|
$.on(counter, 'keydown', (function(_this) {
|
||||||
|
return function(e) {
|
||||||
|
if (Keybinds.keyCode(e) !== 'Space') {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
_this.toggle();
|
||||||
|
e.preventDefault();
|
||||||
|
return e.stopPropagation();
|
||||||
|
};
|
||||||
|
})(this));
|
||||||
return $.on(window, 'captcha:success', (function(_this) {
|
return $.on(window, 'captcha:success', (function(_this) {
|
||||||
return function() {
|
return function() {
|
||||||
return $.queueTask(function() {
|
return $.queueTask(function() {
|
||||||
@ -8597,7 +8684,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
setupIFrame: function(iframe) {
|
setupIFrame: function(iframe) {
|
||||||
Captcha.language.fixIframe(iframe);
|
Captcha.replace.iframe(iframe);
|
||||||
$.addClass(QR.nodes.el, 'captcha-open');
|
$.addClass(QR.nodes.el, 'captcha-open');
|
||||||
if (QR.nodes.el.getBoundingClientRect().bottom > doc.clientHeight) {
|
if (QR.nodes.el.getBoundingClientRect().bottom > doc.clientHeight) {
|
||||||
QR.nodes.el.style.top = null;
|
QR.nodes.el.style.top = null;
|
||||||
@ -13912,19 +13999,21 @@
|
|||||||
if (!Header.areNotificationsEnabled) {
|
if (!Header.areNotificationsEnabled) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
notif = new Notification(post.info.nameBlock + " replied to you", {
|
try {
|
||||||
body: post.info.commentDisplay,
|
notif = new Notification(post.info.nameBlock + " replied to you", {
|
||||||
icon: Favicon.logo
|
body: post.info.commentDisplay,
|
||||||
});
|
icon: Favicon.logo
|
||||||
notif.onclick = function() {
|
});
|
||||||
Header.scrollToIfNeeded(post.nodes.root, true);
|
notif.onclick = function() {
|
||||||
return window.focus();
|
Header.scrollToIfNeeded(post.nodes.root, true);
|
||||||
};
|
return window.focus();
|
||||||
return notif.onshow = function() {
|
};
|
||||||
return setTimeout(function() {
|
return notif.onshow = function() {
|
||||||
return notif.close();
|
return setTimeout(function() {
|
||||||
}, 7 * $.SECOND);
|
return notif.close();
|
||||||
};
|
}, 7 * $.SECOND);
|
||||||
|
};
|
||||||
|
} catch (_error) {}
|
||||||
},
|
},
|
||||||
onUpdate: function(e) {
|
onUpdate: function(e) {
|
||||||
if (!e.detail[404]) {
|
if (!e.detail[404]) {
|
||||||
@ -15905,21 +15994,18 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
Report = {
|
Report = {
|
||||||
css: "noscript > div, noscript > div > div {\n" +
|
css: ":root:not(.js-enabled) #captchaContainerAlt {\n" +
|
||||||
" height: 545px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"noscript > div > div > div:first-child, noscript iframe {\n" +
|
|
||||||
" height: 423px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
":root:not(.js-enabled) #g-recaptcha {\n" +
|
|
||||||
" height: auto;\n" +
|
" height: auto;\n" +
|
||||||
|
"}\n" +
|
||||||
|
"noscript > iframe, #recaptcha_challenge_field {\n" +
|
||||||
|
" width: 500px;\n" +
|
||||||
"}",
|
"}",
|
||||||
init: function() {
|
init: function() {
|
||||||
var match;
|
var match;
|
||||||
if (!(/\bmode=report\b/.test(location.search) && (match = location.search.match(/\bno=(\d+)/)))) {
|
if (!(/\bmode=report\b/.test(location.search) && (match = location.search.match(/\bno=(\d+)/)))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
Captcha.language.fixPage();
|
Captcha.replace.init();
|
||||||
this.postID = +match[1];
|
this.postID = +match[1];
|
||||||
return $.ready(this.ready);
|
return $.ready(this.ready);
|
||||||
},
|
},
|
||||||
@ -15928,9 +16014,6 @@
|
|||||||
if (Conf['Archive Report']) {
|
if (Conf['Archive Report']) {
|
||||||
Report.archive();
|
Report.archive();
|
||||||
}
|
}
|
||||||
if (Conf['Use Recaptcha v2 in Reports']) {
|
|
||||||
Report.captchaV2();
|
|
||||||
}
|
|
||||||
if (Conf['Use Recaptcha v2 in Reports'] && $.hasClass(doc, 'js-enabled')) {
|
if (Conf['Use Recaptcha v2 in Reports'] && $.hasClass(doc, 'js-enabled')) {
|
||||||
return new MutationObserver(function() {
|
return new MutationObserver(function() {
|
||||||
return Report.fit('.gc-bubbleDefault');
|
return Report.fit('.gc-bubbleDefault');
|
||||||
@ -15943,25 +16026,6 @@
|
|||||||
return Report.fit('body');
|
return Report.fit('body');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
captchaV2: function() {
|
|
||||||
var container, lang, old, script, url;
|
|
||||||
if (!(old = $.id('captchaContainerAlt'))) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
container = $.el('div', {
|
|
||||||
className: 'g-recaptcha'
|
|
||||||
});
|
|
||||||
container.dataset.sitekey = '6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc';
|
|
||||||
$.replace(old, container);
|
|
||||||
url = 'https://www.google.com/recaptcha/api.js';
|
|
||||||
if (lang = Conf['captchaLanguage'].trim()) {
|
|
||||||
url += "?hl=" + (encodeURIComponent(lang));
|
|
||||||
}
|
|
||||||
script = $.el('script', {
|
|
||||||
src: url
|
|
||||||
});
|
|
||||||
return $.add(d.head, script);
|
|
||||||
},
|
|
||||||
fit: function(selector) {
|
fit: function(selector) {
|
||||||
var dy, el;
|
var dy, el;
|
||||||
if (!(el = $(selector, doc))) {
|
if (!(el = $(selector, doc))) {
|
||||||
@ -16830,19 +16894,6 @@
|
|||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (location.hostname === 'www.4chan.org') {
|
|
||||||
$.onExists(d.documentElement, 'body', false, function() {
|
|
||||||
return $.addStyle(Main.cssWWW);
|
|
||||||
});
|
|
||||||
Conf = {
|
|
||||||
'captchaLanguage': Config.captchaLanguage
|
|
||||||
};
|
|
||||||
$.get(Conf, function(items) {
|
|
||||||
$.extend(Conf, items);
|
|
||||||
return Captcha.language.fixPage();
|
|
||||||
});
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
g.threads = new SimpleDict();
|
g.threads = new SimpleDict();
|
||||||
g.posts = new SimpleDict();
|
g.posts = new SimpleDict();
|
||||||
pathname = location.pathname.split('/');
|
pathname = location.pathname.split('/');
|
||||||
@ -16911,10 +16962,13 @@
|
|||||||
},
|
},
|
||||||
initFeatures: function() {
|
initFeatures: function() {
|
||||||
var err, feature, k, len1, name, pathname, ref, ref1, ref2;
|
var err, feature, k, len1, name, pathname, ref, ref1, ref2;
|
||||||
if ((ref = location.hostname) === 'boards.4chan.org' || ref === 'sys.4chan.org') {
|
if ((ref = location.hostname) === 'boards.4chan.org' || ref === 'sys.4chan.org' || ref === 'www.4chan.org') {
|
||||||
$.globalEval('document.documentElement.classList.add("js-enabled");');
|
$.globalEval('document.documentElement.classList.add("js-enabled");');
|
||||||
}
|
}
|
||||||
switch (location.hostname) {
|
switch (location.hostname) {
|
||||||
|
case 'www.4chan.org':
|
||||||
|
Captcha.replace.init();
|
||||||
|
return;
|
||||||
case 'a.4cdn.org':
|
case 'a.4cdn.org':
|
||||||
return;
|
return;
|
||||||
case 'sys.4chan.org':
|
case 'sys.4chan.org':
|
||||||
@ -16974,6 +17028,9 @@
|
|||||||
},
|
},
|
||||||
initStyle: function() {
|
initStyle: function() {
|
||||||
var keyboard, ref;
|
var keyboard, ref;
|
||||||
|
if (location.hostname === 'www.4chan.org') {
|
||||||
|
$.addStyle(Main.cssWWW);
|
||||||
|
}
|
||||||
if (!Main.isThisPageLegit() || $.hasClass(doc, 'fourchan-x')) {
|
if (!Main.isThisPageLegit() || $.hasClass(doc, 'fourchan-x')) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -17802,15 +17859,6 @@
|
|||||||
" 0% {transform:rotate(0deg);}\n" +
|
" 0% {transform:rotate(0deg);}\n" +
|
||||||
" 100% {transform:rotate(359deg);}\n" +
|
" 100% {transform:rotate(359deg);}\n" +
|
||||||
"}\n" +
|
"}\n" +
|
||||||
"noscript > div, noscript > div > div {\n" +
|
|
||||||
" height: 545px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"noscript > div > div > div:first-child, noscript iframe {\n" +
|
|
||||||
" height: 423px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
":root:not(.js-enabled) #g-recaptcha {\n" +
|
|
||||||
" height: auto;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"/* General */\n" +
|
"/* General */\n" +
|
||||||
".dialog {\n" +
|
".dialog {\n" +
|
||||||
" border: 1px solid;\n" +
|
" border: 1px solid;\n" +
|
||||||
@ -17920,6 +17968,9 @@
|
|||||||
":root:not(.js-enabled) #postForm {\n" +
|
":root:not(.js-enabled) #postForm {\n" +
|
||||||
" display: table;\n" +
|
" display: table;\n" +
|
||||||
"}\n" +
|
"}\n" +
|
||||||
|
"#captchaContainerAlt td:nth-child(2) {\n" +
|
||||||
|
" display: table-cell !important;\n" +
|
||||||
|
"}\n" +
|
||||||
"/* Anti-autoplay */\n" +
|
"/* Anti-autoplay */\n" +
|
||||||
"audio.controls-added {\n" +
|
"audio.controls-added {\n" +
|
||||||
" display: block;\n" +
|
" display: block;\n" +
|
||||||
@ -20217,19 +20268,10 @@
|
|||||||
" font-family: sans-serif !important;\n" +
|
" font-family: sans-serif !important;\n" +
|
||||||
" text-shadow: 1px 1px 1px rgba(0,74,153,0.6);\n" +
|
" text-shadow: 1px 1px 1px rgba(0,74,153,0.6);\n" +
|
||||||
"}",
|
"}",
|
||||||
cssWWW: "noscript > div, noscript > div > div {\n" +
|
cssWWW: "#captcha-cnt {\n" +
|
||||||
" height: 545px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"noscript > div > div > div:first-child, noscript iframe {\n" +
|
|
||||||
" height: 423px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
":root:not(.js-enabled) #g-recaptcha {\n" +
|
|
||||||
" height: auto;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"#captcha-cnt {\n" +
|
|
||||||
" height: auto;\n" +
|
" height: auto;\n" +
|
||||||
"}",
|
"}",
|
||||||
features: [['Polyfill', Polyfill], ['Captcha Language', Captcha.language], ['Redirect', Redirect], ['Header', Header], ['Catalog Links', CatalogLinks], ['Settings', Settings], ['Index Generator', Index], ['Disable Autoplay', AntiAutoplay], ['Announcement Hiding', PSAHiding], ['Fourchan thingies', Fourchan], ['Color User IDs', IDColor], ['Highlight by User ID', IDHighlight], ['Custom CSS', CustomCSS], ['Linkify', Linkify], ['Reveal Spoilers', RemoveSpoilers], ['Resurrect Quotes', Quotify], ['Filter', Filter], ['Thread Hiding Buttons', ThreadHiding], ['Reply Hiding Buttons', PostHiding], ['Recursive', Recursive], ['Strike-through Quotes', QuoteStrikeThrough], ['Quick Reply', QR], ['Menu', Menu], ['Index Generator (Menu)', Index.menu], ['Report Link', ReportLink], ['Thread Hiding (Menu)', ThreadHiding.menu], ['Reply Hiding (Menu)', PostHiding.menu], ['Delete Link', DeleteLink], ['Filter (Menu)', Filter.menu], ['Download Link', DownloadLink], ['Archive Link', ArchiveLink], ['Quote Inlining', QuoteInline], ['Quote Previewing', QuotePreview], ['Quote Backlinks', QuoteBacklink], ['Mark Quotes of You', QuoteYou], ['Mark OP Quotes', QuoteOP], ['Mark Cross-thread Quotes', QuoteCT], ['Anonymize', Anonymize], ['Time Formatting', Time], ['Relative Post Dates', RelativeDates], ['File Info Formatting', FileInfo], ['Fappe Tyme', FappeTyme], ['Gallery', Gallery], ['Gallery (menu)', Gallery.menu], ['Sauce', Sauce], ['Image Expansion', ImageExpand], ['Image Expansion (Menu)', ImageExpand.menu], ['Reveal Spoiler Thumbnails', RevealSpoilers], ['Image Loading', ImageLoader], ['Image Hover', ImageHover], ['Volume Control', Volume], ['WEBM Metadata', Metadata], ['Comment Expansion', ExpandComment], ['Thread Expansion', ExpandThread], ['Thread Excerpt', ThreadExcerpt], ['Favicon', Favicon], ['Unread', Unread], ['Quote Threading', QuoteThreading], ['Thread Stats', ThreadStats], ['Thread Updater', ThreadUpdater], ['Thread Watcher', ThreadWatcher], ['Thread Watcher (Menu)', ThreadWatcher.menu], ['Mark New IPs', MarkNewIPs], ['Index Navigation', Nav], ['Keybinds', Keybinds], ['Banner', Banner], ['Flash Features', Flash]]
|
features: [['Polyfill', Polyfill], ['Captcha Replacement', Captcha.replace], ['Redirect', Redirect], ['Header', Header], ['Catalog Links', CatalogLinks], ['Settings', Settings], ['Index Generator', Index], ['Disable Autoplay', AntiAutoplay], ['Announcement Hiding', PSAHiding], ['Fourchan thingies', Fourchan], ['Color User IDs', IDColor], ['Highlight by User ID', IDHighlight], ['Custom CSS', CustomCSS], ['Linkify', Linkify], ['Reveal Spoilers', RemoveSpoilers], ['Resurrect Quotes', Quotify], ['Filter', Filter], ['Thread Hiding Buttons', ThreadHiding], ['Reply Hiding Buttons', PostHiding], ['Recursive', Recursive], ['Strike-through Quotes', QuoteStrikeThrough], ['Quick Reply', QR], ['Menu', Menu], ['Index Generator (Menu)', Index.menu], ['Report Link', ReportLink], ['Thread Hiding (Menu)', ThreadHiding.menu], ['Reply Hiding (Menu)', PostHiding.menu], ['Delete Link', DeleteLink], ['Filter (Menu)', Filter.menu], ['Download Link', DownloadLink], ['Archive Link', ArchiveLink], ['Quote Inlining', QuoteInline], ['Quote Previewing', QuotePreview], ['Quote Backlinks', QuoteBacklink], ['Mark Quotes of You', QuoteYou], ['Mark OP Quotes', QuoteOP], ['Mark Cross-thread Quotes', QuoteCT], ['Anonymize', Anonymize], ['Time Formatting', Time], ['Relative Post Dates', RelativeDates], ['File Info Formatting', FileInfo], ['Fappe Tyme', FappeTyme], ['Gallery', Gallery], ['Gallery (menu)', Gallery.menu], ['Sauce', Sauce], ['Image Expansion', ImageExpand], ['Image Expansion (Menu)', ImageExpand.menu], ['Reveal Spoiler Thumbnails', RevealSpoilers], ['Image Loading', ImageLoader], ['Image Hover', ImageHover], ['Volume Control', Volume], ['WEBM Metadata', Metadata], ['Comment Expansion', ExpandComment], ['Thread Expansion', ExpandThread], ['Thread Excerpt', ThreadExcerpt], ['Favicon', Favicon], ['Unread', Unread], ['Quote Threading', QuoteThreading], ['Thread Stats', ThreadStats], ['Thread Updater', ThreadUpdater], ['Thread Watcher', ThreadWatcher], ['Thread Watcher (Menu)', ThreadWatcher.menu], ['Mark New IPs', MarkNewIPs], ['Index Navigation', Nav], ['Keybinds', Keybinds], ['Banner', Banner], ['Flash Features', Flash]]
|
||||||
};
|
};
|
||||||
|
|
||||||
Main.init();
|
Main.init();
|
||||||
|
|||||||
Binary file not shown.
@ -1,7 +1,7 @@
|
|||||||
// Generated by CoffeeScript
|
// Generated by CoffeeScript
|
||||||
// ==UserScript==
|
// ==UserScript==
|
||||||
// @name 4chan X
|
// @name 4chan X
|
||||||
// @version 1.11.1.3
|
// @version 1.11.2.0
|
||||||
// @minGMVer 1.14
|
// @minGMVer 1.14
|
||||||
// @minFFVer 26
|
// @minFFVer 26
|
||||||
// @namespace 4chan-X
|
// @namespace 4chan-X
|
||||||
@ -241,12 +241,12 @@
|
|||||||
'Hide Original Post Form': [true, 'Hide the normal post form.', 1],
|
'Hide Original Post Form': [true, 'Hide the normal post form.', 1],
|
||||||
'Cooldown': [true, 'Indicate the remaining time before posting again.', 1],
|
'Cooldown': [true, 'Indicate the remaining time before posting again.', 1],
|
||||||
'Posting Success Notifications': [true, 'Show notifications on successful post creation or file uploading.', 1],
|
'Posting Success Notifications': [true, 'Show notifications on successful post creation or file uploading.', 1],
|
||||||
'Use Recaptcha v1': [false, 'Use the old text version of Recaptcha.', 1],
|
|
||||||
'Force Noscript Captcha': [false, 'Use the non-Javascript fallback captcha in the QR even if Javascript is enabled.', 1],
|
'Force Noscript Captcha': [false, 'Use the non-Javascript fallback captcha in the QR even if Javascript is enabled.', 1],
|
||||||
'Auto-load captcha': [false, 'Automatically load the captcha in the QR even if your post is empty.', 1],
|
'Auto-load captcha': [false, 'Automatically load the captcha in the QR even if your post is empty.', 1],
|
||||||
'Post on Captcha Completion': [false, 'Submit the post immediately when the captcha is completed.', 1],
|
'Post on Captcha Completion': [false, 'Submit the post immediately when the captcha is completed.', 1],
|
||||||
'Bottom QR Link': [true, 'Places a link on the bottom of threads to open the QR.', 1],
|
'Bottom QR Link': [true, 'Places a link on the bottom of threads to open the QR.', 1],
|
||||||
'Captcha Fixes': [true, 'Make captcha easier to use, especially with the keyboard.'],
|
'Captcha Fixes': [true, 'Make captcha easier to use, especially with the keyboard.'],
|
||||||
|
'Use Recaptcha v1': [false, 'Use the old text version of Recaptcha.'],
|
||||||
'Use Recaptcha v2 in Reports': [false, 'Use the image selection captcha in the report window.']
|
'Use Recaptcha v2 in Reports': [false, 'Use the image selection captcha in the report window.']
|
||||||
},
|
},
|
||||||
'Quote Links': {
|
'Quote Links': {
|
||||||
@ -298,7 +298,7 @@
|
|||||||
tripcode: "# Filter any tripfag\n#/^!/",
|
tripcode: "# Filter any tripfag\n#/^!/",
|
||||||
capcode: "# Set a custom class for mods:\n#/Mod$/;highlight:mod;op:yes\n# Set a custom class for moot:\n#/Admin$/;highlight:moot;op:yes",
|
capcode: "# Set a custom class for mods:\n#/Mod$/;highlight:mod;op:yes\n# Set a custom class for moot:\n#/Admin$/;highlight:moot;op:yes",
|
||||||
subject: "# Filter Generals on /v/:\n#/general/i;boards:v;op:only",
|
subject: "# Filter Generals on /v/:\n#/general/i;boards:v;op:only",
|
||||||
comment: "# Filter Stallman copypasta on /g/:\n#/what you\'re refer+ing to as linux/i;boards:g",
|
comment: "# Filter Stallman copypasta on /g/:\n#/what you\'re refer+ing to as linux/i;boards:g\n# Filter posts with 10 or more quote links:\n#/(?:>>\\d(?:(?!>>\\d)[^])*){10}/",
|
||||||
flag: '',
|
flag: '',
|
||||||
filename: '',
|
filename: '',
|
||||||
dimensions: "# Highlight potential wallpapers:\n#/1920x1080/;op:yes;highlight;top:no;boards:w,wg",
|
dimensions: "# Highlight potential wallpapers:\n#/1920x1080/;op:yes;highlight;top:no;boards:w,wg",
|
||||||
@ -410,7 +410,7 @@
|
|||||||
doc = d.documentElement;
|
doc = d.documentElement;
|
||||||
|
|
||||||
g = {
|
g = {
|
||||||
VERSION: '1.11.1.3',
|
VERSION: '1.11.2.0',
|
||||||
NAMESPACE: '4chan X.',
|
NAMESPACE: '4chan X.',
|
||||||
boards: {}
|
boards: {}
|
||||||
};
|
};
|
||||||
@ -1522,7 +1522,6 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
Post.prototype.collect = function() {
|
Post.prototype.collect = function() {
|
||||||
this.kill();
|
|
||||||
g.posts.rm(this.fullID);
|
g.posts.rm(this.fullID);
|
||||||
this.thread.posts.rm(this);
|
this.thread.posts.rm(this);
|
||||||
return this.board.posts.rm(this);
|
return this.board.posts.rm(this);
|
||||||
@ -6955,24 +6954,26 @@
|
|||||||
return alert(el.textContent);
|
return alert(el.textContent);
|
||||||
}
|
}
|
||||||
} else if (d.hidden || !(focusOverride || d.hasFocus())) {
|
} else if (d.hidden || !(focusOverride || d.hasFocus())) {
|
||||||
notif = new Notification(el.textContent, {
|
try {
|
||||||
body: el.textContent,
|
notif = new Notification(el.textContent, {
|
||||||
icon: Favicon.logo
|
body: el.textContent,
|
||||||
});
|
icon: Favicon.logo
|
||||||
notif.onclick = function() {
|
});
|
||||||
return window.focus();
|
notif.onclick = function() {
|
||||||
};
|
return window.focus();
|
||||||
if (typeof chrome !== "undefined" && chrome !== null) {
|
|
||||||
notif.onclose = function() {
|
|
||||||
return notice.close();
|
|
||||||
};
|
};
|
||||||
return notif.onshow = function() {
|
if (typeof chrome !== "undefined" && chrome !== null) {
|
||||||
return setTimeout(function() {
|
notif.onclose = function() {
|
||||||
notif.onclose = null;
|
return notice.close();
|
||||||
return notif.close();
|
};
|
||||||
}, 7 * $.SECOND);
|
return notif.onshow = function() {
|
||||||
};
|
return setTimeout(function() {
|
||||||
}
|
notif.onclose = null;
|
||||||
|
return notif.close();
|
||||||
|
}, 7 * $.SECOND);
|
||||||
|
};
|
||||||
|
}
|
||||||
|
} catch (_error) {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
notifications: [],
|
notifications: [],
|
||||||
@ -7819,33 +7820,6 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
Captcha.language = {
|
|
||||||
init: function() {
|
|
||||||
if (!(Conf['captchaLanguage'].trim() && d.cookie.indexOf('pass_enabled=1') < 0 && !Conf['Hide Original Post Form'])) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
return $.onExists(doc, '#captchaFormPart', true, function(node) {
|
|
||||||
return $.onExists(node, 'iframe', true, Captcha.language.fixIframe);
|
|
||||||
});
|
|
||||||
},
|
|
||||||
fixPage: function() {
|
|
||||||
if (!(Conf['captchaLanguage'].trim() && d.cookie.indexOf('pass_enabled=1') < 0)) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
return $.onExists(doc, 'iframe', true, Captcha.language.fixIframe);
|
|
||||||
},
|
|
||||||
fixIframe: function(el) {
|
|
||||||
var lang, src;
|
|
||||||
if (!(lang = Conf['captchaLanguage'].trim())) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
src = /[?&]hl=/.test(el.src) ? el.src.replace(/([?&]hl=)[^&]*/, '$1' + encodeURIComponent(lang)) : el.src + ("&hl=" + (encodeURIComponent(lang)));
|
|
||||||
if (el.src !== src) {
|
|
||||||
return el.src = src;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
Captcha.noscript = {
|
Captcha.noscript = {
|
||||||
lifetime: 30 * $.MINUTE,
|
lifetime: 30 * $.MINUTE,
|
||||||
init: function() {
|
init: function() {
|
||||||
@ -7853,7 +7827,7 @@
|
|||||||
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!(this.isEnabled = !!$.id('g-recaptcha'))) {
|
if (!(this.isEnabled = !!$('#g-recaptcha, #captchaContainerAlt'))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
container = $.el('div', {
|
container = $.el('div', {
|
||||||
@ -8181,24 +8155,97 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
Captcha.v1 = {
|
Captcha.replace = {
|
||||||
init: function() {
|
init: function() {
|
||||||
var captchaContainer, imgContainer, input, script;
|
var jsEnabled;
|
||||||
|
if (!(d.cookie.indexOf('pass_enabled=1') < 0)) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (location.hostname === 'boards.4chan.org' && Conf['Hide Original Post Form']) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
jsEnabled = $.hasClass(doc, 'js-enabled');
|
||||||
|
if (location.hostname === 'sys.4chan.org' && Conf['Use Recaptcha v2 in Reports'] && jsEnabled) {
|
||||||
|
$.ready(Captcha.replace.v2);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (Conf['Use Recaptcha v1'] && jsEnabled && location.hostname !== 'www.4chan.org') {
|
||||||
|
$.ready(Captcha.replace.v1);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (Conf['captchaLanguage'].trim()) {
|
||||||
|
if (location.hostname === 'boards.4chan.org') {
|
||||||
|
return $.onExists(doc, '#captchaFormPart', true, function(node) {
|
||||||
|
return $.onExists(node, 'iframe', true, Captcha.replace.iframe);
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
return $.onExists(doc, 'iframe', true, Captcha.replace.iframe);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
v1: function() {
|
||||||
|
var form, link;
|
||||||
|
if (!$.id('g-recaptcha')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
Captcha.v1.replace();
|
||||||
|
if (link = $.id('form-link')) {
|
||||||
|
return $.on(link, 'click', function() {
|
||||||
|
return Captcha.v1.create();
|
||||||
|
});
|
||||||
|
} else if (location.hostname === 'boards.4chan.org') {
|
||||||
|
form = $.id('postForm');
|
||||||
|
return form.addEventListener('focus', (function() {
|
||||||
|
return Captcha.v1.create();
|
||||||
|
}), true);
|
||||||
|
} else {
|
||||||
|
return Captcha.v1.create();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
v2: function() {
|
||||||
|
var container, lang, old, script, url;
|
||||||
|
if (!(old = $.id('captchaContainerAlt'))) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
container = $.el('div', {
|
||||||
|
className: 'g-recaptcha'
|
||||||
|
});
|
||||||
|
$.extend(container.dataset, {
|
||||||
|
sitekey: '6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc',
|
||||||
|
tabindex: 3
|
||||||
|
});
|
||||||
|
$.replace(old, container);
|
||||||
|
url = 'https://www.google.com/recaptcha/api.js';
|
||||||
|
if (lang = Conf['captchaLanguage'].trim()) {
|
||||||
|
url += "?hl=" + (encodeURIComponent(lang));
|
||||||
|
}
|
||||||
|
script = $.el('script', {
|
||||||
|
src: url
|
||||||
|
});
|
||||||
|
return $.add(d.head, script);
|
||||||
|
},
|
||||||
|
iframe: function(el) {
|
||||||
|
var lang, src;
|
||||||
|
if (!(lang = Conf['captchaLanguage'].trim())) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
src = /[?&]hl=/.test(el.src) ? el.src.replace(/([?&]hl=)[^&]*/, '$1' + encodeURIComponent(lang)) : el.src + ("&hl=" + (encodeURIComponent(lang)));
|
||||||
|
if (el.src !== src) {
|
||||||
|
return el.src = src;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
Captcha.v1 = {
|
||||||
|
blank: "data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='300' height='57'/>",
|
||||||
|
init: function() {
|
||||||
|
var imgContainer, input;
|
||||||
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!(this.isEnabled = !!$.id('g-recaptcha'))) {
|
if (!(this.isEnabled = !!$('#g-recaptcha, #captchaContainerAlt'))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
script = $.el('script', {
|
|
||||||
src: '//www.google.com/recaptcha/api/js/recaptcha_ajax.js'
|
|
||||||
});
|
|
||||||
$.add(d.head, script);
|
|
||||||
captchaContainer = $.el('div', {
|
|
||||||
id: 'captchaContainer',
|
|
||||||
hidden: true
|
|
||||||
});
|
|
||||||
$.add(d.body, captchaContainer);
|
|
||||||
imgContainer = $.el('div', {
|
imgContainer = $.el('div', {
|
||||||
className: 'captcha-img',
|
className: 'captcha-img',
|
||||||
title: 'Reload reCAPTCHA'
|
title: 'Reload reCAPTCHA'
|
||||||
@ -8230,13 +8277,36 @@
|
|||||||
return QR.captcha.clear();
|
return QR.captcha.clear();
|
||||||
});
|
});
|
||||||
$.sync('captchas', this.sync);
|
$.sync('captchas', this.sync);
|
||||||
new MutationObserver(this.afterSetup).observe($.id('captchaContainer'), {
|
|
||||||
childList: true
|
|
||||||
});
|
|
||||||
this.beforeSetup();
|
this.beforeSetup();
|
||||||
if (Conf['Auto-load captcha']) {
|
if (Conf['Auto-load captcha']) {
|
||||||
return this.setup();
|
this.setup();
|
||||||
}
|
}
|
||||||
|
new MutationObserver(this.afterSetup).observe($.id('captchaContainerAlt'), {
|
||||||
|
childList: true
|
||||||
|
});
|
||||||
|
return this.afterSetup();
|
||||||
|
},
|
||||||
|
replace: function() {
|
||||||
|
var container, old;
|
||||||
|
if (this.script) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (!(this.script = $('script[src="//www.google.com/recaptcha/api/js/recaptcha_ajax.js"]', d.head))) {
|
||||||
|
this.script = $.el('script', {
|
||||||
|
src: '//www.google.com/recaptcha/api/js/recaptcha_ajax.js'
|
||||||
|
});
|
||||||
|
$.add(d.head, this.script);
|
||||||
|
}
|
||||||
|
if (old = $.id('g-recaptcha')) {
|
||||||
|
container = $.el('div', {
|
||||||
|
id: 'captchaContainerAlt'
|
||||||
|
});
|
||||||
|
return $.replace(old, container);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
create: function() {
|
||||||
|
this.replace();
|
||||||
|
return $.globalEval('(function() {\n var container = document.getElementById("captchaContainerAlt");\n if (container.firstChild) return;\n var options = {\n theme: "clean",\n tabindex: {"boards.4chan.org": 5, "sys.4chan.org": 3}[location.hostname]\n };\n if (window.Recaptcha) {\n window.Recaptcha.create("6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc", container, options);\n } else {\n var script = document.head.querySelector(\'script[src="//www.google.com/recaptcha/api/js/recaptcha_ajax.js"]\');\n script.addEventListener(\'load\', function() {\n window.Recaptcha.create("6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc", container, options);\n }, false);\n }\n})();');
|
||||||
},
|
},
|
||||||
cb: {
|
cb: {
|
||||||
focus: function() {
|
focus: function() {
|
||||||
@ -8247,6 +8317,7 @@
|
|||||||
var img, input, ref;
|
var img, input, ref;
|
||||||
ref = this.nodes, img = ref.img, input = ref.input;
|
ref = this.nodes, img = ref.img, input = ref.input;
|
||||||
img.parentNode.hidden = true;
|
img.parentNode.hidden = true;
|
||||||
|
img.src = this.blank;
|
||||||
input.value = '';
|
input.value = '';
|
||||||
input.placeholder = 'Focus to load reCAPTCHA';
|
input.placeholder = 'Focus to load reCAPTCHA';
|
||||||
this.count();
|
this.count();
|
||||||
@ -8267,10 +8338,10 @@
|
|||||||
onNewPost: function() {},
|
onNewPost: function() {},
|
||||||
onPostChange: function() {},
|
onPostChange: function() {},
|
||||||
setup: function(focus, force) {
|
setup: function(focus, force) {
|
||||||
if (!(this.isEnabled && (this.needed() || force))) {
|
if (!(this.isEnabled && (force || this.needed()))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$.globalEval('(function() {\n var captchaContainer = document.getElementById("captchaContainer");\n if (captchaContainer.firstChild) return;\n function setup() {\n if (window.Recaptcha) {\n Recaptcha.create(recaptchaKey, captchaContainer, {theme: "clean"});\n } else {\n setTimeout(setup, 25);\n }\n }\n setup();\n})()');
|
this.create();
|
||||||
if (focus) {
|
if (focus) {
|
||||||
return this.nodes.input.focus();
|
return this.nodes.input.focus();
|
||||||
}
|
}
|
||||||
@ -8307,11 +8378,13 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
destroy: function() {
|
destroy: function() {
|
||||||
if (!this.isEnabled) {
|
if (!this.script) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$.globalEval('Recaptcha.destroy()');
|
$.globalEval('window.Recaptcha.destroy();');
|
||||||
return this.beforeSetup();
|
if (this.nodes) {
|
||||||
|
return this.beforeSetup();
|
||||||
|
}
|
||||||
},
|
},
|
||||||
sync: function(captchas) {
|
sync: function(captchas) {
|
||||||
if (captchas == null) {
|
if (captchas == null) {
|
||||||
@ -8379,6 +8452,10 @@
|
|||||||
},
|
},
|
||||||
load: function() {
|
load: function() {
|
||||||
var challenge, challenge_image;
|
var challenge, challenge_image;
|
||||||
|
if ($('#captchaContainerAlt[class~="recaptcha_is_showing_audio"]')) {
|
||||||
|
this.nodes.img.src = this.blank;
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (!this.nodes.challenge.firstChild) {
|
if (!this.nodes.challenge.firstChild) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -8389,7 +8466,7 @@
|
|||||||
challenge = this.nodes.challenge.firstChild.value;
|
challenge = this.nodes.challenge.firstChild.value;
|
||||||
this.nodes.img.alt = challenge;
|
this.nodes.img.alt = challenge;
|
||||||
this.nodes.img.src = challenge_image.src;
|
this.nodes.img.src = challenge_image.src;
|
||||||
this.nodes.input.value = null;
|
this.nodes.input.value = '';
|
||||||
return this.clear();
|
return this.clear();
|
||||||
},
|
},
|
||||||
count: function() {
|
count: function() {
|
||||||
@ -8415,7 +8492,7 @@
|
|||||||
return this.nodes.input.alt = count;
|
return this.nodes.input.alt = count;
|
||||||
},
|
},
|
||||||
reload: function(focus) {
|
reload: function(focus) {
|
||||||
$.globalEval('Recaptcha.reload(); Recaptcha.should_focus = false;');
|
$.globalEval('if (window.Recaptcha.type === "image") {\n window.Recaptcha.reload();\n} else {\n window.Recaptcha.switch_type("image");\n}\nwindow.Recaptcha.should_focus = false;');
|
||||||
if (focus) {
|
if (focus) {
|
||||||
return this.nodes.input.focus();
|
return this.nodes.input.focus();
|
||||||
}
|
}
|
||||||
@ -8439,7 +8516,7 @@
|
|||||||
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!(this.isEnabled = !!$.id('g-recaptcha'))) {
|
if (!(this.isEnabled = !!$('#g-recaptcha, #captchaContainerAlt'))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (this.noscript = Conf['Force Noscript Captcha'] || !$.hasClass(doc, 'js-enabled')) {
|
if (this.noscript = Conf['Force Noscript Captcha'] || !$.hasClass(doc, 'js-enabled')) {
|
||||||
@ -8474,6 +8551,16 @@
|
|||||||
$.addClass(QR.nodes.el, 'has-captcha', 'captcha-v2');
|
$.addClass(QR.nodes.el, 'has-captcha', 'captcha-v2');
|
||||||
$.after(QR.nodes.com.parentNode, root);
|
$.after(QR.nodes.com.parentNode, root);
|
||||||
$.on(counter, 'click', this.toggle.bind(this));
|
$.on(counter, 'click', this.toggle.bind(this));
|
||||||
|
$.on(counter, 'keydown', (function(_this) {
|
||||||
|
return function(e) {
|
||||||
|
if (Keybinds.keyCode(e) !== 'Space') {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
_this.toggle();
|
||||||
|
e.preventDefault();
|
||||||
|
return e.stopPropagation();
|
||||||
|
};
|
||||||
|
})(this));
|
||||||
return $.on(window, 'captcha:success', (function(_this) {
|
return $.on(window, 'captcha:success', (function(_this) {
|
||||||
return function() {
|
return function() {
|
||||||
return $.queueTask(function() {
|
return $.queueTask(function() {
|
||||||
@ -8596,7 +8683,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
setupIFrame: function(iframe) {
|
setupIFrame: function(iframe) {
|
||||||
Captcha.language.fixIframe(iframe);
|
Captcha.replace.iframe(iframe);
|
||||||
$.addClass(QR.nodes.el, 'captcha-open');
|
$.addClass(QR.nodes.el, 'captcha-open');
|
||||||
if (QR.nodes.el.getBoundingClientRect().bottom > doc.clientHeight) {
|
if (QR.nodes.el.getBoundingClientRect().bottom > doc.clientHeight) {
|
||||||
QR.nodes.el.style.top = null;
|
QR.nodes.el.style.top = null;
|
||||||
@ -13911,19 +13998,21 @@
|
|||||||
if (!Header.areNotificationsEnabled) {
|
if (!Header.areNotificationsEnabled) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
notif = new Notification(post.info.nameBlock + " replied to you", {
|
try {
|
||||||
body: post.info.commentDisplay,
|
notif = new Notification(post.info.nameBlock + " replied to you", {
|
||||||
icon: Favicon.logo
|
body: post.info.commentDisplay,
|
||||||
});
|
icon: Favicon.logo
|
||||||
notif.onclick = function() {
|
});
|
||||||
Header.scrollToIfNeeded(post.nodes.root, true);
|
notif.onclick = function() {
|
||||||
return window.focus();
|
Header.scrollToIfNeeded(post.nodes.root, true);
|
||||||
};
|
return window.focus();
|
||||||
return notif.onshow = function() {
|
};
|
||||||
return setTimeout(function() {
|
return notif.onshow = function() {
|
||||||
return notif.close();
|
return setTimeout(function() {
|
||||||
}, 7 * $.SECOND);
|
return notif.close();
|
||||||
};
|
}, 7 * $.SECOND);
|
||||||
|
};
|
||||||
|
} catch (_error) {}
|
||||||
},
|
},
|
||||||
onUpdate: function(e) {
|
onUpdate: function(e) {
|
||||||
if (!e.detail[404]) {
|
if (!e.detail[404]) {
|
||||||
@ -15904,21 +15993,18 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
Report = {
|
Report = {
|
||||||
css: "noscript > div, noscript > div > div {\n" +
|
css: ":root:not(.js-enabled) #captchaContainerAlt {\n" +
|
||||||
" height: 545px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"noscript > div > div > div:first-child, noscript iframe {\n" +
|
|
||||||
" height: 423px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
":root:not(.js-enabled) #g-recaptcha {\n" +
|
|
||||||
" height: auto;\n" +
|
" height: auto;\n" +
|
||||||
|
"}\n" +
|
||||||
|
"noscript > iframe, #recaptcha_challenge_field {\n" +
|
||||||
|
" width: 500px;\n" +
|
||||||
"}",
|
"}",
|
||||||
init: function() {
|
init: function() {
|
||||||
var match;
|
var match;
|
||||||
if (!(/\bmode=report\b/.test(location.search) && (match = location.search.match(/\bno=(\d+)/)))) {
|
if (!(/\bmode=report\b/.test(location.search) && (match = location.search.match(/\bno=(\d+)/)))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
Captcha.language.fixPage();
|
Captcha.replace.init();
|
||||||
this.postID = +match[1];
|
this.postID = +match[1];
|
||||||
return $.ready(this.ready);
|
return $.ready(this.ready);
|
||||||
},
|
},
|
||||||
@ -15927,9 +16013,6 @@
|
|||||||
if (Conf['Archive Report']) {
|
if (Conf['Archive Report']) {
|
||||||
Report.archive();
|
Report.archive();
|
||||||
}
|
}
|
||||||
if (Conf['Use Recaptcha v2 in Reports']) {
|
|
||||||
Report.captchaV2();
|
|
||||||
}
|
|
||||||
if (Conf['Use Recaptcha v2 in Reports'] && $.hasClass(doc, 'js-enabled')) {
|
if (Conf['Use Recaptcha v2 in Reports'] && $.hasClass(doc, 'js-enabled')) {
|
||||||
return new MutationObserver(function() {
|
return new MutationObserver(function() {
|
||||||
return Report.fit('.gc-bubbleDefault');
|
return Report.fit('.gc-bubbleDefault');
|
||||||
@ -15942,25 +16025,6 @@
|
|||||||
return Report.fit('body');
|
return Report.fit('body');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
captchaV2: function() {
|
|
||||||
var container, lang, old, script, url;
|
|
||||||
if (!(old = $.id('captchaContainerAlt'))) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
container = $.el('div', {
|
|
||||||
className: 'g-recaptcha'
|
|
||||||
});
|
|
||||||
container.dataset.sitekey = '6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc';
|
|
||||||
$.replace(old, container);
|
|
||||||
url = 'https://www.google.com/recaptcha/api.js';
|
|
||||||
if (lang = Conf['captchaLanguage'].trim()) {
|
|
||||||
url += "?hl=" + (encodeURIComponent(lang));
|
|
||||||
}
|
|
||||||
script = $.el('script', {
|
|
||||||
src: url
|
|
||||||
});
|
|
||||||
return $.add(d.head, script);
|
|
||||||
},
|
|
||||||
fit: function(selector) {
|
fit: function(selector) {
|
||||||
var dy, el;
|
var dy, el;
|
||||||
if (!(el = $(selector, doc))) {
|
if (!(el = $(selector, doc))) {
|
||||||
@ -16829,19 +16893,6 @@
|
|||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (location.hostname === 'www.4chan.org') {
|
|
||||||
$.onExists(d.documentElement, 'body', false, function() {
|
|
||||||
return $.addStyle(Main.cssWWW);
|
|
||||||
});
|
|
||||||
Conf = {
|
|
||||||
'captchaLanguage': Config.captchaLanguage
|
|
||||||
};
|
|
||||||
$.get(Conf, function(items) {
|
|
||||||
$.extend(Conf, items);
|
|
||||||
return Captcha.language.fixPage();
|
|
||||||
});
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
g.threads = new SimpleDict();
|
g.threads = new SimpleDict();
|
||||||
g.posts = new SimpleDict();
|
g.posts = new SimpleDict();
|
||||||
pathname = location.pathname.split('/');
|
pathname = location.pathname.split('/');
|
||||||
@ -16910,10 +16961,13 @@
|
|||||||
},
|
},
|
||||||
initFeatures: function() {
|
initFeatures: function() {
|
||||||
var err, feature, k, len1, name, pathname, ref, ref1, ref2;
|
var err, feature, k, len1, name, pathname, ref, ref1, ref2;
|
||||||
if ((ref = location.hostname) === 'boards.4chan.org' || ref === 'sys.4chan.org') {
|
if ((ref = location.hostname) === 'boards.4chan.org' || ref === 'sys.4chan.org' || ref === 'www.4chan.org') {
|
||||||
$.globalEval('document.documentElement.classList.add("js-enabled");');
|
$.globalEval('document.documentElement.classList.add("js-enabled");');
|
||||||
}
|
}
|
||||||
switch (location.hostname) {
|
switch (location.hostname) {
|
||||||
|
case 'www.4chan.org':
|
||||||
|
Captcha.replace.init();
|
||||||
|
return;
|
||||||
case 'a.4cdn.org':
|
case 'a.4cdn.org':
|
||||||
return;
|
return;
|
||||||
case 'sys.4chan.org':
|
case 'sys.4chan.org':
|
||||||
@ -16973,6 +17027,9 @@
|
|||||||
},
|
},
|
||||||
initStyle: function() {
|
initStyle: function() {
|
||||||
var keyboard, ref;
|
var keyboard, ref;
|
||||||
|
if (location.hostname === 'www.4chan.org') {
|
||||||
|
$.addStyle(Main.cssWWW);
|
||||||
|
}
|
||||||
if (!Main.isThisPageLegit() || $.hasClass(doc, 'fourchan-x')) {
|
if (!Main.isThisPageLegit() || $.hasClass(doc, 'fourchan-x')) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -17801,15 +17858,6 @@
|
|||||||
" 0% {transform:rotate(0deg);}\n" +
|
" 0% {transform:rotate(0deg);}\n" +
|
||||||
" 100% {transform:rotate(359deg);}\n" +
|
" 100% {transform:rotate(359deg);}\n" +
|
||||||
"}\n" +
|
"}\n" +
|
||||||
"noscript > div, noscript > div > div {\n" +
|
|
||||||
" height: 545px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"noscript > div > div > div:first-child, noscript iframe {\n" +
|
|
||||||
" height: 423px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
":root:not(.js-enabled) #g-recaptcha {\n" +
|
|
||||||
" height: auto;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"/* General */\n" +
|
"/* General */\n" +
|
||||||
".dialog {\n" +
|
".dialog {\n" +
|
||||||
" border: 1px solid;\n" +
|
" border: 1px solid;\n" +
|
||||||
@ -17919,6 +17967,9 @@
|
|||||||
":root:not(.js-enabled) #postForm {\n" +
|
":root:not(.js-enabled) #postForm {\n" +
|
||||||
" display: table;\n" +
|
" display: table;\n" +
|
||||||
"}\n" +
|
"}\n" +
|
||||||
|
"#captchaContainerAlt td:nth-child(2) {\n" +
|
||||||
|
" display: table-cell !important;\n" +
|
||||||
|
"}\n" +
|
||||||
"/* Anti-autoplay */\n" +
|
"/* Anti-autoplay */\n" +
|
||||||
"audio.controls-added {\n" +
|
"audio.controls-added {\n" +
|
||||||
" display: block;\n" +
|
" display: block;\n" +
|
||||||
@ -20216,19 +20267,10 @@
|
|||||||
" font-family: sans-serif !important;\n" +
|
" font-family: sans-serif !important;\n" +
|
||||||
" text-shadow: 1px 1px 1px rgba(0,74,153,0.6);\n" +
|
" text-shadow: 1px 1px 1px rgba(0,74,153,0.6);\n" +
|
||||||
"}",
|
"}",
|
||||||
cssWWW: "noscript > div, noscript > div > div {\n" +
|
cssWWW: "#captcha-cnt {\n" +
|
||||||
" height: 545px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"noscript > div > div > div:first-child, noscript iframe {\n" +
|
|
||||||
" height: 423px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
":root:not(.js-enabled) #g-recaptcha {\n" +
|
|
||||||
" height: auto;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"#captcha-cnt {\n" +
|
|
||||||
" height: auto;\n" +
|
" height: auto;\n" +
|
||||||
"}",
|
"}",
|
||||||
features: [['Polyfill', Polyfill], ['Captcha Language', Captcha.language], ['Redirect', Redirect], ['Header', Header], ['Catalog Links', CatalogLinks], ['Settings', Settings], ['Index Generator', Index], ['Disable Autoplay', AntiAutoplay], ['Announcement Hiding', PSAHiding], ['Fourchan thingies', Fourchan], ['Color User IDs', IDColor], ['Highlight by User ID', IDHighlight], ['Custom CSS', CustomCSS], ['Linkify', Linkify], ['Reveal Spoilers', RemoveSpoilers], ['Resurrect Quotes', Quotify], ['Filter', Filter], ['Thread Hiding Buttons', ThreadHiding], ['Reply Hiding Buttons', PostHiding], ['Recursive', Recursive], ['Strike-through Quotes', QuoteStrikeThrough], ['Quick Reply', QR], ['Menu', Menu], ['Index Generator (Menu)', Index.menu], ['Report Link', ReportLink], ['Thread Hiding (Menu)', ThreadHiding.menu], ['Reply Hiding (Menu)', PostHiding.menu], ['Delete Link', DeleteLink], ['Filter (Menu)', Filter.menu], ['Download Link', DownloadLink], ['Archive Link', ArchiveLink], ['Quote Inlining', QuoteInline], ['Quote Previewing', QuotePreview], ['Quote Backlinks', QuoteBacklink], ['Mark Quotes of You', QuoteYou], ['Mark OP Quotes', QuoteOP], ['Mark Cross-thread Quotes', QuoteCT], ['Anonymize', Anonymize], ['Time Formatting', Time], ['Relative Post Dates', RelativeDates], ['File Info Formatting', FileInfo], ['Fappe Tyme', FappeTyme], ['Gallery', Gallery], ['Gallery (menu)', Gallery.menu], ['Sauce', Sauce], ['Image Expansion', ImageExpand], ['Image Expansion (Menu)', ImageExpand.menu], ['Reveal Spoiler Thumbnails', RevealSpoilers], ['Image Loading', ImageLoader], ['Image Hover', ImageHover], ['Volume Control', Volume], ['WEBM Metadata', Metadata], ['Comment Expansion', ExpandComment], ['Thread Expansion', ExpandThread], ['Thread Excerpt', ThreadExcerpt], ['Favicon', Favicon], ['Unread', Unread], ['Quote Threading', QuoteThreading], ['Thread Stats', ThreadStats], ['Thread Updater', ThreadUpdater], ['Thread Watcher', ThreadWatcher], ['Thread Watcher (Menu)', ThreadWatcher.menu], ['Mark New IPs', MarkNewIPs], ['Index Navigation', Nav], ['Keybinds', Keybinds], ['Banner', Banner], ['Flash Features', Flash]]
|
features: [['Polyfill', Polyfill], ['Captcha Replacement', Captcha.replace], ['Redirect', Redirect], ['Header', Header], ['Catalog Links', CatalogLinks], ['Settings', Settings], ['Index Generator', Index], ['Disable Autoplay', AntiAutoplay], ['Announcement Hiding', PSAHiding], ['Fourchan thingies', Fourchan], ['Color User IDs', IDColor], ['Highlight by User ID', IDHighlight], ['Custom CSS', CustomCSS], ['Linkify', Linkify], ['Reveal Spoilers', RemoveSpoilers], ['Resurrect Quotes', Quotify], ['Filter', Filter], ['Thread Hiding Buttons', ThreadHiding], ['Reply Hiding Buttons', PostHiding], ['Recursive', Recursive], ['Strike-through Quotes', QuoteStrikeThrough], ['Quick Reply', QR], ['Menu', Menu], ['Index Generator (Menu)', Index.menu], ['Report Link', ReportLink], ['Thread Hiding (Menu)', ThreadHiding.menu], ['Reply Hiding (Menu)', PostHiding.menu], ['Delete Link', DeleteLink], ['Filter (Menu)', Filter.menu], ['Download Link', DownloadLink], ['Archive Link', ArchiveLink], ['Quote Inlining', QuoteInline], ['Quote Previewing', QuotePreview], ['Quote Backlinks', QuoteBacklink], ['Mark Quotes of You', QuoteYou], ['Mark OP Quotes', QuoteOP], ['Mark Cross-thread Quotes', QuoteCT], ['Anonymize', Anonymize], ['Time Formatting', Time], ['Relative Post Dates', RelativeDates], ['File Info Formatting', FileInfo], ['Fappe Tyme', FappeTyme], ['Gallery', Gallery], ['Gallery (menu)', Gallery.menu], ['Sauce', Sauce], ['Image Expansion', ImageExpand], ['Image Expansion (Menu)', ImageExpand.menu], ['Reveal Spoiler Thumbnails', RevealSpoilers], ['Image Loading', ImageLoader], ['Image Hover', ImageHover], ['Volume Control', Volume], ['WEBM Metadata', Metadata], ['Comment Expansion', ExpandComment], ['Thread Expansion', ExpandThread], ['Thread Excerpt', ThreadExcerpt], ['Favicon', Favicon], ['Unread', Unread], ['Quote Threading', QuoteThreading], ['Thread Stats', ThreadStats], ['Thread Updater', ThreadUpdater], ['Thread Watcher', ThreadWatcher], ['Thread Watcher (Menu)', ThreadWatcher.menu], ['Mark New IPs', MarkNewIPs], ['Index Navigation', Nav], ['Keybinds', Keybinds], ['Banner', Banner], ['Flash Features', Flash]]
|
||||||
};
|
};
|
||||||
|
|
||||||
Main.init();
|
Main.init();
|
||||||
|
|||||||
Binary file not shown.
@ -1,6 +1,6 @@
|
|||||||
// ==UserScript==
|
// ==UserScript==
|
||||||
// @name 4chan X
|
// @name 4chan X
|
||||||
// @version 1.11.1.3
|
// @version 1.11.2.0
|
||||||
// @minGMVer 1.14
|
// @minGMVer 1.14
|
||||||
// @minFFVer 26
|
// @minFFVer 26
|
||||||
// @namespace 4chan-X
|
// @namespace 4chan-X
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
// Generated by CoffeeScript
|
// Generated by CoffeeScript
|
||||||
// ==UserScript==
|
// ==UserScript==
|
||||||
// @name 4chan X
|
// @name 4chan X
|
||||||
// @version 1.11.1.3
|
// @version 1.11.2.0
|
||||||
// @minGMVer 1.14
|
// @minGMVer 1.14
|
||||||
// @minFFVer 26
|
// @minFFVer 26
|
||||||
// @namespace 4chan-X
|
// @namespace 4chan-X
|
||||||
@ -242,12 +242,12 @@
|
|||||||
'Hide Original Post Form': [true, 'Hide the normal post form.', 1],
|
'Hide Original Post Form': [true, 'Hide the normal post form.', 1],
|
||||||
'Cooldown': [true, 'Indicate the remaining time before posting again.', 1],
|
'Cooldown': [true, 'Indicate the remaining time before posting again.', 1],
|
||||||
'Posting Success Notifications': [true, 'Show notifications on successful post creation or file uploading.', 1],
|
'Posting Success Notifications': [true, 'Show notifications on successful post creation or file uploading.', 1],
|
||||||
'Use Recaptcha v1': [false, 'Use the old text version of Recaptcha.', 1],
|
|
||||||
'Force Noscript Captcha': [false, 'Use the non-Javascript fallback captcha in the QR even if Javascript is enabled.', 1],
|
'Force Noscript Captcha': [false, 'Use the non-Javascript fallback captcha in the QR even if Javascript is enabled.', 1],
|
||||||
'Auto-load captcha': [false, 'Automatically load the captcha in the QR even if your post is empty.', 1],
|
'Auto-load captcha': [false, 'Automatically load the captcha in the QR even if your post is empty.', 1],
|
||||||
'Post on Captcha Completion': [false, 'Submit the post immediately when the captcha is completed.', 1],
|
'Post on Captcha Completion': [false, 'Submit the post immediately when the captcha is completed.', 1],
|
||||||
'Bottom QR Link': [true, 'Places a link on the bottom of threads to open the QR.', 1],
|
'Bottom QR Link': [true, 'Places a link on the bottom of threads to open the QR.', 1],
|
||||||
'Captcha Fixes': [true, 'Make captcha easier to use, especially with the keyboard.'],
|
'Captcha Fixes': [true, 'Make captcha easier to use, especially with the keyboard.'],
|
||||||
|
'Use Recaptcha v1': [false, 'Use the old text version of Recaptcha.'],
|
||||||
'Use Recaptcha v2 in Reports': [false, 'Use the image selection captcha in the report window.']
|
'Use Recaptcha v2 in Reports': [false, 'Use the image selection captcha in the report window.']
|
||||||
},
|
},
|
||||||
'Quote Links': {
|
'Quote Links': {
|
||||||
@ -299,7 +299,7 @@
|
|||||||
tripcode: "# Filter any tripfag\n#/^!/",
|
tripcode: "# Filter any tripfag\n#/^!/",
|
||||||
capcode: "# Set a custom class for mods:\n#/Mod$/;highlight:mod;op:yes\n# Set a custom class for moot:\n#/Admin$/;highlight:moot;op:yes",
|
capcode: "# Set a custom class for mods:\n#/Mod$/;highlight:mod;op:yes\n# Set a custom class for moot:\n#/Admin$/;highlight:moot;op:yes",
|
||||||
subject: "# Filter Generals on /v/:\n#/general/i;boards:v;op:only",
|
subject: "# Filter Generals on /v/:\n#/general/i;boards:v;op:only",
|
||||||
comment: "# Filter Stallman copypasta on /g/:\n#/what you\'re refer+ing to as linux/i;boards:g",
|
comment: "# Filter Stallman copypasta on /g/:\n#/what you\'re refer+ing to as linux/i;boards:g\n# Filter posts with 10 or more quote links:\n#/(?:>>\\d(?:(?!>>\\d)[^])*){10}/",
|
||||||
flag: '',
|
flag: '',
|
||||||
filename: '',
|
filename: '',
|
||||||
dimensions: "# Highlight potential wallpapers:\n#/1920x1080/;op:yes;highlight;top:no;boards:w,wg",
|
dimensions: "# Highlight potential wallpapers:\n#/1920x1080/;op:yes;highlight;top:no;boards:w,wg",
|
||||||
@ -411,7 +411,7 @@
|
|||||||
doc = d.documentElement;
|
doc = d.documentElement;
|
||||||
|
|
||||||
g = {
|
g = {
|
||||||
VERSION: '1.11.1.3',
|
VERSION: '1.11.2.0',
|
||||||
NAMESPACE: '4chan X.',
|
NAMESPACE: '4chan X.',
|
||||||
boards: {}
|
boards: {}
|
||||||
};
|
};
|
||||||
@ -1523,7 +1523,6 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
Post.prototype.collect = function() {
|
Post.prototype.collect = function() {
|
||||||
this.kill();
|
|
||||||
g.posts.rm(this.fullID);
|
g.posts.rm(this.fullID);
|
||||||
this.thread.posts.rm(this);
|
this.thread.posts.rm(this);
|
||||||
return this.board.posts.rm(this);
|
return this.board.posts.rm(this);
|
||||||
@ -6956,24 +6955,26 @@
|
|||||||
return alert(el.textContent);
|
return alert(el.textContent);
|
||||||
}
|
}
|
||||||
} else if (d.hidden || !(focusOverride || d.hasFocus())) {
|
} else if (d.hidden || !(focusOverride || d.hasFocus())) {
|
||||||
notif = new Notification(el.textContent, {
|
try {
|
||||||
body: el.textContent,
|
notif = new Notification(el.textContent, {
|
||||||
icon: Favicon.logo
|
body: el.textContent,
|
||||||
});
|
icon: Favicon.logo
|
||||||
notif.onclick = function() {
|
});
|
||||||
return window.focus();
|
notif.onclick = function() {
|
||||||
};
|
return window.focus();
|
||||||
if (typeof chrome !== "undefined" && chrome !== null) {
|
|
||||||
notif.onclose = function() {
|
|
||||||
return notice.close();
|
|
||||||
};
|
};
|
||||||
return notif.onshow = function() {
|
if (typeof chrome !== "undefined" && chrome !== null) {
|
||||||
return setTimeout(function() {
|
notif.onclose = function() {
|
||||||
notif.onclose = null;
|
return notice.close();
|
||||||
return notif.close();
|
};
|
||||||
}, 7 * $.SECOND);
|
return notif.onshow = function() {
|
||||||
};
|
return setTimeout(function() {
|
||||||
}
|
notif.onclose = null;
|
||||||
|
return notif.close();
|
||||||
|
}, 7 * $.SECOND);
|
||||||
|
};
|
||||||
|
}
|
||||||
|
} catch (_error) {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
notifications: [],
|
notifications: [],
|
||||||
@ -7820,33 +7821,6 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
Captcha.language = {
|
|
||||||
init: function() {
|
|
||||||
if (!(Conf['captchaLanguage'].trim() && d.cookie.indexOf('pass_enabled=1') < 0 && !Conf['Hide Original Post Form'])) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
return $.onExists(doc, '#captchaFormPart', true, function(node) {
|
|
||||||
return $.onExists(node, 'iframe', true, Captcha.language.fixIframe);
|
|
||||||
});
|
|
||||||
},
|
|
||||||
fixPage: function() {
|
|
||||||
if (!(Conf['captchaLanguage'].trim() && d.cookie.indexOf('pass_enabled=1') < 0)) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
return $.onExists(doc, 'iframe', true, Captcha.language.fixIframe);
|
|
||||||
},
|
|
||||||
fixIframe: function(el) {
|
|
||||||
var lang, src;
|
|
||||||
if (!(lang = Conf['captchaLanguage'].trim())) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
src = /[?&]hl=/.test(el.src) ? el.src.replace(/([?&]hl=)[^&]*/, '$1' + encodeURIComponent(lang)) : el.src + ("&hl=" + (encodeURIComponent(lang)));
|
|
||||||
if (el.src !== src) {
|
|
||||||
return el.src = src;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
Captcha.noscript = {
|
Captcha.noscript = {
|
||||||
lifetime: 30 * $.MINUTE,
|
lifetime: 30 * $.MINUTE,
|
||||||
init: function() {
|
init: function() {
|
||||||
@ -7854,7 +7828,7 @@
|
|||||||
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!(this.isEnabled = !!$.id('g-recaptcha'))) {
|
if (!(this.isEnabled = !!$('#g-recaptcha, #captchaContainerAlt'))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
container = $.el('div', {
|
container = $.el('div', {
|
||||||
@ -8182,24 +8156,97 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
Captcha.v1 = {
|
Captcha.replace = {
|
||||||
init: function() {
|
init: function() {
|
||||||
var captchaContainer, imgContainer, input, script;
|
var jsEnabled;
|
||||||
|
if (!(d.cookie.indexOf('pass_enabled=1') < 0)) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (location.hostname === 'boards.4chan.org' && Conf['Hide Original Post Form']) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
jsEnabled = $.hasClass(doc, 'js-enabled');
|
||||||
|
if (location.hostname === 'sys.4chan.org' && Conf['Use Recaptcha v2 in Reports'] && jsEnabled) {
|
||||||
|
$.ready(Captcha.replace.v2);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (Conf['Use Recaptcha v1'] && jsEnabled && location.hostname !== 'www.4chan.org') {
|
||||||
|
$.ready(Captcha.replace.v1);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (Conf['captchaLanguage'].trim()) {
|
||||||
|
if (location.hostname === 'boards.4chan.org') {
|
||||||
|
return $.onExists(doc, '#captchaFormPart', true, function(node) {
|
||||||
|
return $.onExists(node, 'iframe', true, Captcha.replace.iframe);
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
return $.onExists(doc, 'iframe', true, Captcha.replace.iframe);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
v1: function() {
|
||||||
|
var form, link;
|
||||||
|
if (!$.id('g-recaptcha')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
Captcha.v1.replace();
|
||||||
|
if (link = $.id('form-link')) {
|
||||||
|
return $.on(link, 'click', function() {
|
||||||
|
return Captcha.v1.create();
|
||||||
|
});
|
||||||
|
} else if (location.hostname === 'boards.4chan.org') {
|
||||||
|
form = $.id('postForm');
|
||||||
|
return form.addEventListener('focus', (function() {
|
||||||
|
return Captcha.v1.create();
|
||||||
|
}), true);
|
||||||
|
} else {
|
||||||
|
return Captcha.v1.create();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
v2: function() {
|
||||||
|
var container, lang, old, script, url;
|
||||||
|
if (!(old = $.id('captchaContainerAlt'))) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
container = $.el('div', {
|
||||||
|
className: 'g-recaptcha'
|
||||||
|
});
|
||||||
|
$.extend(container.dataset, {
|
||||||
|
sitekey: '6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc',
|
||||||
|
tabindex: 3
|
||||||
|
});
|
||||||
|
$.replace(old, container);
|
||||||
|
url = 'https://www.google.com/recaptcha/api.js';
|
||||||
|
if (lang = Conf['captchaLanguage'].trim()) {
|
||||||
|
url += "?hl=" + (encodeURIComponent(lang));
|
||||||
|
}
|
||||||
|
script = $.el('script', {
|
||||||
|
src: url
|
||||||
|
});
|
||||||
|
return $.add(d.head, script);
|
||||||
|
},
|
||||||
|
iframe: function(el) {
|
||||||
|
var lang, src;
|
||||||
|
if (!(lang = Conf['captchaLanguage'].trim())) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
src = /[?&]hl=/.test(el.src) ? el.src.replace(/([?&]hl=)[^&]*/, '$1' + encodeURIComponent(lang)) : el.src + ("&hl=" + (encodeURIComponent(lang)));
|
||||||
|
if (el.src !== src) {
|
||||||
|
return el.src = src;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
Captcha.v1 = {
|
||||||
|
blank: "data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='300' height='57'/>",
|
||||||
|
init: function() {
|
||||||
|
var imgContainer, input;
|
||||||
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!(this.isEnabled = !!$.id('g-recaptcha'))) {
|
if (!(this.isEnabled = !!$('#g-recaptcha, #captchaContainerAlt'))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
script = $.el('script', {
|
|
||||||
src: '//www.google.com/recaptcha/api/js/recaptcha_ajax.js'
|
|
||||||
});
|
|
||||||
$.add(d.head, script);
|
|
||||||
captchaContainer = $.el('div', {
|
|
||||||
id: 'captchaContainer',
|
|
||||||
hidden: true
|
|
||||||
});
|
|
||||||
$.add(d.body, captchaContainer);
|
|
||||||
imgContainer = $.el('div', {
|
imgContainer = $.el('div', {
|
||||||
className: 'captcha-img',
|
className: 'captcha-img',
|
||||||
title: 'Reload reCAPTCHA'
|
title: 'Reload reCAPTCHA'
|
||||||
@ -8231,13 +8278,36 @@
|
|||||||
return QR.captcha.clear();
|
return QR.captcha.clear();
|
||||||
});
|
});
|
||||||
$.sync('captchas', this.sync);
|
$.sync('captchas', this.sync);
|
||||||
new MutationObserver(this.afterSetup).observe($.id('captchaContainer'), {
|
|
||||||
childList: true
|
|
||||||
});
|
|
||||||
this.beforeSetup();
|
this.beforeSetup();
|
||||||
if (Conf['Auto-load captcha']) {
|
if (Conf['Auto-load captcha']) {
|
||||||
return this.setup();
|
this.setup();
|
||||||
}
|
}
|
||||||
|
new MutationObserver(this.afterSetup).observe($.id('captchaContainerAlt'), {
|
||||||
|
childList: true
|
||||||
|
});
|
||||||
|
return this.afterSetup();
|
||||||
|
},
|
||||||
|
replace: function() {
|
||||||
|
var container, old;
|
||||||
|
if (this.script) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (!(this.script = $('script[src="//www.google.com/recaptcha/api/js/recaptcha_ajax.js"]', d.head))) {
|
||||||
|
this.script = $.el('script', {
|
||||||
|
src: '//www.google.com/recaptcha/api/js/recaptcha_ajax.js'
|
||||||
|
});
|
||||||
|
$.add(d.head, this.script);
|
||||||
|
}
|
||||||
|
if (old = $.id('g-recaptcha')) {
|
||||||
|
container = $.el('div', {
|
||||||
|
id: 'captchaContainerAlt'
|
||||||
|
});
|
||||||
|
return $.replace(old, container);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
create: function() {
|
||||||
|
this.replace();
|
||||||
|
return $.globalEval('(function() {\n var container = document.getElementById("captchaContainerAlt");\n if (container.firstChild) return;\n var options = {\n theme: "clean",\n tabindex: {"boards.4chan.org": 5, "sys.4chan.org": 3}[location.hostname]\n };\n if (window.Recaptcha) {\n window.Recaptcha.create("6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc", container, options);\n } else {\n var script = document.head.querySelector(\'script[src="//www.google.com/recaptcha/api/js/recaptcha_ajax.js"]\');\n script.addEventListener(\'load\', function() {\n window.Recaptcha.create("6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc", container, options);\n }, false);\n }\n})();');
|
||||||
},
|
},
|
||||||
cb: {
|
cb: {
|
||||||
focus: function() {
|
focus: function() {
|
||||||
@ -8248,6 +8318,7 @@
|
|||||||
var img, input, ref;
|
var img, input, ref;
|
||||||
ref = this.nodes, img = ref.img, input = ref.input;
|
ref = this.nodes, img = ref.img, input = ref.input;
|
||||||
img.parentNode.hidden = true;
|
img.parentNode.hidden = true;
|
||||||
|
img.src = this.blank;
|
||||||
input.value = '';
|
input.value = '';
|
||||||
input.placeholder = 'Focus to load reCAPTCHA';
|
input.placeholder = 'Focus to load reCAPTCHA';
|
||||||
this.count();
|
this.count();
|
||||||
@ -8268,10 +8339,10 @@
|
|||||||
onNewPost: function() {},
|
onNewPost: function() {},
|
||||||
onPostChange: function() {},
|
onPostChange: function() {},
|
||||||
setup: function(focus, force) {
|
setup: function(focus, force) {
|
||||||
if (!(this.isEnabled && (this.needed() || force))) {
|
if (!(this.isEnabled && (force || this.needed()))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$.globalEval('(function() {\n var captchaContainer = document.getElementById("captchaContainer");\n if (captchaContainer.firstChild) return;\n function setup() {\n if (window.Recaptcha) {\n Recaptcha.create(recaptchaKey, captchaContainer, {theme: "clean"});\n } else {\n setTimeout(setup, 25);\n }\n }\n setup();\n})()');
|
this.create();
|
||||||
if (focus) {
|
if (focus) {
|
||||||
return this.nodes.input.focus();
|
return this.nodes.input.focus();
|
||||||
}
|
}
|
||||||
@ -8308,11 +8379,13 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
destroy: function() {
|
destroy: function() {
|
||||||
if (!this.isEnabled) {
|
if (!this.script) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$.globalEval('Recaptcha.destroy()');
|
$.globalEval('window.Recaptcha.destroy();');
|
||||||
return this.beforeSetup();
|
if (this.nodes) {
|
||||||
|
return this.beforeSetup();
|
||||||
|
}
|
||||||
},
|
},
|
||||||
sync: function(captchas) {
|
sync: function(captchas) {
|
||||||
if (captchas == null) {
|
if (captchas == null) {
|
||||||
@ -8380,6 +8453,10 @@
|
|||||||
},
|
},
|
||||||
load: function() {
|
load: function() {
|
||||||
var challenge, challenge_image;
|
var challenge, challenge_image;
|
||||||
|
if ($('#captchaContainerAlt[class~="recaptcha_is_showing_audio"]')) {
|
||||||
|
this.nodes.img.src = this.blank;
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (!this.nodes.challenge.firstChild) {
|
if (!this.nodes.challenge.firstChild) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -8390,7 +8467,7 @@
|
|||||||
challenge = this.nodes.challenge.firstChild.value;
|
challenge = this.nodes.challenge.firstChild.value;
|
||||||
this.nodes.img.alt = challenge;
|
this.nodes.img.alt = challenge;
|
||||||
this.nodes.img.src = challenge_image.src;
|
this.nodes.img.src = challenge_image.src;
|
||||||
this.nodes.input.value = null;
|
this.nodes.input.value = '';
|
||||||
return this.clear();
|
return this.clear();
|
||||||
},
|
},
|
||||||
count: function() {
|
count: function() {
|
||||||
@ -8416,7 +8493,7 @@
|
|||||||
return this.nodes.input.alt = count;
|
return this.nodes.input.alt = count;
|
||||||
},
|
},
|
||||||
reload: function(focus) {
|
reload: function(focus) {
|
||||||
$.globalEval('Recaptcha.reload(); Recaptcha.should_focus = false;');
|
$.globalEval('if (window.Recaptcha.type === "image") {\n window.Recaptcha.reload();\n} else {\n window.Recaptcha.switch_type("image");\n}\nwindow.Recaptcha.should_focus = false;');
|
||||||
if (focus) {
|
if (focus) {
|
||||||
return this.nodes.input.focus();
|
return this.nodes.input.focus();
|
||||||
}
|
}
|
||||||
@ -8440,7 +8517,7 @@
|
|||||||
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
if (d.cookie.indexOf('pass_enabled=1') >= 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!(this.isEnabled = !!$.id('g-recaptcha'))) {
|
if (!(this.isEnabled = !!$('#g-recaptcha, #captchaContainerAlt'))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (this.noscript = Conf['Force Noscript Captcha'] || !$.hasClass(doc, 'js-enabled')) {
|
if (this.noscript = Conf['Force Noscript Captcha'] || !$.hasClass(doc, 'js-enabled')) {
|
||||||
@ -8475,6 +8552,16 @@
|
|||||||
$.addClass(QR.nodes.el, 'has-captcha', 'captcha-v2');
|
$.addClass(QR.nodes.el, 'has-captcha', 'captcha-v2');
|
||||||
$.after(QR.nodes.com.parentNode, root);
|
$.after(QR.nodes.com.parentNode, root);
|
||||||
$.on(counter, 'click', this.toggle.bind(this));
|
$.on(counter, 'click', this.toggle.bind(this));
|
||||||
|
$.on(counter, 'keydown', (function(_this) {
|
||||||
|
return function(e) {
|
||||||
|
if (Keybinds.keyCode(e) !== 'Space') {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
_this.toggle();
|
||||||
|
e.preventDefault();
|
||||||
|
return e.stopPropagation();
|
||||||
|
};
|
||||||
|
})(this));
|
||||||
return $.on(window, 'captcha:success', (function(_this) {
|
return $.on(window, 'captcha:success', (function(_this) {
|
||||||
return function() {
|
return function() {
|
||||||
return $.queueTask(function() {
|
return $.queueTask(function() {
|
||||||
@ -8597,7 +8684,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
setupIFrame: function(iframe) {
|
setupIFrame: function(iframe) {
|
||||||
Captcha.language.fixIframe(iframe);
|
Captcha.replace.iframe(iframe);
|
||||||
$.addClass(QR.nodes.el, 'captcha-open');
|
$.addClass(QR.nodes.el, 'captcha-open');
|
||||||
if (QR.nodes.el.getBoundingClientRect().bottom > doc.clientHeight) {
|
if (QR.nodes.el.getBoundingClientRect().bottom > doc.clientHeight) {
|
||||||
QR.nodes.el.style.top = null;
|
QR.nodes.el.style.top = null;
|
||||||
@ -13912,19 +13999,21 @@
|
|||||||
if (!Header.areNotificationsEnabled) {
|
if (!Header.areNotificationsEnabled) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
notif = new Notification(post.info.nameBlock + " replied to you", {
|
try {
|
||||||
body: post.info.commentDisplay,
|
notif = new Notification(post.info.nameBlock + " replied to you", {
|
||||||
icon: Favicon.logo
|
body: post.info.commentDisplay,
|
||||||
});
|
icon: Favicon.logo
|
||||||
notif.onclick = function() {
|
});
|
||||||
Header.scrollToIfNeeded(post.nodes.root, true);
|
notif.onclick = function() {
|
||||||
return window.focus();
|
Header.scrollToIfNeeded(post.nodes.root, true);
|
||||||
};
|
return window.focus();
|
||||||
return notif.onshow = function() {
|
};
|
||||||
return setTimeout(function() {
|
return notif.onshow = function() {
|
||||||
return notif.close();
|
return setTimeout(function() {
|
||||||
}, 7 * $.SECOND);
|
return notif.close();
|
||||||
};
|
}, 7 * $.SECOND);
|
||||||
|
};
|
||||||
|
} catch (_error) {}
|
||||||
},
|
},
|
||||||
onUpdate: function(e) {
|
onUpdate: function(e) {
|
||||||
if (!e.detail[404]) {
|
if (!e.detail[404]) {
|
||||||
@ -15905,21 +15994,18 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
Report = {
|
Report = {
|
||||||
css: "noscript > div, noscript > div > div {\n" +
|
css: ":root:not(.js-enabled) #captchaContainerAlt {\n" +
|
||||||
" height: 545px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"noscript > div > div > div:first-child, noscript iframe {\n" +
|
|
||||||
" height: 423px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
":root:not(.js-enabled) #g-recaptcha {\n" +
|
|
||||||
" height: auto;\n" +
|
" height: auto;\n" +
|
||||||
|
"}\n" +
|
||||||
|
"noscript > iframe, #recaptcha_challenge_field {\n" +
|
||||||
|
" width: 500px;\n" +
|
||||||
"}",
|
"}",
|
||||||
init: function() {
|
init: function() {
|
||||||
var match;
|
var match;
|
||||||
if (!(/\bmode=report\b/.test(location.search) && (match = location.search.match(/\bno=(\d+)/)))) {
|
if (!(/\bmode=report\b/.test(location.search) && (match = location.search.match(/\bno=(\d+)/)))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
Captcha.language.fixPage();
|
Captcha.replace.init();
|
||||||
this.postID = +match[1];
|
this.postID = +match[1];
|
||||||
return $.ready(this.ready);
|
return $.ready(this.ready);
|
||||||
},
|
},
|
||||||
@ -15928,9 +16014,6 @@
|
|||||||
if (Conf['Archive Report']) {
|
if (Conf['Archive Report']) {
|
||||||
Report.archive();
|
Report.archive();
|
||||||
}
|
}
|
||||||
if (Conf['Use Recaptcha v2 in Reports']) {
|
|
||||||
Report.captchaV2();
|
|
||||||
}
|
|
||||||
if (Conf['Use Recaptcha v2 in Reports'] && $.hasClass(doc, 'js-enabled')) {
|
if (Conf['Use Recaptcha v2 in Reports'] && $.hasClass(doc, 'js-enabled')) {
|
||||||
return new MutationObserver(function() {
|
return new MutationObserver(function() {
|
||||||
return Report.fit('.gc-bubbleDefault');
|
return Report.fit('.gc-bubbleDefault');
|
||||||
@ -15943,25 +16026,6 @@
|
|||||||
return Report.fit('body');
|
return Report.fit('body');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
captchaV2: function() {
|
|
||||||
var container, lang, old, script, url;
|
|
||||||
if (!(old = $.id('captchaContainerAlt'))) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
container = $.el('div', {
|
|
||||||
className: 'g-recaptcha'
|
|
||||||
});
|
|
||||||
container.dataset.sitekey = '6Ldp2bsSAAAAAAJ5uyx_lx34lJeEpTLVkP5k04qc';
|
|
||||||
$.replace(old, container);
|
|
||||||
url = 'https://www.google.com/recaptcha/api.js';
|
|
||||||
if (lang = Conf['captchaLanguage'].trim()) {
|
|
||||||
url += "?hl=" + (encodeURIComponent(lang));
|
|
||||||
}
|
|
||||||
script = $.el('script', {
|
|
||||||
src: url
|
|
||||||
});
|
|
||||||
return $.add(d.head, script);
|
|
||||||
},
|
|
||||||
fit: function(selector) {
|
fit: function(selector) {
|
||||||
var dy, el;
|
var dy, el;
|
||||||
if (!(el = $(selector, doc))) {
|
if (!(el = $(selector, doc))) {
|
||||||
@ -16830,19 +16894,6 @@
|
|||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (location.hostname === 'www.4chan.org') {
|
|
||||||
$.onExists(d.documentElement, 'body', false, function() {
|
|
||||||
return $.addStyle(Main.cssWWW);
|
|
||||||
});
|
|
||||||
Conf = {
|
|
||||||
'captchaLanguage': Config.captchaLanguage
|
|
||||||
};
|
|
||||||
$.get(Conf, function(items) {
|
|
||||||
$.extend(Conf, items);
|
|
||||||
return Captcha.language.fixPage();
|
|
||||||
});
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
g.threads = new SimpleDict();
|
g.threads = new SimpleDict();
|
||||||
g.posts = new SimpleDict();
|
g.posts = new SimpleDict();
|
||||||
pathname = location.pathname.split('/');
|
pathname = location.pathname.split('/');
|
||||||
@ -16911,10 +16962,13 @@
|
|||||||
},
|
},
|
||||||
initFeatures: function() {
|
initFeatures: function() {
|
||||||
var err, feature, k, len1, name, pathname, ref, ref1, ref2;
|
var err, feature, k, len1, name, pathname, ref, ref1, ref2;
|
||||||
if ((ref = location.hostname) === 'boards.4chan.org' || ref === 'sys.4chan.org') {
|
if ((ref = location.hostname) === 'boards.4chan.org' || ref === 'sys.4chan.org' || ref === 'www.4chan.org') {
|
||||||
$.globalEval('document.documentElement.classList.add("js-enabled");');
|
$.globalEval('document.documentElement.classList.add("js-enabled");');
|
||||||
}
|
}
|
||||||
switch (location.hostname) {
|
switch (location.hostname) {
|
||||||
|
case 'www.4chan.org':
|
||||||
|
Captcha.replace.init();
|
||||||
|
return;
|
||||||
case 'a.4cdn.org':
|
case 'a.4cdn.org':
|
||||||
return;
|
return;
|
||||||
case 'sys.4chan.org':
|
case 'sys.4chan.org':
|
||||||
@ -16974,6 +17028,9 @@
|
|||||||
},
|
},
|
||||||
initStyle: function() {
|
initStyle: function() {
|
||||||
var keyboard, ref;
|
var keyboard, ref;
|
||||||
|
if (location.hostname === 'www.4chan.org') {
|
||||||
|
$.addStyle(Main.cssWWW);
|
||||||
|
}
|
||||||
if (!Main.isThisPageLegit() || $.hasClass(doc, 'fourchan-x')) {
|
if (!Main.isThisPageLegit() || $.hasClass(doc, 'fourchan-x')) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -17802,15 +17859,6 @@
|
|||||||
" 0% {transform:rotate(0deg);}\n" +
|
" 0% {transform:rotate(0deg);}\n" +
|
||||||
" 100% {transform:rotate(359deg);}\n" +
|
" 100% {transform:rotate(359deg);}\n" +
|
||||||
"}\n" +
|
"}\n" +
|
||||||
"noscript > div, noscript > div > div {\n" +
|
|
||||||
" height: 545px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"noscript > div > div > div:first-child, noscript iframe {\n" +
|
|
||||||
" height: 423px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
":root:not(.js-enabled) #g-recaptcha {\n" +
|
|
||||||
" height: auto;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"/* General */\n" +
|
"/* General */\n" +
|
||||||
".dialog {\n" +
|
".dialog {\n" +
|
||||||
" border: 1px solid;\n" +
|
" border: 1px solid;\n" +
|
||||||
@ -17920,6 +17968,9 @@
|
|||||||
":root:not(.js-enabled) #postForm {\n" +
|
":root:not(.js-enabled) #postForm {\n" +
|
||||||
" display: table;\n" +
|
" display: table;\n" +
|
||||||
"}\n" +
|
"}\n" +
|
||||||
|
"#captchaContainerAlt td:nth-child(2) {\n" +
|
||||||
|
" display: table-cell !important;\n" +
|
||||||
|
"}\n" +
|
||||||
"/* Anti-autoplay */\n" +
|
"/* Anti-autoplay */\n" +
|
||||||
"audio.controls-added {\n" +
|
"audio.controls-added {\n" +
|
||||||
" display: block;\n" +
|
" display: block;\n" +
|
||||||
@ -20217,19 +20268,10 @@
|
|||||||
" font-family: sans-serif !important;\n" +
|
" font-family: sans-serif !important;\n" +
|
||||||
" text-shadow: 1px 1px 1px rgba(0,74,153,0.6);\n" +
|
" text-shadow: 1px 1px 1px rgba(0,74,153,0.6);\n" +
|
||||||
"}",
|
"}",
|
||||||
cssWWW: "noscript > div, noscript > div > div {\n" +
|
cssWWW: "#captcha-cnt {\n" +
|
||||||
" height: 545px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"noscript > div > div > div:first-child, noscript iframe {\n" +
|
|
||||||
" height: 423px !important;\n" +
|
|
||||||
"}\n" +
|
|
||||||
":root:not(.js-enabled) #g-recaptcha {\n" +
|
|
||||||
" height: auto;\n" +
|
|
||||||
"}\n" +
|
|
||||||
"#captcha-cnt {\n" +
|
|
||||||
" height: auto;\n" +
|
" height: auto;\n" +
|
||||||
"}",
|
"}",
|
||||||
features: [['Polyfill', Polyfill], ['Captcha Language', Captcha.language], ['Redirect', Redirect], ['Header', Header], ['Catalog Links', CatalogLinks], ['Settings', Settings], ['Index Generator', Index], ['Disable Autoplay', AntiAutoplay], ['Announcement Hiding', PSAHiding], ['Fourchan thingies', Fourchan], ['Color User IDs', IDColor], ['Highlight by User ID', IDHighlight], ['Custom CSS', CustomCSS], ['Linkify', Linkify], ['Reveal Spoilers', RemoveSpoilers], ['Resurrect Quotes', Quotify], ['Filter', Filter], ['Thread Hiding Buttons', ThreadHiding], ['Reply Hiding Buttons', PostHiding], ['Recursive', Recursive], ['Strike-through Quotes', QuoteStrikeThrough], ['Quick Reply', QR], ['Menu', Menu], ['Index Generator (Menu)', Index.menu], ['Report Link', ReportLink], ['Thread Hiding (Menu)', ThreadHiding.menu], ['Reply Hiding (Menu)', PostHiding.menu], ['Delete Link', DeleteLink], ['Filter (Menu)', Filter.menu], ['Download Link', DownloadLink], ['Archive Link', ArchiveLink], ['Quote Inlining', QuoteInline], ['Quote Previewing', QuotePreview], ['Quote Backlinks', QuoteBacklink], ['Mark Quotes of You', QuoteYou], ['Mark OP Quotes', QuoteOP], ['Mark Cross-thread Quotes', QuoteCT], ['Anonymize', Anonymize], ['Time Formatting', Time], ['Relative Post Dates', RelativeDates], ['File Info Formatting', FileInfo], ['Fappe Tyme', FappeTyme], ['Gallery', Gallery], ['Gallery (menu)', Gallery.menu], ['Sauce', Sauce], ['Image Expansion', ImageExpand], ['Image Expansion (Menu)', ImageExpand.menu], ['Reveal Spoiler Thumbnails', RevealSpoilers], ['Image Loading', ImageLoader], ['Image Hover', ImageHover], ['Volume Control', Volume], ['WEBM Metadata', Metadata], ['Comment Expansion', ExpandComment], ['Thread Expansion', ExpandThread], ['Thread Excerpt', ThreadExcerpt], ['Favicon', Favicon], ['Unread', Unread], ['Quote Threading', QuoteThreading], ['Thread Stats', ThreadStats], ['Thread Updater', ThreadUpdater], ['Thread Watcher', ThreadWatcher], ['Thread Watcher (Menu)', ThreadWatcher.menu], ['Mark New IPs', MarkNewIPs], ['Index Navigation', Nav], ['Keybinds', Keybinds], ['Banner', Banner], ['Flash Features', Flash]]
|
features: [['Polyfill', Polyfill], ['Captcha Replacement', Captcha.replace], ['Redirect', Redirect], ['Header', Header], ['Catalog Links', CatalogLinks], ['Settings', Settings], ['Index Generator', Index], ['Disable Autoplay', AntiAutoplay], ['Announcement Hiding', PSAHiding], ['Fourchan thingies', Fourchan], ['Color User IDs', IDColor], ['Highlight by User ID', IDHighlight], ['Custom CSS', CustomCSS], ['Linkify', Linkify], ['Reveal Spoilers', RemoveSpoilers], ['Resurrect Quotes', Quotify], ['Filter', Filter], ['Thread Hiding Buttons', ThreadHiding], ['Reply Hiding Buttons', PostHiding], ['Recursive', Recursive], ['Strike-through Quotes', QuoteStrikeThrough], ['Quick Reply', QR], ['Menu', Menu], ['Index Generator (Menu)', Index.menu], ['Report Link', ReportLink], ['Thread Hiding (Menu)', ThreadHiding.menu], ['Reply Hiding (Menu)', PostHiding.menu], ['Delete Link', DeleteLink], ['Filter (Menu)', Filter.menu], ['Download Link', DownloadLink], ['Archive Link', ArchiveLink], ['Quote Inlining', QuoteInline], ['Quote Previewing', QuotePreview], ['Quote Backlinks', QuoteBacklink], ['Mark Quotes of You', QuoteYou], ['Mark OP Quotes', QuoteOP], ['Mark Cross-thread Quotes', QuoteCT], ['Anonymize', Anonymize], ['Time Formatting', Time], ['Relative Post Dates', RelativeDates], ['File Info Formatting', FileInfo], ['Fappe Tyme', FappeTyme], ['Gallery', Gallery], ['Gallery (menu)', Gallery.menu], ['Sauce', Sauce], ['Image Expansion', ImageExpand], ['Image Expansion (Menu)', ImageExpand.menu], ['Reveal Spoiler Thumbnails', RevealSpoilers], ['Image Loading', ImageLoader], ['Image Hover', ImageHover], ['Volume Control', Volume], ['WEBM Metadata', Metadata], ['Comment Expansion', ExpandComment], ['Thread Expansion', ExpandThread], ['Thread Excerpt', ThreadExcerpt], ['Favicon', Favicon], ['Unread', Unread], ['Quote Threading', QuoteThreading], ['Thread Stats', ThreadStats], ['Thread Updater', ThreadUpdater], ['Thread Watcher', ThreadWatcher], ['Thread Watcher (Menu)', ThreadWatcher.menu], ['Mark New IPs', MarkNewIPs], ['Index Navigation', Nav], ['Keybinds', Keybinds], ['Banner', Banner], ['Flash Features', Flash]]
|
||||||
};
|
};
|
||||||
|
|
||||||
Main.init();
|
Main.init();
|
||||||
|
|||||||
Binary file not shown.
@ -1,7 +1,7 @@
|
|||||||
<?xml version='1.0' encoding='UTF-8'?>
|
<?xml version='1.0' encoding='UTF-8'?>
|
||||||
<gupdate xmlns='http://www.google.com/update2/response' protocol='2.0'>
|
<gupdate xmlns='http://www.google.com/update2/response' protocol='2.0'>
|
||||||
<app appid='lacclbnghgdicfifcamcmcnilckjamag'>
|
<app appid='lacclbnghgdicfifcamcmcnilckjamag'>
|
||||||
<updatecheck codebase='https://ccd0.github.io/4chan-x/builds/4chan-X-beta.crx' version='1.11.1.3' />
|
<updatecheck codebase='https://ccd0.github.io/4chan-x/builds/4chan-X-beta.crx' version='1.11.2.0' />
|
||||||
</app>
|
</app>
|
||||||
</gupdate>
|
</gupdate>
|
||||||
|
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
<?xml version='1.0' encoding='UTF-8'?>
|
<?xml version='1.0' encoding='UTF-8'?>
|
||||||
<gupdate xmlns='http://www.google.com/update2/response' protocol='2.0'>
|
<gupdate xmlns='http://www.google.com/update2/response' protocol='2.0'>
|
||||||
<app appid='lacclbnghgdicfifcamcmcnilckjamag'>
|
<app appid='lacclbnghgdicfifcamcmcnilckjamag'>
|
||||||
<updatecheck codebase='https://ccd0.github.io/4chan-x/builds/4chan-X.crx' version='1.11.1.3' />
|
<updatecheck codebase='https://ccd0.github.io/4chan-x/builds/4chan-X.crx' version='1.11.2.0' />
|
||||||
</app>
|
</app>
|
||||||
</gupdate>
|
</gupdate>
|
||||||
|
|
||||||
|
|||||||
@ -3,8 +3,8 @@
|
|||||||
"description": "Cross-browser userscript for maximum lurking on 4chan.",
|
"description": "Cross-browser userscript for maximum lurking on 4chan.",
|
||||||
"meta": {
|
"meta": {
|
||||||
"name": "4chan X",
|
"name": "4chan X",
|
||||||
"version": "1.11.1.3",
|
"version": "1.11.2.0",
|
||||||
"date": "2015-06-26T07:35:52.988Z",
|
"date": "2015-06-30T02:36:36.193Z",
|
||||||
"repo": "https://github.com/ccd0/4chan-x/",
|
"repo": "https://github.com/ccd0/4chan-x/",
|
||||||
"page": "https://github.com/ccd0/4chan-x",
|
"page": "https://github.com/ccd0/4chan-x",
|
||||||
"downloads": "https://ccd0.github.io/4chan-x/builds/",
|
"downloads": "https://ccd0.github.io/4chan-x/builds/",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user