Diff
Modified: trunk/Source/WebInspectorUI/ChangeLog (191398 => 191399)
--- trunk/Source/WebInspectorUI/ChangeLog 2015-10-21 20:04:12 UTC (rev 191398)
+++ trunk/Source/WebInspectorUI/ChangeLog 2015-10-21 20:07:33 UTC (rev 191399)
@@ -1,3 +1,46 @@
+2015-10-21 Joseph Pecoraro <pecor...@apple.com>
+
+ Web Inspector: Use some CSS Variables in Web Inspector
+ https://bugs.webkit.org/show_bug.cgi?id=150405
+
+ Reviewed by Timothy Hatcher.
+
+ * UserInterface/Main.html:
+ Include the new variables stylesheet.
+
+ * UserInterface/Views/Variables.css: Added.
+ (:root):
+ Introduce new global variables.
+
+ * UserInterface/Views/CSSStyleDeclarationTextEditor.css:
+ (.css-style-text-editor > .CodeMirror .cm-link):
+ * UserInterface/Views/ConsoleMessageView.css:
+ (.console-message-preview-divider):
+ (.console-message-enclosed):
+ (.console-message .console-message-extra-parameters-container > li::before):
+ (.console-saved-variable):
+ * UserInterface/Views/DOMTreeOutline.css:
+ (.dom-tree-outline li.selected > span::after):
+ * UserInterface/Views/FormattedValue.css:
+ (:matches(.formatted-array, .formatted-map, .formatted-set, .formatted-weakmap, .formatted-weakset) > .size):
+ (.formatted-number):
+ (.formatted-boolean):
+ (.formatted-string):
+ (.formatted-regexp):
+ (.formatted-symbol):
+ * UserInterface/Views/ObjectPreviewView.css:
+ (.object-preview > .size):
+ * UserInterface/Views/ObjectTreeArrayIndexTreeElement.css:
+ (.object-tree-array-index .index-name):
+ * UserInterface/Views/SyntaxHighlightingDefaultTheme.css:
+ (.syntax-highlighted :matches(.css-keyword, .css-tag, .css-at-rule, .css-important, ._javascript_-keyword, .html-tag)):
+ (.syntax-highlighted :matches(.css-number, ._javascript_-number)):
+ (.syntax-highlighted :matches(.css-string, ._javascript_-string, .html-attribute-value)):
+ (.syntax-highlighted ._javascript_-regexp):
+ * UserInterface/Views/TypeTokenView.css:
+ (.type-token-symbol):
+ Make use of variables.
+
2015-10-21 Nikita Vasilyev <nvasil...@apple.com>
Web Inspector: Typo in a property name: style.inerhited
Modified: trunk/Source/WebInspectorUI/UserInterface/Main.html (191398 => 191399)
--- trunk/Source/WebInspectorUI/UserInterface/Main.html 2015-10-21 20:04:12 UTC (rev 191398)
+++ trunk/Source/WebInspectorUI/UserInterface/Main.html 2015-10-21 20:07:33 UTC (rev 191399)
@@ -163,6 +163,7 @@
<link rel="stylesheet" href=""
<link rel="stylesheet" href=""
<link rel="stylesheet" href=""
+ <link rel="stylesheet" href=""
<link rel="stylesheet" href=""
<link rel="stylesheet" href=""
<link rel="stylesheet" href=""
Modified: trunk/Source/WebInspectorUI/UserInterface/Views/CSSStyleDeclarationTextEditor.css (191398 => 191399)
--- trunk/Source/WebInspectorUI/UserInterface/Views/CSSStyleDeclarationTextEditor.css 2015-10-21 20:04:12 UTC (rev 191398)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/CSSStyleDeclarationTextEditor.css 2015-10-21 20:07:33 UTC (rev 191399)
@@ -204,7 +204,7 @@
.css-style-text-editor > .CodeMirror .cm-link {
/* Style url(...) links as if they are strings. */
- color: hsl(1, 79%, 42%);
+ color: var(--syntax-highlight-string-color);
text-decoration: inherit;
cursor: inherit;
}
Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.css (191398 => 191399)
--- trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.css 2015-10-21 20:04:12 UTC (rev 191398)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.css 2015-10-21 20:07:33 UTC (rev 191399)
@@ -94,13 +94,13 @@
}
.console-message-preview-divider {
- color: hsla(0, 0%, 0%, 0.33);
+ color: var(--console-secondary-text-color);
}
.console-message-enclosed {
font-family: Menlo, monospace;
font-size: 11px;
- color: hsla(0, 0%, 0%, 0.33);
+ color: var(--console-secondary-text-color);
}
.console-message .console-message-extra-parameters-container,
@@ -142,7 +142,7 @@
font-family: -apple-system, sans-serif;
font-size: 11px;
- color: hsla(0, 0%, 0%, 0.33);
+ color: var(--console-secondary-text-color);
vertical-align: top;
}
@@ -215,7 +215,7 @@
.console-saved-variable {
font-style: normal;
- color: hsla(0, 0%, 0%, 0.33);
+ color: var(--console-secondary-text-color);
}
.console-user-command,
Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.css (191398 => 191399)
--- trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.css 2015-10-21 20:04:12 UTC (rev 191398)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.css 2015-10-21 20:07:33 UTC (rev 191399)
@@ -70,7 +70,7 @@
.dom-tree-outline li.selected > span::after {
content: " = $0";
- color: hsla(0, 0%, 0%, 0.33);
+ color: var(--console-secondary-text-color);
position: absolute;
white-space: pre;
}
Modified: trunk/Source/WebInspectorUI/UserInterface/Views/FormattedValue.css (191398 => 191399)
--- trunk/Source/WebInspectorUI/UserInterface/Views/FormattedValue.css 2015-10-21 20:04:12 UTC (rev 191398)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/FormattedValue.css 2015-10-21 20:07:33 UTC (rev 191399)
@@ -31,15 +31,15 @@
:matches(.formatted-array, .formatted-map, .formatted-set, .formatted-weakmap, .formatted-weakset) > .size {
font-style: normal;
- color: hsla(0, 0%, 0%, 0.33);
+ color: var(--console-secondary-text-color);
}
.formatted-number {
- color: hsl(248, 100%, 40%);
+ color: var(--syntax-highlight-number-color);
}
.formatted-boolean {
- color: hsl(309, 85%, 35%);
+ color: var(--syntax-highlight-boolean-color);
}
.formatted-string, .formatted-regexp {
@@ -47,15 +47,15 @@
}
.formatted-string {
- color: hsl(1, 79%, 42%);
+ color: var(--syntax-highlight-string-color);
}
.formatted-regexp {
- color: hsl(20, 100%, 44%);
+ color: var(--syntax-highlight-regexp-color);
}
.formatted-symbol {
- color: hsl(172, 45%, 45%);
+ color: var(--syntax-highlight-symbol-color);
}
.formatted-null, .formatted-undefined {
Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ObjectPreviewView.css (191398 => 191399)
--- trunk/Source/WebInspectorUI/UserInterface/Views/ObjectPreviewView.css 2015-10-21 20:04:12 UTC (rev 191398)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/ObjectPreviewView.css 2015-10-21 20:07:33 UTC (rev 191399)
@@ -41,5 +41,5 @@
.object-preview > .size {
font-style: normal;
- color: hsla(0, 0%, 0%, 0.33);
+ color: var(--console-secondary-text-color);
}
Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ObjectTreeArrayIndexTreeElement.css (191398 => 191399)
--- trunk/Source/WebInspectorUI/UserInterface/Views/ObjectTreeArrayIndexTreeElement.css 2015-10-21 20:04:12 UTC (rev 191398)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/ObjectTreeArrayIndexTreeElement.css 2015-10-21 20:07:33 UTC (rev 191399)
@@ -39,7 +39,7 @@
font-family: -apple-system-monospaced-numbers, sans-serif;
font-size: 11px;
vertical-align: top;
- color: hsla(0, 0%, 0%, 0.33);
+ color: var(--console-secondary-text-color);
position:relative;
top: -1px;
Modified: trunk/Source/WebInspectorUI/UserInterface/Views/SyntaxHighlightingDefaultTheme.css (191398 => 191399)
--- trunk/Source/WebInspectorUI/UserInterface/Views/SyntaxHighlightingDefaultTheme.css 2015-10-21 20:04:12 UTC (rev 191398)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/SyntaxHighlightingDefaultTheme.css 2015-10-21 20:07:33 UTC (rev 191399)
@@ -41,12 +41,12 @@
.cm-s-default :matches(.cm-tag, .cm-bracket, .cm-atom, .cm-keyword, .cm-m-_javascript_.cm-builtin),
.cm-s-default .cm-m-css:matches(.cm-atom, .cm-meta, .cm-variable-3, .cm-property),
.syntax-highlighted :matches(.css-keyword, .css-tag, .css-at-rule, .css-important, ._javascript_-keyword, .html-tag) {
- color: hsl(309, 85%, 35%);
+ color: var(--syntax-highlight-boolean-color);
}
.cm-s-default :matches(.cm-number, .cm-atom.cm-hex-color),
.syntax-highlighted :matches(.css-number, ._javascript_-number) {
- color: hsl(248, 100%, 40%);
+ color: var(--syntax-highlight-number-color);
}
.cm-s-default :matches(.cm-def, .cm-operator, .cm-variable, .cm-variable-2),
@@ -57,12 +57,12 @@
.cm-s-default .cm-string,
.syntax-highlighted :matches(.css-string, ._javascript_-string, .html-attribute-value) {
- color: hsl(1, 79%, 42%);
+ color: var(--syntax-highlight-string-color);
}
.cm-s-default .cm-string-2,
.syntax-highlighted ._javascript_-regexp {
- color: hsl(20, 100%, 44%);
+ color: var(--syntax-highlight-regexp-color);
}
.cm-s-default .cm-m-xml.cm-meta,
Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TypeTokenView.css (191398 => 191399)
--- trunk/Source/WebInspectorUI/UserInterface/Views/TypeTokenView.css 2015-10-21 20:04:12 UTC (rev 191398)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/TypeTokenView.css 2015-10-21 20:07:33 UTC (rev 191399)
@@ -56,7 +56,7 @@
}
.type-token-symbol {
- background-color: hsl(172, 45%, 45%);
+ background-color: var(--syntax-highlight-symbol-color);
}
.type-token-default {
Copied: trunk/Source/WebInspectorUI/UserInterface/Views/Variables.css (from rev 191398, trunk/Source/WebInspectorUI/UserInterface/Views/ObjectPreviewView.css) (0 => 191399)
--- trunk/Source/WebInspectorUI/UserInterface/Views/Variables.css (rev 0)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/Variables.css 2015-10-21 20:07:33 UTC (rev 191399)
@@ -0,0 +1,34 @@
+/*
+ * Copyright (C) 2015 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+:root {
+ --console-secondary-text-color: hsla(0, 0%, 0%, 0.33);
+
+ --syntax-highlight-number-color: hsl(248, 100%, 40%);
+ --syntax-highlight-boolean-color: hsl(309, 85%, 35%);
+ --syntax-highlight-string-color: hsl(1, 79%, 42%);
+ --syntax-highlight-regexp-color: hsl(20, 100%, 44%);
+ --syntax-highlight-symbol-color: hsl(172, 45%, 45%);
+}