mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-23 13:32:27 +01:00
Insert the chrome stylesheet before the last element in the document, rather than the first.
This commit is contained in:
@@ -212,7 +212,7 @@ liberator.Buffer = function () //{{{
|
|||||||
let styles = liberator.storage.newObject("styles", Styles, false);
|
let styles = liberator.storage.newObject("styles", Styles, false);
|
||||||
|
|
||||||
let stylesheet = document.createProcessingInstruction("xml-stylesheet", "");
|
let stylesheet = document.createProcessingInstruction("xml-stylesheet", "");
|
||||||
document.insertBefore(stylesheet, document.firstChild);
|
document.insertBefore(stylesheet, document.childNodes[document.childNodes.length - 1]);
|
||||||
|
|
||||||
let chromeObserver = function () { stylesheet.data = 'type="text/css" href="' + styles.chromeCSS + '"' };
|
let chromeObserver = function () { stylesheet.data = 'type="text/css" href="' + styles.chromeCSS + '"' };
|
||||||
storage.addObserver("styles", chromeObserver);
|
storage.addObserver("styles", chromeObserver);
|
||||||
|
|||||||
Reference in New Issue
Block a user