diff --git a/chrome/global/tree.css b/chrome/global/tree.css new file mode 100644 index 0000000..2bbffb4 --- /dev/null +++ b/chrome/global/tree.css @@ -0,0 +1,87 @@ +/* Edge-Frfox - tree.css */ + +/* Change height of tree items and add rounded corners */ +treechildren::-moz-tree-row, +treecol:not([hideheader="true"]), +.tree-columnpicker-button { + min-height: max(28px, 1.3em) !important; + border-radius: 2px !important; +} + +/* Change the background colour on hover */ +@media not (prefers-contrast) { + treechildren::-moz-tree-row(hover) { + background-color: var(--toolbarbutton-hover-background) !important; + } +} + +/* Change the background colour when pressed */ +treechildren::-moz-tree-row(selected) { + background-color: var(--toolbarbutton-active-background) !important; +} + +/* Change the background colour when focused */ +treechildren::-moz-tree-row(selected, focus) { + background-color: var(--button-primary-bgcolor) !important; +} + +treechildren::-moz-tree-row(current, focus) { + outline: var(--default-focusring); + outline-color: var(--button-primary-bgcolor) !important; + outline-offset: calc(-1 * var(--default-focusring-width)); +} + +treechildren::-moz-tree-image(selected), +treechildren::-moz-tree-twisty(selected), +treechildren::-moz-tree-cell-text(selected) { + color: inherit !important; +} + +treechildren::-moz-tree-image(selected, focus), +treechildren::-moz-tree-twisty(selected, focus), +treechildren::-moz-tree-cell-text(selected, focus) { + color: var(--button-primary-color) !important; +} + +/* Spacing between icon and label */ +treechildren::-moz-tree-image { + margin-inline-end: 8px !important; +} + +/* Separator appearance */ +treechildren::-moz-tree-separator { + border-top: 1px solid var(--toolbarseparator-color) !important; + border-bottom: none !important; +} + +/* Change the colour of the drop feedback elements */ +treechildren::-moz-tree-cell-text(primary, dropOn) { + background-color: var(--button-primary-bgcolor) !important; + color: var(--button-primary-color) !important; +} + +treechildren::-moz-tree-drop-feedback { + background-color: var(--toolbarbutton-icon-fill-attention) !important; + border-radius: 2px !important; +} + +/* Change the appearance for the expandable items */ +treechildren::-moz-tree-twisty { + padding-top: 0 !important; + padding-inline: 4px !important; + width: 16px !important; + list-style-image: url("../icons/arrow-filled-right.svg") !important; +} + +treechildren:-moz-locale-dir(rtl)::-moz-tree-twisty(closed) { + list-style-image: url("../icons/arrow-filled-left.svg") !important; +} + +treechildren::-moz-tree-twisty(open) { + list-style-image: url("../icons/arrow-filled-down.svg") !important; +} + +/* Change the identation of child items */ +treechildren::-moz-tree-indentation { + width: 16px !important; +} diff --git a/chrome/icons/arrow-filled-down.svg b/chrome/icons/arrow-filled-down.svg new file mode 100644 index 0000000..bd111a7 --- /dev/null +++ b/chrome/icons/arrow-filled-down.svg @@ -0,0 +1,3 @@ + + + diff --git a/chrome/icons/arrow-filled-left.svg b/chrome/icons/arrow-filled-left.svg new file mode 100644 index 0000000..c0f6945 --- /dev/null +++ b/chrome/icons/arrow-filled-left.svg @@ -0,0 +1,3 @@ + + + diff --git a/chrome/icons/icons.css b/chrome/icons/icons.css index a6c20a7..e99d62c 100644 --- a/chrome/icons/icons.css +++ b/chrome/icons/icons.css @@ -944,3 +944,67 @@ and 11 so applied to both) */ --header-image: url("extension.svg"); --uc-enabled: 1; } + +/* Tree items used for side bar and library windows */ +treechildren::-moz-tree-image { + fill-opacity: 1 !important; +} + +treechildren::-moz-tree-image(title) { + list-style-image: url("page-portrait.svg") !important; +} + +/* default folder icon */ +treechildren::-moz-tree-image(title, container), +treechildren::-moz-tree-image(title, open) { + list-style-image: url("folder.svg") !important; +} + +/* bookmarks bar icon */ +treechildren::-moz-tree-image(container, queryFolder_toolbar_____) { + list-style-image: url("bookmark-hollow.svg") !important; +} + +/* bookmarks menu icon */ +treechildren::-moz-tree-image(container, queryFolder_menu________) { + list-style-image: url("folder.svg") !important; +} + +/* smart folder icon */ +treechildren::-moz-tree-image(query) { + list-style-image: url("settings.svg") !important; +} + +/* bookmarks category icon */ +treechildren::-moz-tree-image(query, OrganizerQuery_allbms_____v) { + list-style-image: url("bookmark-hollow.svg") !important; +} + +/* downloads category icon */ +treechildren::-moz-tree-image(query, OrganizerQuery_downloads__v) { + list-style-image: url("downloads.svg") !important; +} + +/* tags category icon */ +treechildren::-moz-tree-image(title, query, tagContainer), +treechildren::-moz-tree-image(query, OrganizerQuery_tags_______v) { + list-style-image: url("tag.svg") !important; +} + +/* calendar icon for folders grouping items by date */ +treechildren::-moz-tree-image(title, query, dayContainer) { + list-style-image: url("history.svg") !important; +} + +treechildren::-moz-tree-image(title, query, hostContainer) { + list-style-image: url("folder.svg") !important; +} + +/* history category icon */ +treechildren::-moz-tree-image(query, OrganizerQuery_history____v) { + list-style-image: url("history.svg") !important; +} + +treechildren::-moz-tree-image(title, query, folder) { + list-style-image: url("folder.svg") !important; +} diff --git a/chrome/icons/tag.svg b/chrome/icons/tag.svg new file mode 100644 index 0000000..8864d48 --- /dev/null +++ b/chrome/icons/tag.svg @@ -0,0 +1,3 @@ + + + diff --git a/chrome/userChrome.css b/chrome/userChrome.css index d8692d8..a43d558 100644 --- a/chrome/userChrome.css +++ b/chrome/userChrome.css @@ -9,6 +9,7 @@ @import url("global/popup.css"); @import url("global/tweaks.css"); @import url("global/browser.css"); +@import url("global/tree.css"); /* import custom stylesheet instead of modifying Edge-Frfox theme files */ @import url("custom.css");