Skip to content

Commit 26bf10d

Browse files
author
Benjamin Pasero
committed
Theme: inconsistency for text field inside extensions sidebar (fixes microsoft#26798)
1 parent e0a8ca5 commit 26bf10d

5 files changed

Lines changed: 14 additions & 29 deletions

File tree

src/vs/base/browser/ui/progressbar/progressbar.css

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -51,14 +51,6 @@
5151
-moz-animation-timing-function: linear;
5252
}
5353

54-
.progress-container.infinite.done .progress-bit {
55-
transition: opacity 200ms linear;
56-
-webkit-transition: opacity 200ms linear;
57-
-o-transition: opacity 200ms linear;
58-
-moz-transition: opacity 200ms linear;
59-
-ms-transition: opacity 200ms linear;
60-
}
61-
6254
@keyframes progress { from { left: 0; width: 2%; } 50% { left: 50%; width: 5%; } to { left: 98%; width: 2%; } }
6355
@-ms-keyframes progress { from { left: 0; width: 2%; } 50% { left: 50%; width: 5%; } to { left: 98%; width: 2%; } }
6456
@-webkit-keyframes progress { from { left: 0; width: 2%; } 50% { left: 50%; width: 5%; } to { left: 98%; width: 2%; } }

src/vs/editor/contrib/referenceSearch/browser/referencesWidget.css

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -61,12 +61,6 @@
6161
line-height: 22px;
6262
}
6363

64-
.monaco-editor .reference-zone-widget .ref-tree .reference-file .directory {
65-
opacity: 0.7;
66-
margin-left: 0.5em;
67-
font-size: 0.9em;
68-
}
69-
7064
.monaco-editor .reference-zone-widget .monaco-count-badge {
7165
margin-right: 12px;
7266
}
@@ -96,8 +90,4 @@
9690
.monaco-editor.hc-black .reference-zone-widget .ref-tree .reference-file {
9791
line-height: 20px;
9892
font-weight: bold;
99-
}
100-
101-
.monaco-editor.hc-black .reference-zone-widget .ref-tree .reference-file .directory {
102-
font-weight: normal;
10393
}

src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ import { LeftRightWidget } from 'vs/base/browser/ui/leftRightWidget/leftRightWid
2727
import * as tree from 'vs/base/parts/tree/browser/tree';
2828
import { DefaultController, LegacyRenderer } from 'vs/base/parts/tree/browser/treeDefaults';
2929
import { Tree } from 'vs/base/parts/tree/browser/treeImpl';
30-
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
30+
import { IInstantiationService, optional } from 'vs/platform/instantiation/common/instantiation';
3131
import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection';
3232
import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace';
3333
import { Range, IRange } from 'vs/editor/common/core/range';
@@ -43,6 +43,7 @@ import { registerThemingParticipant, ITheme, IThemeService } from 'vs/platform/t
4343
import { attachListStyler, attachBadgeStyler } from 'vs/platform/theme/common/styler';
4444
import { IModelDecorationsChangedEvent } from 'vs/editor/common/model/textModelEvents';
4545
import { IEditorOptions } from 'vs/editor/common/config/editorOptions';
46+
import { IEnvironmentService } from "vs/platform/environment/common/environment";
4647

4748
class DecorationsManager implements IDisposable {
4849

@@ -345,15 +346,18 @@ class Controller extends DefaultController {
345346
class Renderer extends LegacyRenderer {
346347
private _contextService: IWorkspaceContextService;
347348
private _themeService: IThemeService;
349+
private _environmentService: IEnvironmentService;
348350

349351
constructor(
350352
@IWorkspaceContextService contextService: IWorkspaceContextService,
351-
@IThemeService themeService: IThemeService
353+
@IThemeService themeService: IThemeService,
354+
@optional(IEnvironmentService) environmentService: IEnvironmentService
352355
) {
353356
super();
354357

355358
this._contextService = contextService;
356359
this._themeService = themeService;
360+
this._environmentService = environmentService;
357361
}
358362

359363
public getHeight(tree: tree.ITree, element: any): number {
@@ -371,7 +375,7 @@ class Renderer extends LegacyRenderer {
371375
/* tslint:disable:no-unused-expression */
372376
new LeftRightWidget(fileReferencesContainer, (left: HTMLElement) => {
373377

374-
const label = new FileLabel(left, element.uri, this._contextService);
378+
const label = new FileLabel(left, element.uri, this._contextService, this._environmentService);
375379
toDispose.push(label);
376380
return <IDisposable>null;
377381

src/vs/editor/contrib/rename/browser/renameInputField.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import { TPromise } from 'vs/base/common/winjs.base';
1313
import { Range } from 'vs/editor/common/core/range';
1414
import { ContentWidgetPositionPreference, ICodeEditor, IContentWidget, IContentWidgetPosition } from 'vs/editor/browser/editorBrowser';
1515
import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService';
16-
import { inputBackground, inputBorder, inputForeground, widgetShadow, focusBorder } from 'vs/platform/theme/common/colorRegistry';
16+
import { inputBackground, inputBorder, inputForeground, widgetShadow } from 'vs/platform/theme/common/colorRegistry';
1717
import { Position } from 'vs/editor/common/core/position';
1818

1919
export default class RenameInputField implements IContentWidget, IDisposable {
@@ -79,7 +79,7 @@ export default class RenameInputField implements IContentWidget, IDisposable {
7979
const background = theme.getColor(inputBackground);
8080
const foreground = theme.getColor(inputForeground);
8181
const widgetShadowColor = theme.getColor(widgetShadow);
82-
const border = theme.getColor(inputBorder) || theme.getColor(focusBorder);
82+
const border = theme.getColor(inputBorder);
8383

8484
this._inputField.style.backgroundColor = background ? background.toString() : null;
8585
this._inputField.style.color = foreground ? foreground.toString() : null;

src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.ts

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ import { IActivityBarService, ProgressBadge, NumberBadge } from 'vs/workbench/se
5050
import { IExtensionService } from 'vs/platform/extensions/common/extensions';
5151
import { IModeService } from 'vs/editor/common/services/modeService';
5252
import { IThemeService } from 'vs/platform/theme/common/themeService';
53-
import { inputForeground, inputBackground, contrastBorder } from 'vs/platform/theme/common/colorRegistry';
53+
import { inputForeground, inputBackground, inputBorder } from 'vs/platform/theme/common/colorRegistry';
5454
import { attachListStyler } from 'vs/platform/theme/common/styler';
5555

5656
interface SearchInputEvent extends Event {
@@ -146,14 +146,13 @@ export class ExtensionsViewlet extends Viewlet implements IExtensionsViewlet {
146146
public updateStyles(): void {
147147
super.updateStyles();
148148

149-
const contrastBorderColor = this.getColor(contrastBorder);
150-
151149
this.searchBox.style.backgroundColor = this.getColor(inputBackground);
152150
this.searchBox.style.color = this.getColor(inputForeground);
153151

154-
this.searchBox.style.borderWidth = contrastBorderColor ? '1px' : null;
155-
this.searchBox.style.borderStyle = contrastBorderColor ? 'solid' : null;
156-
this.searchBox.style.borderColor = contrastBorderColor;
152+
const inputBorderColor = this.getColor(inputBorder);
153+
this.searchBox.style.borderWidth = inputBorderColor ? '1px' : null;
154+
this.searchBox.style.borderStyle = inputBorderColor ? 'solid' : null;
155+
this.searchBox.style.borderColor = inputBorderColor;
157156
}
158157

159158
setVisible(visible: boolean): TPromise<void> {

0 commit comments

Comments
 (0)