Release 4chan X v1.8.6.
This commit is contained in:
parent
852aa277b2
commit
32200fa18a
@ -1,3 +1,6 @@
|
|||||||
|
### v1.8.6
|
||||||
|
*2014-07-13*
|
||||||
|
|
||||||
**ccd0**
|
**ccd0**
|
||||||
- Warn when redirecting from an HTTPS 404 page to an HTTP archive, and don't load unencrypted posts/images from archives when using HTTPS.
|
- Warn when redirecting from an HTTPS 404 page to an HTTP archive, and don't load unencrypted posts/images from archives when using HTTPS.
|
||||||
- `Loop in New Tab` now only makes the video loop, and doesn't apply any of your other settings.
|
- `Loop in New Tab` now only makes the video loop, and doesn't apply any of your other settings.
|
||||||
|
|||||||
2
LICENSE
2
LICENSE
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* 4chan X - Version 1.8.5.3 - 2014-07-13
|
* 4chan X - Version 1.8.6 - 2014-07-13
|
||||||
*
|
*
|
||||||
* Licensed under the MIT license.
|
* Licensed under the MIT license.
|
||||||
* https://github.com/ccd0/4chan-x/blob/master/LICENSE
|
* https://github.com/ccd0/4chan-x/blob/master/LICENSE
|
||||||
|
|||||||
Binary file not shown.
@ -1,6 +1,6 @@
|
|||||||
// ==UserScript==
|
// ==UserScript==
|
||||||
// @name 4chan X
|
// @name 4chan X
|
||||||
// @version 1.8.5.3
|
// @version 1.8.6
|
||||||
// @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.8.5.3
|
// @version 1.8.6
|
||||||
// @minGMVer 1.14
|
// @minGMVer 1.14
|
||||||
// @minFFVer 26
|
// @minFFVer 26
|
||||||
// @namespace 4chan-X
|
// @namespace 4chan-X
|
||||||
@ -24,7 +24,7 @@
|
|||||||
// ==/UserScript==
|
// ==/UserScript==
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* 4chan X - Version 1.8.5.3 - 2014-07-13
|
* 4chan X - Version 1.8.6 - 2014-07-13
|
||||||
*
|
*
|
||||||
* Licensed under the MIT license.
|
* Licensed under the MIT license.
|
||||||
* https://github.com/ccd0/4chan-x/blob/master/LICENSE
|
* https://github.com/ccd0/4chan-x/blob/master/LICENSE
|
||||||
@ -187,7 +187,7 @@
|
|||||||
'Werk Tyme': [false, 'Hide all post images.'],
|
'Werk Tyme': [false, 'Hide all post images.'],
|
||||||
'Autoplay': [true, 'Videos begin playing immediately when opened.'],
|
'Autoplay': [true, 'Videos begin playing immediately when opened.'],
|
||||||
'Show Controls': [true, 'Show controls on videos expanded inline. Turn this off if you want to contract videos by clicking on them.'],
|
'Show Controls': [true, 'Show controls on videos expanded inline. Turn this off if you want to contract videos by clicking on them.'],
|
||||||
'Loop in New Tab': [true, 'Loop videos opened in their own tabs, and apply settings for inline expanded videos to them.']
|
'Loop in New Tab': [true, 'Loop videos opened in their own tabs.']
|
||||||
},
|
},
|
||||||
'Menu': {
|
'Menu': {
|
||||||
'Menu': [true, 'Add a drop-down menu to posts.'],
|
'Menu': [true, 'Add a drop-down menu to posts.'],
|
||||||
@ -376,7 +376,7 @@
|
|||||||
doc = d.documentElement;
|
doc = d.documentElement;
|
||||||
|
|
||||||
g = {
|
g = {
|
||||||
VERSION: '1.8.5.3',
|
VERSION: '1.8.6',
|
||||||
NAMESPACE: '4chan X.',
|
NAMESPACE: '4chan X.',
|
||||||
boards: {}
|
boards: {}
|
||||||
};
|
};
|
||||||
@ -7782,6 +7782,8 @@
|
|||||||
});
|
});
|
||||||
if (URL) {
|
if (URL) {
|
||||||
thumb.href = URL;
|
thumb.href = URL;
|
||||||
|
}
|
||||||
|
if (URL && (/^https:\/\//.test(URL) || location.protocol === 'http:')) {
|
||||||
if (Gallery.nodes.current !== file) {
|
if (Gallery.nodes.current !== file) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -8242,7 +8244,7 @@
|
|||||||
boardID: src[3],
|
boardID: src[3],
|
||||||
filename: src[src.length - 1]
|
filename: src[src.length - 1]
|
||||||
});
|
});
|
||||||
if (URL) {
|
if (URL && (/^https:\/\//.test(URL) || location.protocol === 'http:')) {
|
||||||
setTimeout(ImageExpand.expand, 10000, post, URL);
|
setTimeout(ImageExpand.expand, 10000, post, URL);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -8400,7 +8402,7 @@
|
|||||||
boardID: src[3],
|
boardID: src[3],
|
||||||
filename: src[src.length - 1].replace(/\?.+$/, '')
|
filename: src[src.length - 1].replace(/\?.+$/, '')
|
||||||
});
|
});
|
||||||
if (URL) {
|
if (URL && (/^https:\/\//.test(URL) || location.protocol === 'http:')) {
|
||||||
this.src = URL;
|
this.src = URL;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -10903,9 +10905,13 @@
|
|||||||
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
||||||
},
|
},
|
||||||
post: function(archive, _arg) {
|
post: function(archive, _arg) {
|
||||||
var URL, boardID, postID;
|
var URL, boardID, postID, protocol;
|
||||||
boardID = _arg.boardID, postID = _arg.postID;
|
boardID = _arg.boardID, postID = _arg.postID;
|
||||||
URL = new String("" + (Redirect.protocol(archive)) + archive.domain + "/_/api/chan/post/?board=" + boardID + "&num=" + postID);
|
protocol = Redirect.protocol(archive);
|
||||||
|
if (!(protocol === 'https://' || location.protocol === 'http:')) {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
|
URL = new String("" + protocol + archive.domain + "/_/api/chan/post/?board=" + boardID + "&num=" + postID);
|
||||||
URL.archive = archive;
|
URL.archive = archive;
|
||||||
return URL;
|
return URL;
|
||||||
},
|
},
|
||||||
@ -10921,6 +10927,13 @@
|
|||||||
value = encodeURIComponent(value);
|
value = encodeURIComponent(value);
|
||||||
path = archive.software === 'foolfuuka' ? "" + boardID + "/search/" + type + "/" + value : "" + boardID + "/?task=search2&search_" + (type === 'image' ? 'media_hash' : type) + "=" + value;
|
path = archive.software === 'foolfuuka' ? "" + boardID + "/search/" + type + "/" + value : "" + boardID + "/?task=search2&search_" + (type === 'image' ? 'media_hash' : type) + "=" + value;
|
||||||
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
||||||
|
},
|
||||||
|
navigate: function(URL, alternative) {
|
||||||
|
if (/^https:\/\//.test(URL) || location.protocol === 'http:' || confirm("Redirect to " + URL + "?\n\nYour connection will not be encrypted.")) {
|
||||||
|
return location.replace(URL);
|
||||||
|
} else if (alternative) {
|
||||||
|
return location.replace(alternative);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -12506,7 +12519,7 @@
|
|||||||
Settings.dialog = dialog = $.el('div', {
|
Settings.dialog = dialog = $.el('div', {
|
||||||
id: 'fourchanx-settings',
|
id: 'fourchanx-settings',
|
||||||
className: 'dialog',
|
className: 'dialog',
|
||||||
innerHTML: '<nav><div class=sections-list></div><p class=\'imp-exp-result warning\'></p><div class=credits><a class=export>Export</a> | <a class=import>Import</a> | <a class=reset>Reset Settings</a> | <input type=file hidden><a href=\'https://github.com/ccd0/4chan-x\' target=_blank>4chan X</a> | <a href=\'https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md\' target=_blank>1.8.5.3</a> | <a href=\'https://github.com/ccd0/4chan-x/issues\' target=_blank>Issues</a> | <a href=javascript:; class=\'close fa fa-times\' title=Close></a></div></nav><div class=section-container><section></section></div>'
|
innerHTML: '<nav><div class=sections-list></div><p class=\'imp-exp-result warning\'></p><div class=credits><a class=export>Export</a> | <a class=import>Import</a> | <a class=reset>Reset Settings</a> | <input type=file hidden><a href=\'https://github.com/ccd0/4chan-x\' target=_blank>4chan X</a> | <a href=\'https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md\' target=_blank>1.8.6</a> | <a href=\'https://github.com/ccd0/4chan-x/issues\' target=_blank>Issues</a> | <a href=javascript:; class=\'close fa fa-times\' title=Close></a></div></nav><div class=section-container><section></section></div>'
|
||||||
});
|
});
|
||||||
$.on($('.export', Settings.dialog), 'click', Settings["export"]);
|
$.on($('.export', Settings.dialog), 'click', Settings["export"]);
|
||||||
$.on($('.import', Settings.dialog), 'click', Settings["import"]);
|
$.on($('.import', Settings.dialog), 'click', Settings["import"]);
|
||||||
@ -13181,20 +13194,9 @@
|
|||||||
boardID: g.BOARD.ID,
|
boardID: g.BOARD.ID,
|
||||||
filename: pathname[pathname.length - 1]
|
filename: pathname[pathname.length - 1]
|
||||||
});
|
});
|
||||||
if (URL) {
|
return Redirect.navigate(URL);
|
||||||
return location.replace(URL);
|
|
||||||
}
|
|
||||||
} else if (Conf['Loop in New Tab'] && (video = $('video'))) {
|
} else if (Conf['Loop in New Tab'] && (video = $('video'))) {
|
||||||
Video.configure(video);
|
return video.loop = true;
|
||||||
return $.on(video, 'click', function() {
|
|
||||||
if (!video.controls) {
|
|
||||||
if (video.paused) {
|
|
||||||
return video.play();
|
|
||||||
} else {
|
|
||||||
return video.pause();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
@ -13273,7 +13275,7 @@
|
|||||||
threadID: g.THREADID,
|
threadID: g.THREADID,
|
||||||
postID: +location.hash.match(/\d+/)
|
postID: +location.hash.match(/\d+/)
|
||||||
});
|
});
|
||||||
location.replace(href || ("/" + g.BOARD + "/"));
|
Redirect.navigate(href, "/" + g.BOARD + "/");
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -13358,7 +13360,7 @@
|
|||||||
}
|
}
|
||||||
if (previousversion) {
|
if (previousversion) {
|
||||||
el = $.el('span', {
|
el = $.el('span', {
|
||||||
innerHTML: '4chan X has been updated to <a href="https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md" target="_blank">version 1.8.5.3</a>.'
|
innerHTML: '4chan X has been updated to <a href="https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md" target="_blank">version 1.8.6</a>.'
|
||||||
});
|
});
|
||||||
new Notice('info', el, 15);
|
new Notice('info', el, 15);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Binary file not shown.
@ -1,7 +1,7 @@
|
|||||||
// Generated by CoffeeScript
|
// Generated by CoffeeScript
|
||||||
// ==UserScript==
|
// ==UserScript==
|
||||||
// @name 4chan X
|
// @name 4chan X
|
||||||
// @version 1.8.5.3
|
// @version 1.8.6
|
||||||
// @minGMVer 1.14
|
// @minGMVer 1.14
|
||||||
// @minFFVer 26
|
// @minFFVer 26
|
||||||
// @namespace 4chan-X
|
// @namespace 4chan-X
|
||||||
@ -23,7 +23,7 @@
|
|||||||
// ==/UserScript==
|
// ==/UserScript==
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* 4chan X - Version 1.8.5.3 - 2014-07-13
|
* 4chan X - Version 1.8.6 - 2014-07-13
|
||||||
*
|
*
|
||||||
* Licensed under the MIT license.
|
* Licensed under the MIT license.
|
||||||
* https://github.com/ccd0/4chan-x/blob/master/LICENSE
|
* https://github.com/ccd0/4chan-x/blob/master/LICENSE
|
||||||
@ -186,7 +186,7 @@
|
|||||||
'Werk Tyme': [false, 'Hide all post images.'],
|
'Werk Tyme': [false, 'Hide all post images.'],
|
||||||
'Autoplay': [true, 'Videos begin playing immediately when opened.'],
|
'Autoplay': [true, 'Videos begin playing immediately when opened.'],
|
||||||
'Show Controls': [true, 'Show controls on videos expanded inline. Turn this off if you want to contract videos by clicking on them.'],
|
'Show Controls': [true, 'Show controls on videos expanded inline. Turn this off if you want to contract videos by clicking on them.'],
|
||||||
'Loop in New Tab': [true, 'Loop videos opened in their own tabs, and apply settings for inline expanded videos to them.']
|
'Loop in New Tab': [true, 'Loop videos opened in their own tabs.']
|
||||||
},
|
},
|
||||||
'Menu': {
|
'Menu': {
|
||||||
'Menu': [true, 'Add a drop-down menu to posts.'],
|
'Menu': [true, 'Add a drop-down menu to posts.'],
|
||||||
@ -375,7 +375,7 @@
|
|||||||
doc = d.documentElement;
|
doc = d.documentElement;
|
||||||
|
|
||||||
g = {
|
g = {
|
||||||
VERSION: '1.8.5.3',
|
VERSION: '1.8.6',
|
||||||
NAMESPACE: '4chan X.',
|
NAMESPACE: '4chan X.',
|
||||||
boards: {}
|
boards: {}
|
||||||
};
|
};
|
||||||
@ -7781,6 +7781,8 @@
|
|||||||
});
|
});
|
||||||
if (URL) {
|
if (URL) {
|
||||||
thumb.href = URL;
|
thumb.href = URL;
|
||||||
|
}
|
||||||
|
if (URL && (/^https:\/\//.test(URL) || location.protocol === 'http:')) {
|
||||||
if (Gallery.nodes.current !== file) {
|
if (Gallery.nodes.current !== file) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -8241,7 +8243,7 @@
|
|||||||
boardID: src[3],
|
boardID: src[3],
|
||||||
filename: src[src.length - 1]
|
filename: src[src.length - 1]
|
||||||
});
|
});
|
||||||
if (URL) {
|
if (URL && (/^https:\/\//.test(URL) || location.protocol === 'http:')) {
|
||||||
setTimeout(ImageExpand.expand, 10000, post, URL);
|
setTimeout(ImageExpand.expand, 10000, post, URL);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -8399,7 +8401,7 @@
|
|||||||
boardID: src[3],
|
boardID: src[3],
|
||||||
filename: src[src.length - 1].replace(/\?.+$/, '')
|
filename: src[src.length - 1].replace(/\?.+$/, '')
|
||||||
});
|
});
|
||||||
if (URL) {
|
if (URL && (/^https:\/\//.test(URL) || location.protocol === 'http:')) {
|
||||||
this.src = URL;
|
this.src = URL;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -10902,9 +10904,13 @@
|
|||||||
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
||||||
},
|
},
|
||||||
post: function(archive, _arg) {
|
post: function(archive, _arg) {
|
||||||
var URL, boardID, postID;
|
var URL, boardID, postID, protocol;
|
||||||
boardID = _arg.boardID, postID = _arg.postID;
|
boardID = _arg.boardID, postID = _arg.postID;
|
||||||
URL = new String("" + (Redirect.protocol(archive)) + archive.domain + "/_/api/chan/post/?board=" + boardID + "&num=" + postID);
|
protocol = Redirect.protocol(archive);
|
||||||
|
if (!(protocol === 'https://' || location.protocol === 'http:')) {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
|
URL = new String("" + protocol + archive.domain + "/_/api/chan/post/?board=" + boardID + "&num=" + postID);
|
||||||
URL.archive = archive;
|
URL.archive = archive;
|
||||||
return URL;
|
return URL;
|
||||||
},
|
},
|
||||||
@ -10920,6 +10926,13 @@
|
|||||||
value = encodeURIComponent(value);
|
value = encodeURIComponent(value);
|
||||||
path = archive.software === 'foolfuuka' ? "" + boardID + "/search/" + type + "/" + value : "" + boardID + "/?task=search2&search_" + (type === 'image' ? 'media_hash' : type) + "=" + value;
|
path = archive.software === 'foolfuuka' ? "" + boardID + "/search/" + type + "/" + value : "" + boardID + "/?task=search2&search_" + (type === 'image' ? 'media_hash' : type) + "=" + value;
|
||||||
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
||||||
|
},
|
||||||
|
navigate: function(URL, alternative) {
|
||||||
|
if (/^https:\/\//.test(URL) || location.protocol === 'http:' || confirm("Redirect to " + URL + "?\n\nYour connection will not be encrypted.")) {
|
||||||
|
return location.replace(URL);
|
||||||
|
} else if (alternative) {
|
||||||
|
return location.replace(alternative);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -12505,7 +12518,7 @@
|
|||||||
Settings.dialog = dialog = $.el('div', {
|
Settings.dialog = dialog = $.el('div', {
|
||||||
id: 'fourchanx-settings',
|
id: 'fourchanx-settings',
|
||||||
className: 'dialog',
|
className: 'dialog',
|
||||||
innerHTML: '<nav><div class=sections-list></div><p class=\'imp-exp-result warning\'></p><div class=credits><a class=export>Export</a> | <a class=import>Import</a> | <a class=reset>Reset Settings</a> | <input type=file hidden><a href=\'https://github.com/ccd0/4chan-x\' target=_blank>4chan X</a> | <a href=\'https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md\' target=_blank>1.8.5.3</a> | <a href=\'https://github.com/ccd0/4chan-x/issues\' target=_blank>Issues</a> | <a href=javascript:; class=\'close fa fa-times\' title=Close></a></div></nav><div class=section-container><section></section></div>'
|
innerHTML: '<nav><div class=sections-list></div><p class=\'imp-exp-result warning\'></p><div class=credits><a class=export>Export</a> | <a class=import>Import</a> | <a class=reset>Reset Settings</a> | <input type=file hidden><a href=\'https://github.com/ccd0/4chan-x\' target=_blank>4chan X</a> | <a href=\'https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md\' target=_blank>1.8.6</a> | <a href=\'https://github.com/ccd0/4chan-x/issues\' target=_blank>Issues</a> | <a href=javascript:; class=\'close fa fa-times\' title=Close></a></div></nav><div class=section-container><section></section></div>'
|
||||||
});
|
});
|
||||||
$.on($('.export', Settings.dialog), 'click', Settings["export"]);
|
$.on($('.export', Settings.dialog), 'click', Settings["export"]);
|
||||||
$.on($('.import', Settings.dialog), 'click', Settings["import"]);
|
$.on($('.import', Settings.dialog), 'click', Settings["import"]);
|
||||||
@ -13180,20 +13193,9 @@
|
|||||||
boardID: g.BOARD.ID,
|
boardID: g.BOARD.ID,
|
||||||
filename: pathname[pathname.length - 1]
|
filename: pathname[pathname.length - 1]
|
||||||
});
|
});
|
||||||
if (URL) {
|
return Redirect.navigate(URL);
|
||||||
return location.replace(URL);
|
|
||||||
}
|
|
||||||
} else if (Conf['Loop in New Tab'] && (video = $('video'))) {
|
} else if (Conf['Loop in New Tab'] && (video = $('video'))) {
|
||||||
Video.configure(video);
|
return video.loop = true;
|
||||||
return $.on(video, 'click', function() {
|
|
||||||
if (!video.controls) {
|
|
||||||
if (video.paused) {
|
|
||||||
return video.play();
|
|
||||||
} else {
|
|
||||||
return video.pause();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
@ -13272,7 +13274,7 @@
|
|||||||
threadID: g.THREADID,
|
threadID: g.THREADID,
|
||||||
postID: +location.hash.match(/\d+/)
|
postID: +location.hash.match(/\d+/)
|
||||||
});
|
});
|
||||||
location.replace(href || ("/" + g.BOARD + "/"));
|
Redirect.navigate(href, "/" + g.BOARD + "/");
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -13357,7 +13359,7 @@
|
|||||||
}
|
}
|
||||||
if (previousversion) {
|
if (previousversion) {
|
||||||
el = $.el('span', {
|
el = $.el('span', {
|
||||||
innerHTML: '4chan X has been updated to <a href="https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md" target="_blank">version 1.8.5.3</a>.'
|
innerHTML: '4chan X has been updated to <a href="https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md" target="_blank">version 1.8.6</a>.'
|
||||||
});
|
});
|
||||||
new Notice('info', el, 15);
|
new Notice('info', el, 15);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Binary file not shown.
@ -1,6 +1,6 @@
|
|||||||
// ==UserScript==
|
// ==UserScript==
|
||||||
// @name 4chan X
|
// @name 4chan X
|
||||||
// @version 1.8.5.3
|
// @version 1.8.6
|
||||||
// @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.8.5.3
|
// @version 1.8.6
|
||||||
// @minGMVer 1.14
|
// @minGMVer 1.14
|
||||||
// @minFFVer 26
|
// @minFFVer 26
|
||||||
// @namespace 4chan-X
|
// @namespace 4chan-X
|
||||||
@ -24,7 +24,7 @@
|
|||||||
// ==/UserScript==
|
// ==/UserScript==
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* 4chan X - Version 1.8.5.3 - 2014-07-13
|
* 4chan X - Version 1.8.6 - 2014-07-13
|
||||||
*
|
*
|
||||||
* Licensed under the MIT license.
|
* Licensed under the MIT license.
|
||||||
* https://github.com/ccd0/4chan-x/blob/master/LICENSE
|
* https://github.com/ccd0/4chan-x/blob/master/LICENSE
|
||||||
@ -187,7 +187,7 @@
|
|||||||
'Werk Tyme': [false, 'Hide all post images.'],
|
'Werk Tyme': [false, 'Hide all post images.'],
|
||||||
'Autoplay': [true, 'Videos begin playing immediately when opened.'],
|
'Autoplay': [true, 'Videos begin playing immediately when opened.'],
|
||||||
'Show Controls': [true, 'Show controls on videos expanded inline. Turn this off if you want to contract videos by clicking on them.'],
|
'Show Controls': [true, 'Show controls on videos expanded inline. Turn this off if you want to contract videos by clicking on them.'],
|
||||||
'Loop in New Tab': [true, 'Loop videos opened in their own tabs, and apply settings for inline expanded videos to them.']
|
'Loop in New Tab': [true, 'Loop videos opened in their own tabs.']
|
||||||
},
|
},
|
||||||
'Menu': {
|
'Menu': {
|
||||||
'Menu': [true, 'Add a drop-down menu to posts.'],
|
'Menu': [true, 'Add a drop-down menu to posts.'],
|
||||||
@ -376,7 +376,7 @@
|
|||||||
doc = d.documentElement;
|
doc = d.documentElement;
|
||||||
|
|
||||||
g = {
|
g = {
|
||||||
VERSION: '1.8.5.3',
|
VERSION: '1.8.6',
|
||||||
NAMESPACE: '4chan X.',
|
NAMESPACE: '4chan X.',
|
||||||
boards: {}
|
boards: {}
|
||||||
};
|
};
|
||||||
@ -7782,6 +7782,8 @@
|
|||||||
});
|
});
|
||||||
if (URL) {
|
if (URL) {
|
||||||
thumb.href = URL;
|
thumb.href = URL;
|
||||||
|
}
|
||||||
|
if (URL && (/^https:\/\//.test(URL) || location.protocol === 'http:')) {
|
||||||
if (Gallery.nodes.current !== file) {
|
if (Gallery.nodes.current !== file) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -8242,7 +8244,7 @@
|
|||||||
boardID: src[3],
|
boardID: src[3],
|
||||||
filename: src[src.length - 1]
|
filename: src[src.length - 1]
|
||||||
});
|
});
|
||||||
if (URL) {
|
if (URL && (/^https:\/\//.test(URL) || location.protocol === 'http:')) {
|
||||||
setTimeout(ImageExpand.expand, 10000, post, URL);
|
setTimeout(ImageExpand.expand, 10000, post, URL);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -8400,7 +8402,7 @@
|
|||||||
boardID: src[3],
|
boardID: src[3],
|
||||||
filename: src[src.length - 1].replace(/\?.+$/, '')
|
filename: src[src.length - 1].replace(/\?.+$/, '')
|
||||||
});
|
});
|
||||||
if (URL) {
|
if (URL && (/^https:\/\//.test(URL) || location.protocol === 'http:')) {
|
||||||
this.src = URL;
|
this.src = URL;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -10903,9 +10905,13 @@
|
|||||||
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
||||||
},
|
},
|
||||||
post: function(archive, _arg) {
|
post: function(archive, _arg) {
|
||||||
var URL, boardID, postID;
|
var URL, boardID, postID, protocol;
|
||||||
boardID = _arg.boardID, postID = _arg.postID;
|
boardID = _arg.boardID, postID = _arg.postID;
|
||||||
URL = new String("" + (Redirect.protocol(archive)) + archive.domain + "/_/api/chan/post/?board=" + boardID + "&num=" + postID);
|
protocol = Redirect.protocol(archive);
|
||||||
|
if (!(protocol === 'https://' || location.protocol === 'http:')) {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
|
URL = new String("" + protocol + archive.domain + "/_/api/chan/post/?board=" + boardID + "&num=" + postID);
|
||||||
URL.archive = archive;
|
URL.archive = archive;
|
||||||
return URL;
|
return URL;
|
||||||
},
|
},
|
||||||
@ -10921,6 +10927,13 @@
|
|||||||
value = encodeURIComponent(value);
|
value = encodeURIComponent(value);
|
||||||
path = archive.software === 'foolfuuka' ? "" + boardID + "/search/" + type + "/" + value : "" + boardID + "/?task=search2&search_" + (type === 'image' ? 'media_hash' : type) + "=" + value;
|
path = archive.software === 'foolfuuka' ? "" + boardID + "/search/" + type + "/" + value : "" + boardID + "/?task=search2&search_" + (type === 'image' ? 'media_hash' : type) + "=" + value;
|
||||||
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
return "" + (Redirect.protocol(archive)) + archive.domain + "/" + path;
|
||||||
|
},
|
||||||
|
navigate: function(URL, alternative) {
|
||||||
|
if (/^https:\/\//.test(URL) || location.protocol === 'http:' || confirm("Redirect to " + URL + "?\n\nYour connection will not be encrypted.")) {
|
||||||
|
return location.replace(URL);
|
||||||
|
} else if (alternative) {
|
||||||
|
return location.replace(alternative);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -12506,7 +12519,7 @@
|
|||||||
Settings.dialog = dialog = $.el('div', {
|
Settings.dialog = dialog = $.el('div', {
|
||||||
id: 'fourchanx-settings',
|
id: 'fourchanx-settings',
|
||||||
className: 'dialog',
|
className: 'dialog',
|
||||||
innerHTML: '<nav><div class=sections-list></div><p class=\'imp-exp-result warning\'></p><div class=credits><a class=export>Export</a> | <a class=import>Import</a> | <a class=reset>Reset Settings</a> | <input type=file hidden><a href=\'https://github.com/ccd0/4chan-x\' target=_blank>4chan X</a> | <a href=\'https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md\' target=_blank>1.8.5.3</a> | <a href=\'https://github.com/ccd0/4chan-x/issues\' target=_blank>Issues</a> | <a href=javascript:; class=\'close fa fa-times\' title=Close></a></div></nav><div class=section-container><section></section></div>'
|
innerHTML: '<nav><div class=sections-list></div><p class=\'imp-exp-result warning\'></p><div class=credits><a class=export>Export</a> | <a class=import>Import</a> | <a class=reset>Reset Settings</a> | <input type=file hidden><a href=\'https://github.com/ccd0/4chan-x\' target=_blank>4chan X</a> | <a href=\'https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md\' target=_blank>1.8.6</a> | <a href=\'https://github.com/ccd0/4chan-x/issues\' target=_blank>Issues</a> | <a href=javascript:; class=\'close fa fa-times\' title=Close></a></div></nav><div class=section-container><section></section></div>'
|
||||||
});
|
});
|
||||||
$.on($('.export', Settings.dialog), 'click', Settings["export"]);
|
$.on($('.export', Settings.dialog), 'click', Settings["export"]);
|
||||||
$.on($('.import', Settings.dialog), 'click', Settings["import"]);
|
$.on($('.import', Settings.dialog), 'click', Settings["import"]);
|
||||||
@ -13181,20 +13194,9 @@
|
|||||||
boardID: g.BOARD.ID,
|
boardID: g.BOARD.ID,
|
||||||
filename: pathname[pathname.length - 1]
|
filename: pathname[pathname.length - 1]
|
||||||
});
|
});
|
||||||
if (URL) {
|
return Redirect.navigate(URL);
|
||||||
return location.replace(URL);
|
|
||||||
}
|
|
||||||
} else if (Conf['Loop in New Tab'] && (video = $('video'))) {
|
} else if (Conf['Loop in New Tab'] && (video = $('video'))) {
|
||||||
Video.configure(video);
|
return video.loop = true;
|
||||||
return $.on(video, 'click', function() {
|
|
||||||
if (!video.controls) {
|
|
||||||
if (video.paused) {
|
|
||||||
return video.play();
|
|
||||||
} else {
|
|
||||||
return video.pause();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
@ -13273,7 +13275,7 @@
|
|||||||
threadID: g.THREADID,
|
threadID: g.THREADID,
|
||||||
postID: +location.hash.match(/\d+/)
|
postID: +location.hash.match(/\d+/)
|
||||||
});
|
});
|
||||||
location.replace(href || ("/" + g.BOARD + "/"));
|
Redirect.navigate(href, "/" + g.BOARD + "/");
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -13358,7 +13360,7 @@
|
|||||||
}
|
}
|
||||||
if (previousversion) {
|
if (previousversion) {
|
||||||
el = $.el('span', {
|
el = $.el('span', {
|
||||||
innerHTML: '4chan X has been updated to <a href="https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md" target="_blank">version 1.8.5.3</a>.'
|
innerHTML: '4chan X has been updated to <a href="https://github.com/ccd0/4chan-x/blob/master/CHANGELOG.md" target="_blank">version 1.8.6</a>.'
|
||||||
});
|
});
|
||||||
new Notice('info', el, 15);
|
new Notice('info', el, 15);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
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.8.5.3' />
|
<updatecheck codebase='https://ccd0.github.io/4chan-x/builds/4chan-X-beta.crx' version='1.8.6' />
|
||||||
</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.8.5.3' />
|
<updatecheck codebase='https://ccd0.github.io/4chan-x/builds/4chan-X.crx' version='1.8.6' />
|
||||||
</app>
|
</app>
|
||||||
</gupdate>
|
</gupdate>
|
||||||
|
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "4chan-X",
|
"name": "4chan-X",
|
||||||
"version": "1.8.5.3",
|
"version": "1.8.6",
|
||||||
"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",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user