Fix image expansion
This commit is contained in:
parent
db1c2b76b3
commit
0cc1c97868
@ -20,7 +20,7 @@
|
|||||||
// @icon data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAACVBMVEUAAGcAAABmzDNZt9VtAAAAAXRSTlMAQObYZgAAAHFJREFUKFOt0LENACEIBdBv4Qju4wgWanEj3D6OcIVMKaitYHEU/jwTCQj8W75kiVCSBvdQ5/AvfVHBin11BgdRq3ysBgfwBDRrj3MCIA+oAQaku/Q1cNctrAmyDl577tOThYt/Y1RBM4DgOHzM0HFTAyLukH/cmRnqAAAAAElFTkSuQmCC
|
// @icon data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAACVBMVEUAAGcAAABmzDNZt9VtAAAAAXRSTlMAQObYZgAAAHFJREFUKFOt0LENACEIBdBv4Qju4wgWanEj3D6OcIVMKaitYHEU/jwTCQj8W75kiVCSBvdQ5/AvfVHBin11BgdRq3ysBgfwBDRrj3MCIA+oAQaku/Q1cNctrAmyDl577tOThYt/Y1RBM4DgOHzM0HFTAyLukH/cmRnqAAAAAElFTkSuQmCC
|
||||||
// ==/UserScript==
|
// ==/UserScript==
|
||||||
|
|
||||||
/* 4chan X Beta - Version 3.0.0 - 2013-03-28
|
/* 4chan X Beta - Version 3.0.0 - 2013-03-31
|
||||||
* https://4chan-x.just-believe.in/
|
* https://4chan-x.just-believe.in/
|
||||||
*
|
*
|
||||||
* Copyright (c) 2009-2011 James Campos <james.r.campos@gmail.com>
|
* Copyright (c) 2009-2011 James Campos <james.r.campos@gmail.com>
|
||||||
@ -4951,7 +4951,7 @@
|
|||||||
rect = thumb.parentNode.getBoundingClientRect();
|
rect = thumb.parentNode.getBoundingClientRect();
|
||||||
if (rect.bottom > 0) {
|
if (rect.bottom > 0) {
|
||||||
postRect = post.nodes.root.getBoundingClientRect();
|
postRect = post.nodes.root.getBoundingClientRect();
|
||||||
headRect = Header.toggle.getBoundingClientRect();
|
headRect = Header.bar.getBoundingClientRect();
|
||||||
top = postRect.top - headRect.top - headRect.height - 2;
|
top = postRect.top - headRect.top - headRect.height - 2;
|
||||||
root = $.engine === 'webkit' ? d.body : doc;
|
root = $.engine === 'webkit' ? d.body : doc;
|
||||||
if (rect.top < 0) {
|
if (rect.top < 0) {
|
||||||
|
|||||||
@ -3197,7 +3197,7 @@ ImageExpand =
|
|||||||
# Scroll back to the thumbnail when contracting the image
|
# Scroll back to the thumbnail when contracting the image
|
||||||
# to avoid being left miles away from the relevant post.
|
# to avoid being left miles away from the relevant post.
|
||||||
postRect = post.nodes.root.getBoundingClientRect()
|
postRect = post.nodes.root.getBoundingClientRect()
|
||||||
headRect = Header.toggle.getBoundingClientRect()
|
headRect = Header.bar.getBoundingClientRect()
|
||||||
top = postRect.top - headRect.top - headRect.height - 2
|
top = postRect.top - headRect.top - headRect.height - 2
|
||||||
root = if $.engine is 'webkit'
|
root = if $.engine is 'webkit'
|
||||||
d.body
|
d.body
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user