bookmarks popup fix #136

This commit is contained in:
overdodactyl 2018-11-30 18:26:31 -07:00
parent d1f6a1f851
commit 3741d4a805
9 changed files with 38 additions and 68 deletions

View File

@ -70,7 +70,22 @@ url(chrome://browser/content/places/bookmarkProperties2.xul) {
#bookmarkproperties {
-moz-appearance: none!important;
color: var(--in-content-page-color)!important;
background-color: var(--in-content-box-background)!important
background-color: var(--in-content-category-header-background)!important
}
textbox {
-moz-appearance: none!important;
min-height: 20px!important;
padding: 2px!important;
border: 1px solid var(--in-content-box-border-color);
color: var(--in-content-page-color)!important;
background: var(--in-content-box-background)!important
}
#editBMPanel_folderTree {
background: var(--in-content-box-background)!important
}
#editBMPanel_folderMenuList {
background-color: var(--in-content-box-background)!important;
padding: 2px!important
}
#editBMPanel_foldersExpander.expander-down,
#editBMPanel_tagsSelectorExpander.expander-down {
@ -99,4 +114,7 @@ url(chrome://browser/content/places/bookmarkProperties2.xul) {
border-radius: 3px;
border-color: var(--in-content-box-border-color)!important
}
#editBMPanel_newFolderBox {
background: 0 0!important
}
}

Binary file not shown.

View File

@ -692,7 +692,22 @@ url(chrome://browser/content/places/bookmarkProperties2.xul) {
#bookmarkproperties {
-moz-appearance: none!important;
color: var(--in-content-page-color)!important;
background-color: var(--in-content-box-background)!important
background-color: var(--in-content-category-header-background)!important
}
textbox {
-moz-appearance: none!important;
min-height: 20px!important;
padding: 2px!important;
border: 1px solid var(--in-content-box-border-color);
color: var(--in-content-page-color)!important;
background: var(--in-content-box-background)!important
}
#editBMPanel_folderTree {
background: var(--in-content-box-background)!important
}
#editBMPanel_folderMenuList {
background-color: var(--in-content-box-background)!important;
padding: 2px!important
}
#editBMPanel_foldersExpander.expander-down,
#editBMPanel_tagsSelectorExpander.expander-down {
@ -721,6 +736,9 @@ url(chrome://browser/content/places/bookmarkProperties2.xul) {
border-radius: 3px;
border-color: var(--in-content-box-border-color)!important
}
#editBMPanel_newFolderBox {
background: 0 0!important
}
}
@-moz-document url("chrome://global/content/commonDialog.xul") {
#commonDialog {

View File

@ -1,24 +0,0 @@
# No Empty iframes
## What it does
No Empty iframes adds a blank `div` to any iframes that have an empty `body`.
## That sounds useless...what's the point?
[ShadowFox](https://github.com/overdodactyl/ShadowFox) utilizes `userContent.css` and `userChrome.css` to create a universal dark theme for Firefox. In part, this means styling `about:blank`. A complication of this is that `about:blank` is also used for anonymous frames on webpages. Generally, iframes will contain content, making the following css rule specific enough:
```css
html > body:empty {
background-color: var(--in-content-page-background)!important;
margin: 0!important
}
```
Some pages, however, have empty iframes that cause readability issues (see [#222](https://github.com/overdodactyl/ShadowFox/issues/222)).
This extension injects an empty div into such iframes, allowing the rule above to work.
## Better approaches?
If anyone has a better approach/workaround for this problem, I would appreciate any suggestions.

View File

@ -1,17 +0,0 @@
{
"description": "Add an empty div to the body of any empty iframes. Supplemental addon to ShadowFox.",
"manifest_version": 2,
"name": "No Empty iframes",
"version": "1.0",
"homepage_url": "https://github.com/overdodactyl/ShadowFox/no_empty_iframes",
"content_scripts": [
{
"matches": ["<all_urls>"],
"js": ["no_empty_iframes.js"],
"run_at": "document_end"
}
]
}

View File

@ -1,12 +0,0 @@
/* Once page finishes loading, find all empty iframes
* and add empty div inside */
window.onload = function() {
var frames = document.getElementsByTagName("iframe");
for (var i = 0; i < frames.length; i++) {
var doc = frames[i].contentWindow.document;
if (doc.body.innerHTML === "") {
var elemDiv = document.createElement('div');
doc.body.appendChild(elemDiv);
}
}
}

View File

@ -1,13 +0,0 @@
<h1 id="no-empty-iframes">No Empty iframes</h1>
<h2 id="what-it-does">What it does</h2>
<p>No Empty iframes adds a blank <code>div</code> to any iframes that have an empty <code>body</code>.</p>
<h2 id="that-sounds-uselesswhats-the-point">That sounds useless…whats the point?</h2>
<p><a href="https://github.com/overdodactyl/ShadowFox">ShadowFox</a> utilizes <code>userContent.css</code> and <code>userChrome.css</code> to create a universal dark theme for Firefox. In part, this means styling <code>about:blank</code>. A complication of this is that <code>about:blank</code> is also used for anonymous frames on webpages. Generally, iframes will contain content, making the following css rule specific enough:</p>
<div class="sourceCode" id="cb1"><pre class="sourceCode css"><code class="sourceCode css"><a class="sourceLine" id="cb1-1" data-line-number="1">html &gt; body<span class="in">:empty</span> {</a>
<a class="sourceLine" id="cb1-2" data-line-number="2"> <span class="kw">background-color</span>: var(--in-content-page-background)<span class="at">!important</span>;</a>
<a class="sourceLine" id="cb1-3" data-line-number="3"> <span class="kw">margin</span>: <span class="dv">0</span><span class="at">!important</span></a>
<a class="sourceLine" id="cb1-4" data-line-number="4">}</a></code></pre></div>
<p>Some pages, however, have empty iframes that cause readability issues (see <a href="https://github.com/overdodactyl/ShadowFox/issues/222">#222</a>).</p>
<p>This extension injects an empty div into such iframes, allowing the rule above to work.</p>
<h2 id="better-approaches">Better approaches?</h2>
<p>If anyone has a better approach/workaround for this problem, I would appreciate any suggestions.</p>