提交 d1dc19b6 编写于 作者: M Martin Aeschlimann

[theme] externalize more hover colors

上级 bd688945
......@@ -60,7 +60,6 @@
}
.monaco-editor-hover code {
background-color: rgba(132, 132, 132, 0.14);
border-radius: 3px;
padding: 0 0.4em;
}
......@@ -68,7 +67,4 @@
.monaco-editor-hover .monaco-tokenized-source {
white-space: pre-wrap;
word-break: break-all;
}
.monaco-editor.vs-dark .monaco-editor-hover a { color: #1C5DAF; }
.monaco-editor.hc-black .monaco-editor-hover a { color: #1C5DAF; }
\ No newline at end of file
}
\ No newline at end of file
......@@ -21,7 +21,7 @@ import { ModesContentHoverWidget } from './modesContentHover';
import { ModesGlyphHoverWidget } from './modesGlyphHover';
import { IDisposable, dispose } from 'vs/base/common/lifecycle';
import { registerThemingParticipant } from 'vs/platform/theme/common/themeService';
import { editorHoverHighlight, editorHoverBackground, editorHoverBorder } from 'vs/platform/theme/common/colorRegistry';
import { editorHoverHighlight, editorHoverBackground, editorHoverBorder, textLinkForeground, textCodeBlockBackground } from 'vs/platform/theme/common/colorRegistry';
import { EditorContextKeys } from 'vs/editor/common/editorContextKeys';
@editorContribution
......@@ -187,4 +187,13 @@ registerThemingParticipant((theme, collector) => {
collector.addRule(`.monaco-editor .monaco-editor-hover { border: 1px solid ${hoverBorder}; }`);
collector.addRule(`.monaco-editor .monaco-editor-hover .hover-row:not(:first-child):not(:empty) { border-top: 1px solid ${hoverBorder.transparent(0.5)}; }`);
}
let link = theme.getColor(textLinkForeground);
if (link) {
collector.addRule(`.monaco-editor .monaco-editor-hover a { color: ${link}; }`);
}
let codeBackground = theme.getColor(textCodeBlockBackground);
if (codeBackground) {
collector.addRule(`.monaco-editor .monaco-editor-hover code { background-color: ${codeBackground}; }`);
}
});
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册