How to show only the "Bookmarks menu" content in the sidebar?
Hello, few years back several users asked for a way to get rid of the "Bookmarks Toolbar" and "Unsorted Bookmarks" folders in the bookmarks sidebar and-or show only "Bookmarks menu" content there. The tips given seems to be only applicable to Firefox prior to 57/Quantum. Here are two old threads related to this topic:
https://support.mozilla.org/en-US/questions/975746 http://forums.mozillazine.org/viewtopic.php?f=38&t=3035360
My question is how to make this possible on FF57, as none of the CSS codes I've found and put in Userchrome.css worked. The list of CSS codes I've tried are in the second URL.
I was given an advice to ask Cor-el for help but I don't know how since I see no option to send him PM.
Attached pictures show my custom Bookmarks sidebar in FF56 (with Bookmarks Menu on Sidebar Panel extension and some CSS code in userCHrome.css). The second picture shows what I was able to adjust and what I'm trying to accomplish.
My current Userchrome.css in FF57 looks like this:
@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
- sidebar { max-width: none !important; min-width: 12px !important; }
/* Bookmarks sidebar: hide "Search:" */
- bookmarksPanel > hbox { display: none !important }
/* Remove SIDEBAR HEADER and CLOSE X */ sidebarheader { display: none !important;}
- BMB_bookmarksPopup menuseparator:nth-of-type(-n+4),
- BMB_viewBookmarksSidebar,
- BMB_bookmarksShowAllTop,
- BMB_pocket,
- BMB_pocketSeparator,
- BMB_subscribeToPageMenuitem,
- BMB_subscribeToPageMenupopup,
- BMB_bookmarksToolbar,
- BMB_unsortedBookmarks
{ display: none !important; }
- BMB_bookmarksShowAll,
- BMB_viewBookmarksSidebar {
display: none !important; }
.sidebar-placesTree treechildren::-moz-tree-row {
height: 1.4em !important; border-width: 1px !important;
}
Krejt Përgjigjet (5)
Oh, the CSS code I posted above got messed up, so I made another picture showing the real userChrome.css contents.
This should be possible. By the way, you can use <pre> before and </pre> after CSS code you post to prevent the forum from misinterpreting it. (Doesn't always work for scripts, though.)
Note: IDs starting with BMB_ should all refer to the drop-down menu from the bookmarks menu button on the main toolbar. Those would not affect the sidebar.
I'll see if I can come up with something in a reasonable amount of time...
Hi, thank you for your reply. I know that some parts of my UserChrome.css are for drop-down menu, I just posted the whole thing just to make sure nothing is colliding with my primary goal (reducing the sidebar content).
This problem is much worse than I expected. There must be some way to target individual elements but the Inspector does not expose the necessary details and the documentation is very discouraging about selective modifications:
https://developer.mozilla.org/docs/Mozilla/Tech/XUL/Tutorial/Styling_a_Tree
At least you can slide the contents of the sidebar left to hide the top level "twisty" icons:
#bookmarks-view { margin-left: -16px !important; }
Well it might be the "better than nothing" type of solution but when I shift the whole content to the left with -28px value, none of the icons are clickable. I have to expand the sidebar and click the names, clicking the icons does nothing :( Maybe the value -28 is too high, but even -16 causes the same problem. Looks like there is nothing we can do.