Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make the watermark editor labels themable #202228

Merged
merged 1 commit into from
Jan 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions build/lib/stylelint/vscode-known-variables.json
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,7 @@
"--vscode-editorWarning-background",
"--vscode-editorWarning-border",
"--vscode-editorWarning-foreground",
"--vscode-editorWatermark-foreground",
"--vscode-editorWhitespace-foreground",
"--vscode-editorWidget-background",
"--vscode-editorWidget-border",
Expand Down
3 changes: 3 additions & 0 deletions src/vs/workbench/browser/parts/editor/editorGroupWatermark.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ import { KeybindingLabel } from 'vs/base/browser/ui/keybindingLabel/keybindingLa
import { CommandsRegistry } from 'vs/platform/commands/common/commands';
import { ContextKeyExpr, ContextKeyExpression, IContextKeyService } from 'vs/platform/contextkey/common/contextkey';
import { defaultKeybindingLabelStyles } from 'vs/platform/theme/browser/defaultStyles';
import { editorForeground, registerColor, transparent } from 'vs/platform/theme/common/colorRegistry';

registerColor('editorWatermark.foreground', { dark: transparent(editorForeground, 0.6), light: transparent(editorForeground, 0.68), hcDark: editorForeground, hcLight: editorForeground }, localize('editorLineHighlight', 'Foreground color for the labels in the editor watermark.'));

interface WatermarkEntry {
readonly text: string;
Expand Down
22 changes: 1 addition & 21 deletions src/vs/workbench/browser/parts/editor/media/editorgroupview.css
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@
display: table-row;
opacity: .8;
cursor: default;
color: var(--vscode-editorWatermark-foreground);
}

.monaco-workbench .part.editor > .content .editor-group-container > .editor-group-watermark > .shortcuts dt {
Expand All @@ -104,27 +105,6 @@
vertical-align: middle;
}

.monaco-workbench .part.editor > .content .editor-group-container > .editor-group-watermark > .shortcuts dt,
.monaco-workbench .part.editor > .content .editor-group-container > .editor-group-watermark > .shortcuts dl {
color: rgba(0,0,0,.68);
}

.monaco-workbench.vs-dark .part.editor > .content .editor-group-container .editor-group-watermark > .shortcuts dt,
.monaco-workbench.vs-dark .part.editor > .content .editor-group-container .editor-group-watermark > .shortcuts dl {
color: rgba(255,255,255,.6);
}

.monaco-workbench.hc-black .part.editor > .content .editor-group-container .editor-group-watermark > .shortcuts dt,
.monaco-workbench.hc-light .part.editor > .content .editor-group-container .editor-group-watermark > .shortcuts dt {
color: var(--vscode-editor-foreground);
}
.monaco-workbench.hc-black .part.editor > .content .editor-group-container .editor-group-watermark > .shortcuts dl,
.monaco-workbench.hc-light .part.editor > .content .editor-group-container .editor-group-watermark > .shortcuts dl {
color: var(--vscode-editor-foreground);
opacity: 1;
}


/* Title */

.monaco-workbench .part.editor > .content .editor-group-container > .title {
Expand Down