iconlabel.css 2.4 KB
Newer Older
1 2 3 4 5 6 7 8
/*---------------------------------------------------------------------------------------------
 *  Copyright (c) Microsoft Corporation. All rights reserved.
 *  Licensed under the MIT License. See License.txt in the project root for license information.
 *--------------------------------------------------------------------------------------------*/

/* ---------- Icon label ---------- */

.monaco-icon-label {
9
	display: flex; /* required for icons support :before rule */
10 11
	overflow: hidden;
	text-overflow: ellipsis;
12 13 14 15 16 17 18 19 20 21 22
}

.monaco-icon-label::before {

	/* svg icons rendered as background image */
	background-size: 16px;
	background-position: left center;
	background-repeat: no-repeat;
	padding-right: 6px;
	width: 16px;
	height: 22px;
M
Miguel Solorio 已提交
23
	line-height: inherit !important;
24 25 26 27 28
	display: inline-block;

	/* fonts icons */
	-webkit-font-smoothing: antialiased;
	vertical-align: top;
29 30 31 32 33 34 35

	flex-shrink: 0; /* fix for https://github.com/Microsoft/vscode/issues/13787 */
}

.monaco-icon-label > .monaco-icon-label-description-container {
	overflow: hidden; /* this causes the label/description to shrink first if decorations are enabled */
	text-overflow: ellipsis;
36 37
}

38
.monaco-icon-label > .monaco-icon-label-description-container > .label-name {
39
	color: inherit;
B
Benjamin Pasero 已提交
40
	white-space: pre; /* enable to show labels that include multiple whitespaces */
41 42
}

43
.monaco-icon-label > .monaco-icon-label-description-container > .label-description {
44
	opacity: .7;
45 46
	margin-left: 0.5em;
	font-size: 0.9em;
B
Benjamin Pasero 已提交
47
	white-space: pre; /* enable to show labels that include multiple whitespaces */
48 49
}

50 51
.monaco-icon-label.italic > .monaco-icon-label-description-container > .label-name,
.monaco-icon-label.italic > .monaco-icon-label-description-container > .label-description {
52
	font-style: italic;
53 54
}

55 56
.monaco-icon-label::after {
	opacity: 0.75;
57
	font-size: 90%;
58
	font-weight: 600;
59
	padding: 0 16px 0 5px;
J
Johannes Rieken 已提交
60 61
	margin-left: auto;
	text-align: center;
62
}
63

J
Johannes Rieken 已提交
64 65 66
/* make sure selection color wins when a label is being selected */
.monaco-tree.focused .selected .monaco-icon-label, /* tree */
.monaco-tree.focused .selected .monaco-icon-label::after,
67 68
.monaco-list:focus .selected .monaco-icon-label, /* list */
.monaco-list:focus .selected .monaco-icon-label::after
69 70 71
{
	color: inherit !important;
}
72 73 74 75 76 77

.monaco-tree-row.focused.selected .label-description,
.monaco-tree-row.selected .label-description,
.monaco-list-row.focused.selected .label-description,
.monaco-list-row.selected .label-description {
	opacity: .8;
M
Miguel Solorio 已提交
78
}