搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

详细了解

How do I hide the icon of one bookmark in the bookmark toolbar in userChrome.css?

more options

I have one bookmark in the bookmark toolbar (the "Read Later" bookmarklet for Instapaper, not that that should matter) which does not have an icon, and I would like to hide the little dashed rounded-square placeholder for bookmarks which don't have an icon.

Right now, in my userChrome.css I have this:

@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); /*only needed once*/

  1. personal-bookmarks toolbarbutton.bookmark-item[label="Read Later"]

{ display: none; }

Unfortunately, it's not working. Any ideas?

I have one bookmark in the bookmark toolbar (the "Read Later" bookmarklet for Instapaper, not that that should matter) which does not have an icon, and I would like to hide the little dashed rounded-square placeholder for bookmarks which don't have an icon. Right now, in my userChrome.css I have this: @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); /*only needed once*/ #personal-bookmarks toolbarbutton.bookmark-item[label="Read Later"] { display: none; } Unfortunately, it's not working. Any ideas?

所有回复 (5)

more options

It should read `#personal-bookmarks toolbarbutton...`

more options

This should work to hide the icon for a specific bookmark.

@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); /* only needed once */

#personal-bookmarks .bookmark-item[label="Read Later"] .toolbarbutton-icon { display:none!important; }
more options

Unfortunately this does not do anything on my machine. Is there something I could do / put in my useChrome.css file to test that Firefox is reading my userChrome.css file at all?

Thank you cor-el.

more options

Did you restart? I think Firefox only reads that file at startup. For tinkering with style rules, you might find it easier to use the Stylish extension because its Preview button lets to see your results instantly. You don't have to keep it if you only are making this one rule, but remember to copy out your rule to userChrome.css before uninstalling.

more options

This is off topic, but...

When I looked at those bookmarks toolbar items (using the DOM Inspector's feature of inspecting a Chrome document) I realized I could get rid of the square outlines for all my bookmarklets. :-) I settled on blue bullets for them.

@namespace url(http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul);
#personal-bookmarks .bookmark-item[scheme="javascript"] .toolbarbutton-icon {
  width:6px !important;
  height:6px !important;
  background-color:#00f !important;
  border-radius:3px !important;
}