gecko-dev/devtools/client/themes/common.css
Julian Descottes 973205986c Bug 1266450 - part1: move devtools tooltip styles to dedicated file;r=bgrins
Tooltip styles are scattered between common.css and panel-specific CSS
files (e.g. inspector.css). For the HTML tooltip, the panel specific CSS
files will not be applied since the tooltip container is appended to the
devtools top window.

This changeset creates a new tooltips.css file which is loaded by default
with devtools themes.

MozReview-Commit-ID: BnoRi9gLfD5

--HG--
extra : rebase_source : 3fee4731f65563c4b61371e3a3c51fb797d1a12b
extra : source : bd8878532e1f370fb49e0c50de0b2da267f7de8a
2016-06-03 14:36:56 +02:00

210 lines
5.4 KiB
CSS

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
@import url("splitters.css");
:root {
font: message-box;
}
:root[platform="mac"] {
--monospace-font-family: Menlo, monospace;
}
:root[platform="win"] {
--monospace-font-family: Consolas, monospace;
}
:root[platform="linux"],
:root.theme-firebug {
--monospace-font-family: monospace;
}
:root.theme-firebug {
--proportional-font-family: Lucida Grande, Tahoma, sans-serif;
}
.devtools-monospace {
font-family: var(--monospace-font-family);
}
:root[platform="linux"] .devtools-monospace {
font-size: 80%;
}
/* Autocomplete Popup */
.devtools-autocomplete-popup {
-moz-appearance: none !important;
box-shadow: 0 1px 0 hsla(209,29%,72%,.25) inset;
background-color: transparent;
border-radius: 3px;
overflow-x: hidden;
max-height: 20rem;
}
:root[platform="linux"] .devtools-autocomplete-popup {
/* Root font size is bigger on Linux, adjust rem-based values. */
max-height: 16rem;
}
.devtools-autocomplete-listbox {
-moz-appearance: none !important;
background-color: transparent;
border-width: 0px !important;
margin: 0;
}
.devtools-autocomplete-listbox > scrollbox {
padding: 2px;
}
.inplace-editor-autocomplete-popup .devtools-autocomplete-listbox {
/* Inplace editor closes the autocomplete popup on blur, the autocomplete
popup should not steal the focus here.*/
-moz-user-focus: ignore;
}
.devtools-autocomplete-listbox > richlistitem,
.devtools-autocomplete-listbox > richlistitem[selected] {
width: 100%;
background-color: transparent;
border-radius: 4px;
}
.devtools-autocomplete-listbox.dark-theme > richlistitem[selected],
.devtools-autocomplete-listbox.dark-theme > richlistitem:hover {
background-color: rgba(0,0,0,0.5);
}
.devtools-autocomplete-listbox.dark-theme > richlistitem[selected] > .autocomplete-value,
.devtools-autocomplete-listbox:focus.dark-theme > richlistitem[selected] > .initial-value {
color: hsl(208,100%,60%);
}
.devtools-autocomplete-listbox.dark-theme > richlistitem[selected] > label {
color: #eee;
}
.devtools-autocomplete-listbox.dark-theme > richlistitem > label {
color: #ccc;
}
.devtools-autocomplete-listbox > richlistitem > .initial-value,
.devtools-autocomplete-listbox > richlistitem > .autocomplete-value {
margin: 0;
padding: 1px 0;
}
.devtools-autocomplete-listbox > richlistitem > .autocomplete-count {
text-align: end;
}
/* Rest of the dark and light theme */
.devtools-autocomplete-popup,
.theme-dark .CodeMirror-hints,
.theme-dark .CodeMirror-Tern-tooltip {
border: 1px solid hsl(210,11%,10%);
background-image: linear-gradient(to bottom, hsla(209,18%,18%,0.9), hsl(210,11%,16%));
}
.devtools-autocomplete-popup.light-theme,
.light-theme .CodeMirror-hints,
.light-theme .CodeMirror-Tern-tooltip {
border: 1px solid hsl(210,24%,90%);
background-image: linear-gradient(to bottom, hsla(209,18%,100%,0.9), hsl(210,24%,95%));
}
.devtools-autocomplete-popup.light-theme {
box-shadow: 0 1px 0 hsla(209,29%,90%,.25) inset;
}
.theme-firebug .devtools-autocomplete-popup {
border-color: var(--theme-splitter-color);
border-radius: 5px;
font-size: var(--theme-autompletion-font-size);
}
.devtools-autocomplete-popup.firebug-theme {
background: var(--theme-body-background);
}
.devtools-autocomplete-listbox.firebug-theme > richlistitem[selected],
.devtools-autocomplete-listbox.firebug-theme > richlistitem:hover,
.devtools-autocomplete-listbox.light-theme > richlistitem[selected],
.devtools-autocomplete-listbox.light-theme > richlistitem:hover {
background-color: rgba(128,128,128,0.3);
}
.devtools-autocomplete-listbox.firebug-theme > richlistitem[selected] > .autocomplete-value,
.devtools-autocomplete-listbox:focus.firebug-theme > richlistitem[selected] > .initial-value,
.devtools-autocomplete-listbox.light-theme > richlistitem[selected] > .autocomplete-value,
.devtools-autocomplete-listbox:focus.light-theme > richlistitem[selected] > .initial-value {
color: #222;
}
.devtools-autocomplete-listbox.firebug-theme > richlistitem > label,
.devtools-autocomplete-listbox.light-theme > richlistitem > label {
color: #666;
}
/* links to source code, like displaying `myfile.js:45` */
.devtools-source-link {
font-family: var(--monospace-font-family);
color: var(--theme-highlight-blue);
cursor: pointer;
white-space: nowrap;
display: flex;
text-decoration: none;
font-size: 11px;
width: 12em; /* probably should be changed for each tool */
}
.devtools-source-link:hover {
text-decoration: underline;
}
.devtools-source-link > .filename {
text-overflow: ellipsis;
text-align: end;
overflow: hidden;
margin: 2px 0px;
cursor: pointer;
}
.devtools-source-link > .line-number {
flex: none;
margin: 2px 0px;
cursor: pointer;
}
/* Keyboard focus highlight styles */
:-moz-focusring {
outline: var(--theme-focus-outline);
outline-offset: -1px;
}
textbox[focused="true"] {
border-color: var(--theme-focus-border-color-textbox);
box-shadow: var(--theme-focus-box-shadow-textbox);
transition: all 0.2s ease-in-out
}
textbox :-moz-focusring {
box-shadow: none;
outline: none;
}
/* Form fields should already have box-shadow hightlight */
select:-moz-focusring,
input[type="radio"]:-moz-focusring,
input[type="checkbox"]:-moz-focusring,
checkbox:-moz-focusring {
outline: none;
}