| 1 | /* This Source Code Form is subject to the terms of the Mozilla Public |
| 2 | * License, v. 2.0. If a copy of the MPL was not distributed with this |
| 3 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
| 4 | |
| 5 | /* Webconsole specific theme variables */ |
| 6 | |
| 7 | .theme-dark, |
| 8 | .theme-light, |
| 9 | .theme-firebug { |
| 10 | } |
| 11 | |
| 12 | window { |
| 13 | padding: 0; |
| 14 | } |
| 15 | |
| 16 | /* |
| 17 | * This hardcoded width likely due to a toolkit Windows specific bug. |
| 18 | * See http://hg.mozilla.org/mozilla-central/annotate/f38d6df93cad/toolkit/themes/winstripe/global/textbox-aero.css#l7 |
| 19 | */ |
| 20 | |
| 21 | .hud-filter-box { |
| 22 | width: 200px; |
| 23 | } |
| 24 | |
| 25 | /* General output styles */ |
| 26 | |
| 27 | a { |
| 28 | -moz-user-focus: normal; |
| 29 | -moz-user-input: enabled; |
| 30 | cursor: pointer; |
| 31 | text-decoration: underline; |
| 32 | } |
| 33 | |
| 34 | /* Workaround for Bug 575675 - FindChildWithRules aRelevantLinkVisited |
| 35 | * assertion when loading HTML page with links in XUL iframe */ |
| 36 | *:visited { } |
| 37 | |
| 38 | .message { |
| 39 | display: flex; |
| 40 | padding: 0 7px; |
| 41 | width: 100%; |
| 42 | box-sizing: border-box; |
| 43 | } |
| 44 | |
| 45 | .message > .prefix, |
| 46 | .message > .timestamp { |
| 47 | flex: none; |
| 48 | color: var(--theme-comment); |
| 49 | margin: 3px 6px 0 0; |
| 50 | } |
| 51 | |
| 52 | .message > .indent { |
| 53 | flex: none; |
| 54 | } |
| 55 | |
| 56 | .message > .icon { |
| 57 | flex: none; |
| 58 | margin: 3px 6px 0 0; |
| 59 | padding: 0 4px; |
| 60 | height: 1em; |
| 61 | align-self: flex-start; |
| 62 | } |
| 63 | |
| 64 | .message > .icon::before { |
| 65 | content: ""; |
| 66 | background-image: url("chrome://devtools/skin/images/webconsole.svg"); |
| 67 | background-position: 12px 12px; |
| 68 | background-repeat: no-repeat; |
| 69 | background-size: 72px 60px; |
| 70 | width: 12px; |
| 71 | height: 12px; |
| 72 | display: inline-block; |
| 73 | } |
| 74 | |
| 75 | .message > .message-body-wrapper { |
| 76 | flex: auto; |
| 77 | min-width: 0px; |
| 78 | margin: 3px; |
| 79 | } |
| 80 | |
| 81 | .message-body-wrapper .table-widget-body { |
| 82 | overflow: visible; |
| 83 | } |
| 84 | |
| 85 | /* The red bubble that shows the number of times a message is repeated */ |
| 86 | .message-repeats { |
| 87 | -moz-user-select: none; |
| 88 | flex: none; |
| 89 | margin: 2px 6px; |
| 90 | padding: 0 6px; |
| 91 | height: 1.25em; |
| 92 | color: #000000; |
| 93 | background-color: #FF0000; |
| 94 | border-radius: 40px; |
| 95 | /* font: message-box; */ |
| 96 | font-size: 0.9em; |
| 97 | font-weight: 600; |
| 98 | } |
| 99 | |
| 100 | .message-repeats[value="1"] { |
| 101 | display: none; |
| 102 | } |
| 103 | |
| 104 | .message-location { |
| 105 | max-width: 40%; |
| 106 | } |
| 107 | |
| 108 | .stack-trace .frame-link-source, |
| 109 | .message-location .frame-link-source { |
| 110 | direction: rtl; |
| 111 | white-space: nowrap; |
| 112 | overflow: hidden; |
| 113 | text-overflow: ellipsis; |
| 114 | } |
| 115 | |
| 116 | .stack-trace .frame-link-function-display-name { |
| 117 | max-width: 50%; |
| 118 | white-space: nowrap; |
| 119 | overflow: hidden; |
| 120 | text-overflow: ellipsis; |
| 121 | } |
| 122 | |
| 123 | .message-flex-body { |
| 124 | display: flex; |
| 125 | } |
| 126 | |
| 127 | .message-body > * { |
| 128 | white-space: pre-wrap; |
| 129 | word-wrap: break-word; |
| 130 | } |
| 131 | |
| 132 | .message-flex-body > .message-body { |
| 133 | flex: auto; |
| 134 | } |
| 135 | |
| 136 | #output-wrapper { |
| 137 | direction: ltr; |
| 138 | overflow: auto; |
| 139 | -moz-user-select: text; |
| 140 | } |
| 141 | |
| 142 | /* The width on #output-container is set to a hardcoded px in webconsole.js |
| 143 | since it's way faster than using 100% with -moz-box-flex (see Bug 1237368) */ |
| 144 | |
| 145 | #output-container.hideTimestamps > .message { |
| 146 | padding-inline-start: 0; |
| 147 | margin-inline-start: 7px; |
| 148 | width: calc(100% - 7px); |
| 149 | } |
| 150 | |
| 151 | #output-container.hideTimestamps > .message > .timestamp { |
| 152 | display: none; |
| 153 | } |
| 154 | |
| 155 | #output-container.hideTimestamps > .message > .indent { |
| 156 | background-color: var(--theme-body-background); |
| 157 | } |
| 158 | |
| 159 | .filtered-by-type, |
| 160 | .filtered-by-string { |
| 161 | display: none; |
| 162 | } |
| 163 | |
| 164 | .hidden-message { |
| 165 | display: block; |
| 166 | visibility: hidden; |
| 167 | height: 0; |
| 168 | overflow: hidden; |
| 169 | } |
| 170 | |
| 171 | /* WebConsole colored drops */ |
| 172 | |
| 173 | .webconsole-filter-button { |
| 174 | -moz-user-focus: normal; |
| 175 | } |
| 176 | |
| 177 | .webconsole-filter-button > .toolbarbutton-menubutton-button:before { |
| 178 | content: ""; |
| 179 | display: inline-block; |
| 180 | height: 8px; |
| 181 | width: 8px; |
| 182 | border-radius: 50%; |
| 183 | margin-inline-start: 5px; |
| 184 | border-width: 1px; |
| 185 | border-style: solid; |
| 186 | } |
| 187 | |
| 188 | /* Network styles */ |
| 189 | .webconsole-filter-button[category="net"] > .toolbarbutton-menubutton-button:before { |
| 190 | background-image: linear-gradient(#BF9B00, #7F6700); |
| 191 | border-color: #FFCF00; |
| 192 | } |
| 193 | |
| 194 | .message:hover { |
| 195 | background-color: var(--theme-contrast-background); |
| 196 | } |
| 197 | |
| 198 | .message[severity=error] { |
| 199 | background-color: #FF0000; |
| 200 | } |
| 201 | |
| 202 | .console-string { |
| 203 | color: var(--theme-highlight-orange); |
| 204 | } |
| 205 | |
| 206 | .message[severity=error] .console-string { |
| 207 | color: #000000; |
| 208 | } |
| 209 | |
| 210 | .theme-selected .console-string, |
| 211 | .theme-selected .cm-number, |
| 212 | .theme-selected .cm-variable, |
| 213 | .theme-selected .kind-ArrayLike { |
| 214 | color: #000000 !important; /* Selection Text Color */ |
| 215 | } |
| 216 | |
| 217 | .message[category=network] > .indent { |
| 218 | border-inline-end: solid var(--theme-body-color-alt) 6px; |
| 219 | } |
| 220 | |
| 221 | .message[category=network][severity=error] > .icon::before { |
| 222 | background-position: -12px 0; |
| 223 | } |
| 224 | |
| 225 | .message[category=network] > .message-body { |
| 226 | display: flex; |
| 227 | flex-wrap: wrap; |
| 228 | } |
| 229 | |
| 230 | .message[category=network] .method { |
| 231 | flex: none; |
| 232 | } |
| 233 | |
| 234 | .message[category=network]:not(.navigation-marker) .url { |
| 235 | flex: 1 1 auto; |
| 236 | /* Make sure the URL is very small initially, let flex change width as needed. */ |
| 237 | width: 100px; |
| 238 | min-width: 5em; |
| 239 | white-space: nowrap; |
| 240 | overflow: hidden; |
| 241 | text-overflow: ellipsis; |
| 242 | } |
| 243 | |
| 244 | .message[category=network] .status { |
| 245 | flex: none; |
| 246 | margin-inline-start: 6px; |
| 247 | } |
| 248 | |
| 249 | .message[category=network].mixed-content .url { |
| 250 | color: var(--theme-highlight-red); |
| 251 | } |
| 252 | |
| 253 | .message .learn-more-link { |
| 254 | color: var(--theme-highlight-blue); |
| 255 | margin: 0 6px; |
| 256 | } |
| 257 | |
| 258 | .message[category=network] .xhr { |
| 259 | background-color: var(--theme-body-color-alt); |
| 260 | color: var(--theme-body-background); |
| 261 | border-radius: 3px; |
| 262 | font-weight: bold; |
| 263 | font-size: 10px; |
| 264 | padding: 2px; |
| 265 | line-height: 10px; |
| 266 | margin-inline-start: 3px; |
| 267 | margin-inline-end: 1ex; |
| 268 | } |
| 269 | |
| 270 | /* CSS styles */ |
| 271 | .webconsole-filter-button[category="css"] > .toolbarbutton-menubutton-button:before { |
| 272 | background-image: linear-gradient(#7575BF, #4E4E7F); |
| 273 | border-color: #9C9CFF; |
| 274 | } |
| 275 | |
| 276 | .message[category=cssparser] > .indent { |
| 277 | border-inline-end: solid #9C9CFF 6px; |
| 278 | } |
| 279 | |
| 280 | .message[category=cssparser][severity=error] > .icon::before { |
| 281 | background-position: -12px -12px; |
| 282 | } |
| 283 | |
| 284 | .message[category=cssparser][severity=warn] > .icon::before { |
| 285 | background-position: -24px -12px; |
| 286 | } |
| 287 | |
| 288 | /* JS styles */ |
| 289 | .webconsole-filter-button[category="js"] > .toolbarbutton-menubutton-button:before { |
| 290 | background-image: linear-gradient(#BF7700, #7F4F00); |
| 291 | border-color: #FF9F00; |
| 292 | } |
| 293 | |
| 294 | .message[category=exception] > .indent { |
| 295 | border-inline-end: solid #FF9F00 6px; |
| 296 | } |
| 297 | |
| 298 | .message[category=exception][severity=error] > .icon::before { |
| 299 | background-position: -12px -24px; |
| 300 | } |
| 301 | |
| 302 | .message[category=exception][severity=warn] > .icon::before { |
| 303 | background-position: -24px -24px; |
| 304 | } |
| 305 | |
| 306 | /* Web Developer styles */ |
| 307 | .webconsole-filter-button[category="logging"] > .toolbarbutton-menubutton-button:before { |
| 308 | background-image: linear-gradient(#5F3B83, #3F2756); |
| 309 | border-color: #8050B0; |
| 310 | } |
| 311 | |
| 312 | .message[category=console] > .indent { |
| 313 | border-inline-end: solid #8050B0 6px; |
| 314 | } |
| 315 | |
| 316 | .message[category=console][severity=error] > .icon::before, |
| 317 | .message[category=output][severity=error] > .icon::before, |
| 318 | .message[category=server][severity=error] > .icon::before { |
| 319 | background-position: -12px -36px; |
| 320 | } |
| 321 | |
| 322 | .message[category=console][severity=warn] > .icon::before, |
| 323 | .message[category=server][severity=warn] > .icon::before { |
| 324 | background-position: -24px -36px; |
| 325 | } |
| 326 | |
| 327 | .message[category=console][severity=info] > .icon::before, |
| 328 | .message[category=server][severity=info] > .icon::before { |
| 329 | background-position: -36px -36px; |
| 330 | } |
| 331 | |
| 332 | /* Server Logging Styles */ |
| 333 | |
| 334 | .webconsole-filter-button[category="server"] > .toolbarbutton-menubutton-button:before { |
| 335 | background-image: linear-gradient(#006363, #004242); |
| 336 | border-color: #008484; |
| 337 | } |
| 338 | |
| 339 | .message[category=server] > .indent { |
| 340 | border-inline-end: solid #8050B0 6px; |
| 341 | } |
| 342 | |
| 343 | /* Input and output styles */ |
| 344 | .message[category=input] > .indent, |
| 345 | .message[category=output] > .indent { |
| 346 | border-inline-end: solid #A09090 6px; |
| 347 | } |
| 348 | |
| 349 | .message[category=input] > .icon::before { |
| 350 | background-position: -48px -36px; |
| 351 | } |
| 352 | |
| 353 | .message[category=output] > .icon::before { |
| 354 | background-position: -60px -36px; |
| 355 | } |
| 356 | |
| 357 | /* JSTerm Styles */ |
| 358 | .jsterm-input-container { |
| 359 | background-color: var(--theme-tab-toolbar-background); |
| 360 | border-top: 1px solid var(--theme-splitter-color); |
| 361 | } |
| 362 | |
| 363 | .jsterm-input-node, |
| 364 | .jsterm-complete-node { |
| 365 | border: none; |
| 366 | padding: 0; |
| 367 | padding-inline-start: 20px; |
| 368 | margin: 0; |
| 369 | -moz-appearance: none; |
| 370 | background-color: transparent; |
| 371 | } |
| 372 | |
| 373 | .jsterm-input-node[focused="true"] { |
| 374 | background-image: var(--theme-command-line-image-focus); |
| 375 | box-shadow: none; |
| 376 | } |
| 377 | |
| 378 | .jsterm-complete-node { |
| 379 | color: var(--theme-comment); |
| 380 | } |
| 381 | |
| 382 | .jsterm-input-node { |
| 383 | /* Always allow scrolling on input - it auto expands in js by setting height, |
| 384 | but don't want it to get bigger than the window. 24px = toolbar height. */ |
| 385 | max-height: calc(90vh - 24px); |
| 386 | background-image: var(--theme-command-line-image); |
| 387 | background-repeat: no-repeat; |
| 388 | background-size: 16px 16px; |
| 389 | background-position: 4px 50%; |
| 390 | color: var(--theme-content-color1); |
| 391 | } |
| 392 | |
| 393 | :-moz-any(.jsterm-input-node, |
| 394 | .jsterm-complete-node) > .textbox-input-box > .textbox-textarea { |
| 395 | overflow-x: hidden; |
| 396 | /* Set padding for console input on textbox to make sure it is inlcuded in |
| 397 | scrollHeight that is used when resizing JSTerminal's input. Note: textbox |
| 398 | default style has important already */ |
| 399 | padding: 4px 0 !important; |
| 400 | } |
| 401 | |
| 402 | .inlined-variables-view .message-body { |
| 403 | display: flex; |
| 404 | flex-direction: column; |
| 405 | resize: vertical; |
| 406 | overflow: auto; |
| 407 | min-height: 200px; |
| 408 | } |
| 409 | |
| 410 | .inlined-variables-view iframe { |
| 411 | display: block; |
| 412 | flex: 1; |
| 413 | margin-top: 5px; |
| 414 | margin-bottom: 15px; |
| 415 | margin-inline-end: 15px; |
| 416 | border: 1px solid var(--theme-splitter-color); |
| 417 | border-radius: 3px; |
| 418 | } |
| 419 | |
| 420 | #webconsole-sidebar > tabs { |
| 421 | height: 0; |
| 422 | border: none; |
| 423 | } |
| 424 | |
| 425 | .devtools-side-splitter ~ #webconsole-sidebar[hidden] { |
| 426 | display: none; |
| 427 | } |
| 428 | |
| 429 | /* Security styles */ |
| 430 | |
| 431 | .message[category=security] > .indent { |
| 432 | border-inline-end: solid #FF0000 6px; |
| 433 | } |
| 434 | |
| 435 | .webconsole-filter-button[category="security"] > .toolbarbutton-menubutton-button:before { |
| 436 | background-color: #FF0000; |
| 437 | border-color: #FFCF00; |
| 438 | } |
| 439 | |
| 440 | .message[category=security][severity=error] > .icon::before { |
| 441 | background-position: -12px -48px; |
| 442 | } |
| 443 | |
| 444 | .message[category=security][severity=warn] > .icon::before { |
| 445 | background-position: -24px -48px; |
| 446 | } |
| 447 | |
| 448 | .navigation-marker { |
| 449 | color: #000000; |
| 450 | background-color: #A09090; |
| 451 | margin-top: 6px; |
| 452 | margin-bottom: 6px; |
| 453 | font-size: 0.9em; |
| 454 | } |
| 455 | |
| 456 | .navigation-marker .url { |
| 457 | padding-inline-end: 9px; |
| 458 | text-decoration: none; |
| 459 | background: var(--theme-body-background); |
| 460 | } |
| 461 | |
| 462 | .stacktrace { |
| 463 | display: none; |
| 464 | padding: 5px 10px; |
| 465 | margin: 5px 0 0 0; |
| 466 | overflow-y: auto; |
| 467 | border: 1px solid var(--theme-splitter-color); |
| 468 | border-radius: 3px; |
| 469 | } |
| 470 | |
| 471 | .consoletable { |
| 472 | margin: 5px 0 0 0; |
| 473 | } |
| 474 | |
| 475 | .message[severity=error] .stacktrace { |
| 476 | background-color: #000000; |
| 477 | } |
| 478 | |
| 479 | .message[open] .stacktrace { |
| 480 | display: block; |
| 481 | } |
| 482 | |
| 483 | .message .theme-twisty { |
| 484 | display: inline-block; |
| 485 | vertical-align: middle; |
| 486 | margin: 3px 0 0 0; |
| 487 | flex-shrink: 0; |
| 488 | } |
| 489 | |
| 490 | .cm-s-mozilla a[class] { |
| 491 | font-style: italic; |
| 492 | text-decoration: none; |
| 493 | } |
| 494 | |
| 495 | .cm-s-mozilla a[class]:hover, |
| 496 | .cm-s-mozilla a[class]:focus { |
| 497 | text-decoration: underline; |
| 498 | } |
| 499 | |
| 500 | a.learn-more-link.webconsole-learn-more-link { |
| 501 | font-style: normal; |
| 502 | } |
| 503 | |
| 504 | /* Open DOMNode in inspector button */ |
| 505 | .open-inspector { |
| 506 | background: url("chrome://devtools/skin/images/vview-open-inspector.png") no-repeat 0 0; |
| 507 | padding-left: 16px; |
| 508 | margin-inline-start: 5px; |
| 509 | cursor: pointer; |
| 510 | } |
| 511 | |
| 512 | .elementNode:hover .open-inspector, |
| 513 | .open-inspector:hover { |
| 514 | filter: url(images/filters.svg#checked-icon-state); |
| 515 | } |
| 516 | |
| 517 | .open-inspector:active { |
| 518 | filter: url(images/filters.svg#checked-icon-state); |
| 519 | } |
| 520 | |
| 521 | @media (max-width: 500px) { |
| 522 | .message > .timestamp { |
| 523 | display: none; |
| 524 | } |
| 525 | .hud-console-filter-toolbar .webconsole-filter-button .toolbarbutton-text { |
| 526 | display: none; |
| 527 | } |
| 528 | .hud-console-filter-toolbar .webconsole-filter-button { |
| 529 | min-width: 40px; |
| 530 | } |
| 531 | .hud-console-filter-toolbar .webconsole-clear-console-button { |
| 532 | min-width: 25px; |
| 533 | } |
| 534 | .webconsole-filter-button > .toolbarbutton-menubutton-button:before { |
| 535 | width: 12px; |
| 536 | height: 12px; |
| 537 | margin-inline-start: 1px; |
| 538 | } |
| 539 | .toolbarbutton-menubutton-dropmarker { |
| 540 | margin: 0px; |
| 541 | } |
| 542 | } |
| 543 | |
| 544 | @media (max-width: 300px) { |
| 545 | .hud-console-filter-toolbar { |
| 546 | -moz-box-orient: vertical; |
| 547 | } |
| 548 | .toolbarbutton-text { |
| 549 | display: -moz-box; |
| 550 | } |
| 551 | /* |
| 552 | .devtools-toolbarbutton { |
| 553 | margin-top: 3px; |
| 554 | } |
| 555 | .hud-console-filter-toolbar .hud-filter-box, |
| 556 | .hud-console-filter-toolbar .devtools-toolbarbutton { |
| 557 | margin-top: 5px; |
| 558 | } |
| 559 | */ |
| 560 | } |
| 561 | |
| 562 | /* |
| 563 | * This hardcoded width likely due to a toolkit Windows specific bug. |
| 564 | * See http://hg.mozilla.org/mozilla-central/annotate/f38d6df93cad/toolkit/themes/winstripe/global/textbox-aero.css#l7 |
| 565 | */ |
| 566 | |
| 567 | :root[platform="win"] .hud-filter-box { |
| 568 | width: 200px; |
| 569 | } |