fifth and final part of synching LCARStrek with windows theme changes in Firefox...
[themes.git] / LCARStrek / browser / devtools / webconsole.css
index b521681247aa48e4aacde91e46c3bed1e1298db0..4bebb5e600933f5c2ca40f5ec0449507a288e6eb 100644 (file)
@@ -6,59 +6,67 @@ window {
   padding: 0;
 }
 
-/* General output styles */
+/*
+ * This hardcoded width likely due to a toolkit Windows specific bug.
+ * See http://hg.mozilla.org/mozilla-central/annotate/f38d6df93cad/toolkit/themes/winstripe/global/textbox-aero.css#l7
+ */
 
-.webconsole-timestamp {
-  color: #8050B0;
-  margin-top: 0;
-  margin-bottom: 0;
-  font-family: "Liberation Mono", Consolas, "Courier New", monospace;
+.hud-filter-box {
+  width: 200px;
 }
 
-.hud-msg-node {
-  list-style-image: url("chrome://browser/skin/devtools/webconsole.png");
-  -moz-image-region: rect(0, 1px, 0, 0);
-}
+/* === webconsole.inc.css === */
 
-.webconsole-msg-icon {
-  margin: 3px 4px;
-  width: 8px;
-  height: 8px;
-}
+/* General output styles */
 
-.hud-output-node div {
-  -moz-user-select: text;
-  white-space: pre-wrap;
+a {
   -moz-user-focus: normal;
-}
-
-.hud-clickable {
+  -moz-user-input: enabled;
   cursor: pointer;
   text-decoration: underline;
 }
 
-.webconsole-msg-body {
-  margin-top: 0;
-  margin-bottom: 3px;
-  -moz-margin-start: 3px;
-  -moz-margin-end: 6px;
-  white-space: pre-wrap;
-  font-family: "Liberation Mono", Consolas, "Courier New", monospace;
+/* Workaround for Bug 575675 - FindChildWithRules aRelevantLinkVisited
+ * assertion when loading HTML page with links in XUL iframe */
+*:visited { }
+
+.message {
+  display: flex;
+  flex: 0 0 auto;
+  -moz-margin-start: 6px;
+  -moz-margin-end: 8px;
+  width: calc(100% - 6px - 8px);
 }
 
-.webconsole-msg-body-piece {
-  margin: 0;
+.message > .timestamp {
+  flex: 0 0 auto;
+  color: #8050B0;
+  margin: 4px 0;
 }
 
-.webconsole-msg-url {
+.message > .icon {
+  background: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 0, 1, 0, 0) no-repeat;
+  background-position: center 0.5em;
+  flex: 0 0 auto;
   margin: 0 6px;
+  padding: 0 4px;
+  width: 8px;
 }
 
-/* Repeated messages */
-.webconsole-msg-repeat {
-  margin: 2px 0;
-  padding-left: 4px;
-  padding-right: 4px;
+.message > .body {
+  flex: 1 1 100%;
+  white-space: pre-wrap;
+  word-wrap: break-word;
+  margin-top: 4px;
+}
+
+/* The red bubble that shows the number of times a message is repeated */
+.message > .repeats {
+  -moz-user-select: none;
+  flex: 0 0 auto;
+  margin: 2px 6px;
+  padding: 0 6px;
+  height: 1.25em;
   color: #000000;
   background-color: #FF0000;
   border-radius: 40px;
@@ -67,18 +75,36 @@ window {
   font-weight: 600;
 }
 
-/* TODO move this and other functional rules to content - bug 635359 */
-.webconsole-msg-repeat[value="1"] {
+.message > .repeats[value="1"] {
   display: none;
 }
 
-.webconsole-location {
-  margin-top: 0;
-  margin-bottom: 0;
-  -moz-margin-start: 0;
-  -moz-margin-end: 6px;
+.message > .location {
+  -moz-margin-start: 6px;
+  display: flex;
+  flex: 0 0 auto;
+  align-self: flex-start;
+  justify-content: flex-end;
   width: 10em;
+  margin-top: 4px;
+  color: #3333FF;
+  text-decoration: none;
+}
+
+.message > .location:hover,
+.message > .location:focus {
+  text-decoration: underline;
+}
+
+.message > .location > .filename {
+  text-overflow: ellipsis;
   text-align: end;
+  overflow: hidden;
+  white-space: nowrap;
+}
+
+.message > .location > .line-number {
+  flex: 0 0 auto;
 }
 
 .hud-msg-node[selected="true"] > .webconsole-timestamp,
@@ -86,19 +112,30 @@ window {
   color: inherit;
 }
 
-.jsterm-input-node,
-.jsterm-complete-node {
-  font-family: "Liberation Mono", Consolas, "Courier New", monospace;
+.jsterm-input-container {
+  border-top-width: 1px;
+  border-top-style: solid;
+}
+
+#output-wrapper {
+  direction: ltr;
+  overflow: auto;
+}
+
+#output-container {
+  -moz-user-select: text;
+  -moz-box-flex: 1;
+  display: flex;
+  flex-direction: column;
+  align-items: flex-start;
 }
 
-.hud-output-node {
-  -moz-appearance: none;
-  border-bottom: 1px solid #9C9CFF;
-  margin: 0;
+#output-container.hideTimestamps > .message > .timestamp {
+  display: none;
 }
 
-.hud-filtered-by-type,
-.hud-filtered-by-string {
+.filtered-by-type,
+.filtered-by-string {
   display: none;
 }
 
@@ -111,6 +148,10 @@ window {
 
 /* WebConsole colored drops */
 
+.webconsole-filter-button {
+  -moz-user-focus: normal;
+}
+
 .webconsole-filter-button[checked] {
   /* color: white !important; */
 }
@@ -141,12 +182,44 @@ window {
   border-color: #FFCF00;
 }
 
-.webconsole-msg-network > .webconsole-msg-icon-container {
+.message[category=network] > .icon {
   -moz-border-start: solid #FFCF00 6px;
 }
 
-.webconsole-msg-network.webconsole-msg-error {
-  -moz-image-region: rect(0, 16px, 8px, 8px);
+.message[category=network][severity=error] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 0, 16, 8, 8);
+}
+
+.message[category=network] > .body {
+  display: flex;
+}
+
+.message[category=network] .method {
+  flex: 0 0 auto;
+}
+
+.message[category=network]:not(.navigation-marker) .url {
+  flex: 1 1 auto;
+  /* Make sure the URL is very small initially, let flex change width as needed. */
+  width: 100px;
+  min-width: 5em;
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+
+.message[category=network] .status {
+  flex: 0 0 auto;
+  -moz-margin-start: 6px;
+}
+
+.message[category=network].mixed-content .url {
+  color: #FF0000;
+}
+
+.message .learn-more-link {
+  color: #3333FF;
+  margin: 0 6px;
 }
 
 /* CSS styles */
@@ -155,16 +228,16 @@ window {
   border-color: #9C9CFF;
 }
 
-.webconsole-msg-cssparser > .webconsole-msg-icon-container {
+.message[category=cssparser] > .icon {
   -moz-border-start: solid #9C9CFF 6px;
 }
 
-.webconsole-msg-cssparser.webconsole-msg-error {
-  -moz-image-region: rect(8px, 16px, 16px, 8px);
+.message[category=cssparser][severity=error] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 8, 16, 16, 8);
 }
 
-.webconsole-msg-cssparser.webconsole-msg-warn {
-  -moz-image-region: rect(8px, 24px, 16px, 16px);
+.message[category=cssparser][severity=warn] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 8, 24, 16, 16);
 }
 
 /* JS styles */
@@ -173,16 +246,16 @@ window {
    border-color: #FF9F00;
 }
 
-.webconsole-msg-exception > .webconsole-msg-icon-container {
+.message[category=exception] > .icon {
   -moz-border-start: solid #FF9F00 6px;
 }
 
-.webconsole-msg-exception.webconsole-msg-error {
-  -moz-image-region: rect(16px, 16px, 24px, 8px);
+.message[category=exception][severity=error] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 16, 16, 24, 8);
 }
 
-.webconsole-msg-exception.webconsole-msg-warn {
-  -moz-image-region: rect(16px, 24px, 24px, 16px);
+.message[category=exception][severity=warn] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 16, 24, 24, 16);
 }
 
 /* Web Developer styles */
@@ -191,68 +264,48 @@ window {
    border-color: #8050B0;
 }
 
-.webconsole-msg-console > .webconsole-msg-icon-container {
+.message[category=console] > .icon {
   -moz-border-start: solid #8050B0 6px;
 }
 
-.webconsole-msg-console.webconsole-msg-error,
-.webconsole-msg-output.webconsole-msg-error {
-  -moz-image-region: rect(24px, 16px, 32px, 8px);
+.message[category=console][severity=error] > .icon,
+.message[category=output][severity=error] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 24, 16, 32, 8);
 }
 
-.webconsole-msg-console.webconsole-msg-warn {
-  -moz-image-region: rect(24px, 24px, 32px, 16px);
+.message[category=console][severity=warn] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 24, 24, 32, 16);
 }
 
-.webconsole-msg-console.webconsole-msg-info {
-  -moz-image-region: rect(24px, 32px, 32px, 24px);
-}
-
-webconsole-mixed-content {
-  color: #FF0000;
-}
-
-.webconsole-mixed-content-link {
-  color: #9C9CFF;
-  margin: 0;
+.message[category=console][severity=info] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 24, 32, 32, 24);
 }
 
 /* Input and output styles */
-.webconsole-msg-input > .webconsole-msg-icon-container,
-.webconsole-msg-output > .webconsole-msg-icon-container {
-  border-left: solid #808080 6px;
+.message[category=input] > .icon,
+.message[category=output] > .icon {
+  -moz-border-start: solid #A09090 6px;
 }
 
-.webconsole-msg-input {
-  -moz-image-region: rect(24px, 40px, 32px, 32px);
+.message[category=input] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 24, 40, 32, 32);
 }
 
-.webconsole-msg-output {
-  -moz-image-region: rect(24px, 48px, 32px, 40px);
-}
-/*
-.webconsole-close-button {
-  border: none;
-  padding-top: 4px;
-  padding-bottom: 5px;
-  list-style-image: url("chrome://global/skin/icons/close-button.gif");
+.message[category=output] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 24, 48, 32, 40);
 }
 
-.webconsole-close-button:hover,
-.webconsole-close-button:hover:active {
-  list-style-image: url("chrome://global/skin/icons/close-button-hover.gif");
-}
-*/
 /* JSTerm Styles */
 
 .jsterm-input-node,
 .jsterm-complete-node {
   -moz-padding-start: 16px;
   margin: 3px 0 0 0;
+  background-color: transparent;
 }
 
 .jsterm-input-node {
-  background: url("chrome://browser/skin/devtools/commandline.png") 4px 3px no-repeat;
+  background: -moz-image-rect(url("chrome://browser/skin/devtools/commandline-icon.png"), 0, 32, 16, 16) no-repeat;
 }
 
 :-moz-any(.jsterm-input-node,
@@ -260,25 +313,18 @@ webconsole-mixed-content {
   overflow-x: hidden;
 }
 
-.jsterm-complete-node > .textbox-input-box > .textbox-textarea {
-  color: #8050B0;
-}
-
-/* Filter */
-
-/*
- * This hardcoded width likely due to a toolkit Windows specific bug.
- * See http://hg.mozilla.org/mozilla-central/annotate/f38d6df93cad/toolkit/themes/winstripe/global/textbox-aero.css#l7
- */
-
-.hud-filter-box {
-  width: 200px;
+.inlined-variables-view .body {
+  display: flex;
+  flex-direction: column;
 }
 
-.webconsole-msg-inspector iframe {
-  height: 7em;
+.inlined-variables-view iframe {
+ display: block;
+  flex: 1;
+  margin-top: 5px;
   margin-bottom: 15px;
   -moz-margin-end: 15px;
+  border: 1px solid #9C9CFF;
   border-radius: 4px;
 }
 
@@ -287,7 +333,9 @@ webconsole-mixed-content {
   border: none;
 }
 
-.webconsole-msg-security > .webconsole-msg-icon-container {
+/* Security styles */
+
+.message[category=security] > .icon {
   -moz-border-start: solid #FF0000 6px;
 }
 
@@ -295,3 +343,68 @@ webconsole-mixed-content {
   background-color: #FF0000;
   border-color: #FFCF00;
 }
+
+.message[category=security][severity=error] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 32, 16, 40, 8);
+}
+
+.message[category=security][severity=warn] > .icon {
+  background-image: -moz-image-rect(url("chrome://browser/skin/devtools/webconsole.png"), 32, 24, 40, 16);
+}
+
+.navigation-marker {
+  color: #000000;
+  background-color: #A09090;
+  margin-top: 6px;
+  margin-bottom: 6px;
+  font-size: 0.9em;
+}
+
+.navigation-marker .url {
+  -moz-padding-end: 9px;
+  text-decoration: none;
+}
+
+/* Replace these values with CSS variables as available */
+.theme-dark .jsterm-input-container {
+  background-color: #000000; /* tabToolbarBackgroundColor */
+  border-color: #9C9CFF; /* mainBackgroundColor */
+}
+
+.theme-dark .jsterm-input-node {
+  color: #E7ADE7; /* textColor */
+}
+
+.theme-dark .jsterm-complete-node {
+  color: #A09090; /* commentColor */
+}
+
+.theme-dark .navigation-marker .url {
+  background: #000000; /* mainBackgroundColor */
+}
+
+.theme-dark .inlined-variables-view iframe {
+  border-color: #A09090;
+}
+
+/* Replace these values with CSS variables as available */
+.theme-light .jsterm-input-container {
+  background-color: #000000; /* tabToolbarBackgroundColor */
+  border-color: #9C9CFF; /* mainBackgroundColor */
+}
+
+.theme-light .jsterm-input-node {
+  color: #E7ADE7; /* textColor */
+}
+
+.theme-light .jsterm-complete-node {
+  color: #A09090; /* commentColor */
+}
+
+.theme-light .navigation-marker .url {
+  background: #000000; /* mainBackgroundColor */
+}
+
+.theme-light .inlined-variables-view iframe {
+  border-color: #A09090;
+}