Rename .monaco-editor-hover to .monaco-hover

This commit is contained in:
Alex Dima
2020-05-14 21:37:23 +02:00
parent 12628f1e2b
commit 88bcf236cf
7 changed files with 51 additions and 51 deletions

View File

@@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
.monaco-editor-hover {
.monaco-hover {
cursor: default;
position: absolute;
overflow: hidden;
@@ -16,34 +16,34 @@
line-height: 1.5em;
}
.monaco-editor-hover.hidden {
.monaco-hover.hidden {
display: none;
}
.monaco-editor-hover .hover-contents {
.monaco-hover .hover-contents {
padding: 4px 8px;
}
.monaco-editor-hover .markdown-hover > .hover-contents:not(.code-hover-contents) {
.monaco-hover .markdown-hover > .hover-contents:not(.code-hover-contents) {
max-width: 500px;
word-wrap: break-word;
}
.monaco-editor-hover .markdown-hover > .hover-contents:not(.code-hover-contents) hr {
.monaco-hover .markdown-hover > .hover-contents:not(.code-hover-contents) hr {
/* This is a strange rule but it avoids https://github.com/microsoft/vscode/issues/96795, just 100vw on its own caused the actual hover width to increase */
min-width: calc(100% + 100vw);
}
.monaco-editor-hover p,
.monaco-editor-hover ul {
.monaco-hover p,
.monaco-hover ul {
margin: 8px 0;
}
.monaco-editor-hover code {
.monaco-hover code {
font-family: var(--monaco-monospace-font);
}
.monaco-editor-hover hr {
.monaco-hover hr {
margin-top: 4px;
margin-bottom: -6px;
margin-left: -10px;
@@ -51,78 +51,78 @@
height: 1px;
}
.monaco-editor-hover p:first-child,
.monaco-editor-hover ul:first-child {
.monaco-hover p:first-child,
.monaco-hover ul:first-child {
margin-top: 0;
}
.monaco-editor-hover p:last-child,
.monaco-editor-hover ul:last-child {
.monaco-hover p:last-child,
.monaco-hover ul:last-child {
margin-bottom: 0;
}
/* MarkupContent Layout */
.monaco-editor-hover ul {
.monaco-hover ul {
padding-left: 20px;
}
.monaco-editor-hover ol {
.monaco-hover ol {
padding-left: 20px;
}
.monaco-editor-hover li > p {
.monaco-hover li > p {
margin-bottom: 0;
}
.monaco-editor-hover li > ul {
.monaco-hover li > ul {
margin-top: 0;
}
.monaco-editor-hover code {
.monaco-hover code {
border-radius: 3px;
padding: 0 0.4em;
}
.monaco-editor-hover .monaco-tokenized-source {
.monaco-hover .monaco-tokenized-source {
white-space: pre-wrap;
word-break: break-all;
}
.monaco-editor-hover .hover-row.status-bar {
.monaco-hover .hover-row.status-bar {
font-size: 12px;
line-height: 22px;
}
.monaco-editor-hover .hover-row.status-bar .actions {
.monaco-hover .hover-row.status-bar .actions {
display: flex;
padding: 0px 8px;
}
.monaco-editor-hover .hover-row.status-bar .actions .action-container {
.monaco-hover .hover-row.status-bar .actions .action-container {
margin-right: 16px;
cursor: pointer;
}
.monaco-editor-hover .hover-row.status-bar .actions .action-container .action .icon {
.monaco-hover .hover-row.status-bar .actions .action-container .action .icon {
padding-right: 4px;
}
.monaco-editor-hover .markdown-hover .hover-contents .codicon {
.monaco-hover .markdown-hover .hover-contents .codicon {
color: inherit;
font-size: inherit;
vertical-align: middle;
}
.monaco-editor-hover .hover-contents a.code-link:before {
.monaco-hover .hover-contents a.code-link:before {
content: '(';
}
.monaco-editor-hover .hover-contents a.code-link:after {
.monaco-hover .hover-contents a.code-link:after {
content: ')';
}
.monaco-editor-hover .hover-contents a.code-link {
.monaco-hover .hover-contents a.code-link {
color: inherit;
}
.monaco-editor-hover .hover-contents a.code-link > span {
.monaco-hover .hover-contents a.code-link > span {
text-decoration: underline;
/** Hack to force underline to show **/
border-bottom: 1px solid transparent;

View File

@@ -20,12 +20,12 @@ export class HoverWidget extends Disposable {
super();
this.containerDomNode = document.createElement('div');
this.containerDomNode.classList.add('terminal-hover-widget', 'fadeIn', 'monaco-editor-hover', 'xterm-hover');
this.containerDomNode.classList.add('terminal-hover-widget', 'fadeIn', 'monaco-hover', 'xterm-hover');
this.containerDomNode.tabIndex = 0;
this.containerDomNode.setAttribute('role', 'tooltip');
this.contentsDomNode = document.createElement('div');
this.contentsDomNode.className = 'monaco-editor-hover-content';
this.contentsDomNode.className = 'monaco-hover-content';
this._scrollbar = this._register(new DomScrollableElement(this.contentsDomNode, {}));
this.containerDomNode.appendChild(this._scrollbar.getDomNode());