Fix the toolbarbutton dropmarker style
This commit is contained in:
parent
88ce834385
commit
988a443974
5 changed files with 34 additions and 25 deletions
|
@ -40,15 +40,6 @@
|
|||
max-width: 29px;
|
||||
}
|
||||
|
||||
.zotero-tb-button[type=menu] > .toolbarbutton-menu-dropmarker {
|
||||
-moz-default-appearance: none;
|
||||
background-image: url("chrome://zotero/skin/searchbar-dropmarker.png");
|
||||
width: 7px;
|
||||
height: 4px;
|
||||
background-repeat: no-repeat;
|
||||
background-size: 100%;
|
||||
}
|
||||
|
||||
/* A decent hack: reverse the effective order of the dropmarker and icon in RTL
|
||||
mode so that the above CSS, which places the menubutton-start.png background
|
||||
on the toolbarbutton-icon, will make sense. (Otherwise the dropmarker appears
|
||||
|
@ -404,7 +395,6 @@ treechildren::-moz-tree-image {
|
|||
@media (min-resolution: 1.25dppx) {
|
||||
.zotero-tb-button,.zotero-tb-button:first-child,.zotero-tb-button:last-child { background: url("chrome://zotero/skin/mac/menubutton-end@2x.png") right center/auto 24px no-repeat; }
|
||||
.zotero-tb-button > .toolbarbutton-icon { background: url("chrome://zotero/skin/mac/menubutton-start@2x.png") left center/auto 24px no-repeat; }
|
||||
.zotero-tb-button[type=menu] > .toolbarbutton-menu-dropmarker { background-image: url("chrome://zotero/skin/searchbar-dropmarker@2x.png"); }
|
||||
.zotero-tb-button:-moz-window-inactive > .toolbarbutton-icon { background: url("chrome://zotero/skin/mac/menubutton-start-inactive-window@2x.png") left center/auto 24px no-repeat; }
|
||||
.zotero-tb-button:-moz-window-inactive,.zotero-tb-button:-moz-window-inactive:first-child,.zotero-tb-button:-moz-window-inactive:last-child { background: url("chrome://zotero/skin/mac/menubutton-end-inactive-window@2x.png") right center/auto 24px no-repeat; }
|
||||
.zotero-tb-button[open="true"],.zotero-tb-button:not([disabled="true"]):hover:active { background: url("chrome://zotero/skin/mac/menubutton-end-pressed@2x.png") right center/auto 24px no-repeat; }
|
||||
|
|
|
@ -8,9 +8,9 @@
|
|||
}
|
||||
}
|
||||
|
||||
/* Dropmarker added automatically on Linux */
|
||||
.toolbarbutton-menu-dropmarker {
|
||||
list-style-image: none;
|
||||
.zotero-tb-button[type="menu"] > .toolbarbutton-menu-dropmarker {
|
||||
-moz-default-appearance: toolbarbutton-dropdown;
|
||||
margin-left: 4px;
|
||||
}
|
||||
|
||||
.zotero-tb-button:not([type=menu]) {
|
||||
|
|
|
@ -24,6 +24,10 @@
|
|||
}
|
||||
}
|
||||
|
||||
.zotero-tb-button[type="menu"] > .toolbarbutton-menu-dropmarker {
|
||||
margin-left: 4px;
|
||||
}
|
||||
|
||||
#zotero-tb-sync-error {
|
||||
margin-right: 4px;
|
||||
padding-top: 4px;
|
||||
|
|
|
@ -44,7 +44,8 @@ window.addEventListener('DOMContentLoaded', () => {
|
|||
if (MozToolbarbutton) {
|
||||
let originalRender = MozToolbarbutton.prototype.render;
|
||||
MozToolbarbutton.prototype.render = function () {
|
||||
originalRender();
|
||||
originalRender.apply(this);
|
||||
if (!this._zoteroMouseDownListenerAdded) {
|
||||
this.addEventListener('mousedown', (event) => {
|
||||
if (!event.defaultPrevented
|
||||
&& !this.disabled
|
||||
|
@ -53,6 +54,8 @@ window.addEventListener('DOMContentLoaded', () => {
|
|||
event.preventDefault();
|
||||
}
|
||||
});
|
||||
this._zoteroMouseDownListenerAdded = true;
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
@ -237,6 +237,19 @@
|
|||
margin-inline-end: 2px;
|
||||
}
|
||||
|
||||
.zotero-tb-button[type="menu"] > .toolbarbutton-menu-dropmarker {
|
||||
-moz-default-appearance: none;
|
||||
background-image: url("chrome://zotero/skin/searchbar-dropmarker.png");
|
||||
width: 7px;
|
||||
height: 4px;
|
||||
background-repeat: no-repeat;
|
||||
background-size: 100%;
|
||||
}
|
||||
|
||||
.zotero-tb-button[type="menu"] > .toolbarbutton-menu-dropmarker::part(icon) {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.zotero-tb-button:hover:active {
|
||||
mix-blend-mode: multiply;
|
||||
}
|
||||
|
@ -715,8 +728,7 @@
|
|||
|
||||
/* BEGIN 2X BLOCK -- DO NOT EDIT MANUALLY -- USE 2XIZE */
|
||||
@media (min-resolution: 1.25dppx) {
|
||||
#zotero-items-column-hasAttachment { list-style-image: url(chrome://zotero/skin/attach-small@2x.png); }
|
||||
#zotero-items-column-numNotes { list-style-image: url(chrome://zotero/skin/treeitem-note-small@2x.png); }
|
||||
.zotero-tb-button[type="menu"] > .toolbarbutton-menu-dropmarker { background-image: url("chrome://zotero/skin/searchbar-dropmarker@2x.png"); }
|
||||
#zotero-tb-collection-add { list-style-image: url('chrome://zotero/skin/toolbar-collection-add@2x.png'); }
|
||||
.zotero-menuitem-new-feed { list-style-image: url('chrome://zotero/skin/toolbar-feed-add@2x.png'); }
|
||||
#zotero-tb-library-add-menu { list-style-image: url('chrome://zotero/skin/library_add@2x.png'); }
|
||||
|
|
Loading…
Reference in a new issue