diff options
| author | mrmr1993 | 2017-09-29 19:01:39 +0100 |
|---|---|---|
| committer | mrmr1993 | 2017-09-29 19:01:39 +0100 |
| commit | 7f45a5e40128aadf02fe598310d40fca850a8e1f (patch) | |
| tree | c7eb422b30f3fc8d381246f9b02cc2ad0eea0701 /lib | |
| parent | 50615a6f3ebb80cedf1807497a6cd73d12950cdb (diff) | |
| download | vimium-7f45a5e40128aadf02fe598310d40fca850a8e1f.tar.bz2 | |
Manually inject custom user CSS into our own frames/pages
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/dom_utils.coffee | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/dom_utils.coffee b/lib/dom_utils.coffee index 65a14c34..32d402df 100644 --- a/lib/dom_utils.coffee +++ b/lib/dom_utils.coffee @@ -407,5 +407,13 @@ DomUtils = windowIsTooSmall: -> return window.innerWidth < 3 or window.innerHeight < 3 + # Inject user styles manually. This is only necessary for our chrome-extension:// pages and frames. + injectUserCss: -> + Settings.onLoaded -> + style = document.createElement "style" + style.type = "text/css" + style.textContent = Settings.get "userDefinedLinkHintCss" + document.head.appendChild style + root = exports ? window root.DomUtils = DomUtils |
