diff --git a/CHANGELOG.md b/CHANGELOG.md index a9a8bca05..88ee1ba16 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ The links to individual versions below are to copies of the script with the upda ### v1.11.2 +**v1.11.2.3** *(2015-06-30)* - [[Firefox](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.2.3/builds/4chan-X-noupdate.user.js "Firefox version")] [[Chromium](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.2.3/builds/4chan-X-noupdate.crx "Chromium version")] +- Add 'webkit' CSS class to document when WebKit engine is detected. +- Various CSS-related bugfixes. + **v1.11.2.2** *(2015-06-30)* - [[Firefox](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.2.2/builds/4chan-X-noupdate.user.js "Firefox version")] [[Chromium](https://raw.githubusercontent.com/ccd0/4chan-x/1.11.2.2/builds/4chan-X-noupdate.crx "Chromium version")] - Fix bug from v1.11.2.0 that broke `Use Recaptcha v1` when the original post form was hidden. diff --git a/builds/4chan-X-beta.crx b/builds/4chan-X-beta.crx index a7a66f420..4f9772264 100644 Binary files a/builds/4chan-X-beta.crx and b/builds/4chan-X-beta.crx differ diff --git a/builds/4chan-X-beta.meta.js b/builds/4chan-X-beta.meta.js index b4bd8c167..8cb44267d 100644 --- a/builds/4chan-X-beta.meta.js +++ b/builds/4chan-X-beta.meta.js @@ -1,6 +1,6 @@ // ==UserScript== // @name 4chan X beta -// @version 1.11.2.2 +// @version 1.11.2.3 // @minGMVer 1.14 // @minFFVer 26 // @namespace 4chan-X diff --git a/builds/4chan-X-beta.user.js b/builds/4chan-X-beta.user.js index d9ff652c8..b79a50b8b 100644 --- a/builds/4chan-X-beta.user.js +++ b/builds/4chan-X-beta.user.js @@ -1,7 +1,7 @@ // Generated by CoffeeScript // ==UserScript== // @name 4chan X beta -// @version 1.11.2.2 +// @version 1.11.2.3 // @minGMVer 1.14 // @minFFVer 26 // @namespace 4chan-X @@ -411,7 +411,7 @@ doc = d.documentElement; g = { - VERSION: '1.11.2.2', + VERSION: '1.11.2.3', NAMESPACE: '4chan X.', boards: {} }; @@ -871,6 +871,18 @@ return video.mozHasAudio || !!video.webkitAudioDecodedByteCount; }; + $.engine = (function() { + if (/Chrome\//.test(navigator.userAgent)) { + return 'blink'; + } + if (/WebKit\//.test(navigator.userAgent)) { + return 'webkit'; + } + if (/Gecko\/|Goanna/.test(navigator.userAgent)) { + return 'gecko'; + } + })(); + $.item = function(key, val) { var item; item = {}; @@ -10573,7 +10585,7 @@ } if (file.scrollIntoView) { delete file.scrollIntoView; - imageBottom = Header.getBottomOf(file.fullImage) - 25; + imageBottom = Header.getBottomOf(file.fullImage); if (imageBottom < 0) { window.scrollBy(0, Math.min(-imageBottom, Header.getTopOf(file.fullImage))); } @@ -10782,7 +10794,7 @@ return results; })(), width = ref1[0], height = ref1[1]; ref2 = this.getBoundingClientRect(), left = ref2.left, right = ref2.right; - padding = 16; + padding = 25; maxWidth = Math.max(left, doc.clientWidth - right); maxHeight = doc.clientHeight - padding; scale = Math.min(1, maxWidth / width, maxHeight / height); @@ -17039,7 +17051,9 @@ } $.addClass(doc, 'fourchan-x', 'seaweedchan'); $.addClass(doc, g.VIEW === 'thread' ? 'thread-view' : g.VIEW); - $.addClass(doc, typeof chrome !== "undefined" && chrome !== null ? 'blink' : 'gecko'); + if ($.engine) { + $.addClass(doc, $.engine); + } $.addStyle(Main.css, 'fourchanx-css'); keyboard = false; $.on(d, 'mousedown', function() { @@ -18105,7 +18119,7 @@ " height: 10px;\n" + " position: absolute;\n" + "}\n" + -":root:not(.autohide) #scroll-marker {\n" + +"#header-bar:not(.autohide) #scroll-marker {\n" + " pointer-events: none;\n" + "}\n" + "#header-bar #scroll-marker {\n" + @@ -18485,6 +18499,10 @@ " left: -1em;\n" + " width: 0;\n" + "}\n" + +"/* \`\`::-webkit-*'' selectors break selector lists on Firefox. */\n" + +"#index-search::-webkit-search-cancel-button {\n" + +" display: none;\n" + +"}\n" + "#index-search:not([data-searching]) + #index-search-clear {\n" + " display: none;\n" + "}\n" + @@ -18828,6 +18846,9 @@ ":root.fit-height .full-image {\n" + " max-height: 100vh;\n" + "}\n" + +":root.fit-height.fixed .full-image {\n" + +" max-height: calc(100vh - 25px);\n" + +"}\n" + ":root.fit-width .full-image {\n" + " max-width: 100%;\n" + "}\n" + diff --git a/builds/4chan-X-noupdate.crx b/builds/4chan-X-noupdate.crx index b0379d1b0..7c4a283c7 100644 Binary files a/builds/4chan-X-noupdate.crx and b/builds/4chan-X-noupdate.crx differ diff --git a/builds/4chan-X-noupdate.user.js b/builds/4chan-X-noupdate.user.js index 2e21be2f7..bbd3c6792 100644 --- a/builds/4chan-X-noupdate.user.js +++ b/builds/4chan-X-noupdate.user.js @@ -1,7 +1,7 @@ // Generated by CoffeeScript // ==UserScript== // @name 4chan X -// @version 1.11.2.2 +// @version 1.11.2.3 // @minGMVer 1.14 // @minFFVer 26 // @namespace 4chan-X @@ -410,7 +410,7 @@ doc = d.documentElement; g = { - VERSION: '1.11.2.2', + VERSION: '1.11.2.3', NAMESPACE: '4chan X.', boards: {} }; @@ -870,6 +870,18 @@ return video.mozHasAudio || !!video.webkitAudioDecodedByteCount; }; + $.engine = (function() { + if (/Chrome\//.test(navigator.userAgent)) { + return 'blink'; + } + if (/WebKit\//.test(navigator.userAgent)) { + return 'webkit'; + } + if (/Gecko\/|Goanna/.test(navigator.userAgent)) { + return 'gecko'; + } + })(); + $.item = function(key, val) { var item; item = {}; @@ -10572,7 +10584,7 @@ } if (file.scrollIntoView) { delete file.scrollIntoView; - imageBottom = Header.getBottomOf(file.fullImage) - 25; + imageBottom = Header.getBottomOf(file.fullImage); if (imageBottom < 0) { window.scrollBy(0, Math.min(-imageBottom, Header.getTopOf(file.fullImage))); } @@ -10781,7 +10793,7 @@ return results; })(), width = ref1[0], height = ref1[1]; ref2 = this.getBoundingClientRect(), left = ref2.left, right = ref2.right; - padding = 16; + padding = 25; maxWidth = Math.max(left, doc.clientWidth - right); maxHeight = doc.clientHeight - padding; scale = Math.min(1, maxWidth / width, maxHeight / height); @@ -17038,7 +17050,9 @@ } $.addClass(doc, 'fourchan-x', 'seaweedchan'); $.addClass(doc, g.VIEW === 'thread' ? 'thread-view' : g.VIEW); - $.addClass(doc, typeof chrome !== "undefined" && chrome !== null ? 'blink' : 'gecko'); + if ($.engine) { + $.addClass(doc, $.engine); + } $.addStyle(Main.css, 'fourchanx-css'); keyboard = false; $.on(d, 'mousedown', function() { @@ -18104,7 +18118,7 @@ " height: 10px;\n" + " position: absolute;\n" + "}\n" + -":root:not(.autohide) #scroll-marker {\n" + +"#header-bar:not(.autohide) #scroll-marker {\n" + " pointer-events: none;\n" + "}\n" + "#header-bar #scroll-marker {\n" + @@ -18484,6 +18498,10 @@ " left: -1em;\n" + " width: 0;\n" + "}\n" + +"/* \`\`::-webkit-*'' selectors break selector lists on Firefox. */\n" + +"#index-search::-webkit-search-cancel-button {\n" + +" display: none;\n" + +"}\n" + "#index-search:not([data-searching]) + #index-search-clear {\n" + " display: none;\n" + "}\n" + @@ -18827,6 +18845,9 @@ ":root.fit-height .full-image {\n" + " max-height: 100vh;\n" + "}\n" + +":root.fit-height.fixed .full-image {\n" + +" max-height: calc(100vh - 25px);\n" + +"}\n" + ":root.fit-width .full-image {\n" + " max-width: 100%;\n" + "}\n" + diff --git a/builds/4chan-X.crx b/builds/4chan-X.crx index ea6e13d75..c670331fe 100644 Binary files a/builds/4chan-X.crx and b/builds/4chan-X.crx differ diff --git a/builds/4chan-X.meta.js b/builds/4chan-X.meta.js index 29cca0b7b..a9fc8967f 100644 --- a/builds/4chan-X.meta.js +++ b/builds/4chan-X.meta.js @@ -1,6 +1,6 @@ // ==UserScript== // @name 4chan X -// @version 1.11.2.2 +// @version 1.11.2.3 // @minGMVer 1.14 // @minFFVer 26 // @namespace 4chan-X diff --git a/builds/4chan-X.user.js b/builds/4chan-X.user.js index 7491b15af..09cd2f31d 100644 --- a/builds/4chan-X.user.js +++ b/builds/4chan-X.user.js @@ -1,7 +1,7 @@ // Generated by CoffeeScript // ==UserScript== // @name 4chan X -// @version 1.11.2.2 +// @version 1.11.2.3 // @minGMVer 1.14 // @minFFVer 26 // @namespace 4chan-X @@ -411,7 +411,7 @@ doc = d.documentElement; g = { - VERSION: '1.11.2.2', + VERSION: '1.11.2.3', NAMESPACE: '4chan X.', boards: {} }; @@ -871,6 +871,18 @@ return video.mozHasAudio || !!video.webkitAudioDecodedByteCount; }; + $.engine = (function() { + if (/Chrome\//.test(navigator.userAgent)) { + return 'blink'; + } + if (/WebKit\//.test(navigator.userAgent)) { + return 'webkit'; + } + if (/Gecko\/|Goanna/.test(navigator.userAgent)) { + return 'gecko'; + } + })(); + $.item = function(key, val) { var item; item = {}; @@ -10573,7 +10585,7 @@ } if (file.scrollIntoView) { delete file.scrollIntoView; - imageBottom = Header.getBottomOf(file.fullImage) - 25; + imageBottom = Header.getBottomOf(file.fullImage); if (imageBottom < 0) { window.scrollBy(0, Math.min(-imageBottom, Header.getTopOf(file.fullImage))); } @@ -10782,7 +10794,7 @@ return results; })(), width = ref1[0], height = ref1[1]; ref2 = this.getBoundingClientRect(), left = ref2.left, right = ref2.right; - padding = 16; + padding = 25; maxWidth = Math.max(left, doc.clientWidth - right); maxHeight = doc.clientHeight - padding; scale = Math.min(1, maxWidth / width, maxHeight / height); @@ -17039,7 +17051,9 @@ } $.addClass(doc, 'fourchan-x', 'seaweedchan'); $.addClass(doc, g.VIEW === 'thread' ? 'thread-view' : g.VIEW); - $.addClass(doc, typeof chrome !== "undefined" && chrome !== null ? 'blink' : 'gecko'); + if ($.engine) { + $.addClass(doc, $.engine); + } $.addStyle(Main.css, 'fourchanx-css'); keyboard = false; $.on(d, 'mousedown', function() { @@ -18105,7 +18119,7 @@ " height: 10px;\n" + " position: absolute;\n" + "}\n" + -":root:not(.autohide) #scroll-marker {\n" + +"#header-bar:not(.autohide) #scroll-marker {\n" + " pointer-events: none;\n" + "}\n" + "#header-bar #scroll-marker {\n" + @@ -18485,6 +18499,10 @@ " left: -1em;\n" + " width: 0;\n" + "}\n" + +"/* \`\`::-webkit-*'' selectors break selector lists on Firefox. */\n" + +"#index-search::-webkit-search-cancel-button {\n" + +" display: none;\n" + +"}\n" + "#index-search:not([data-searching]) + #index-search-clear {\n" + " display: none;\n" + "}\n" + @@ -18828,6 +18846,9 @@ ":root.fit-height .full-image {\n" + " max-height: 100vh;\n" + "}\n" + +":root.fit-height.fixed .full-image {\n" + +" max-height: calc(100vh - 25px);\n" + +"}\n" + ":root.fit-width .full-image {\n" + " max-width: 100%;\n" + "}\n" + diff --git a/builds/4chan-X.zip b/builds/4chan-X.zip index 0e9c6a548..db6beab50 100644 Binary files a/builds/4chan-X.zip and b/builds/4chan-X.zip differ diff --git a/builds/updates-beta.xml b/builds/updates-beta.xml index b51430ef3..416db1911 100644 --- a/builds/updates-beta.xml +++ b/builds/updates-beta.xml @@ -1,7 +1,7 @@ - + diff --git a/builds/updates.xml b/builds/updates.xml index a691e688b..6a6ded0d5 100644 --- a/builds/updates.xml +++ b/builds/updates.xml @@ -1,7 +1,7 @@ - + diff --git a/package.json b/package.json index 39f97b23a..0de1623a2 100755 --- a/package.json +++ b/package.json @@ -3,8 +3,8 @@ "description": "Cross-browser userscript for maximum lurking on 4chan.", "meta": { "name": "4chan X", - "version": "1.11.2.2", - "date": "2015-06-30T15:52:28.530Z", + "version": "1.11.2.3", + "date": "2015-07-01T06:15:34.618Z", "repo": "https://github.com/ccd0/4chan-x/", "page": "https://github.com/ccd0/4chan-x", "downloads": "https://ccd0.github.io/4chan-x/builds/",