File tree Expand file tree Collapse file tree 2 files changed +12
-10
lines changed
src/vs/editor/contrib/codeAction/browser Expand file tree Collapse file tree 2 files changed +12
-10
lines changed Original file line number Diff line number Diff line change @@ -90,7 +90,7 @@ export interface ICodeActionMenuTemplateData {
90
90
}
91
91
92
92
const TEMPLATE_ID = 'codeActionWidget' ;
93
- const codeActionLineHeight = 27 ;
93
+ const codeActionLineHeight = 26 ;
94
94
95
95
class CodeMenuRenderer implements IListRenderer < ICodeActionMenuItem , ICodeActionMenuTemplateData > {
96
96
get templateId ( ) : string { return TEMPLATE_ID ; }
@@ -222,6 +222,8 @@ export class CodeActionMenu extends Disposable implements IEditorContribution {
222
222
) ;
223
223
224
224
renderDisposables . add ( this . codeActionList . value . onDidChangeSelection ( e => this . _onListSelection ( e ) ) ) ;
225
+ renderDisposables . add ( this . _editor . onDidLayoutChange ( e => this . hideCodeActionWidget ( ) ) ) ;
226
+
225
227
226
228
// Populating the list widget and tracking enabled options.
227
229
inputArray . forEach ( ( item , index ) => {
@@ -257,7 +259,7 @@ export class CodeActionMenu extends Disposable implements IEditorContribution {
257
259
const maxWidth = Math . max ( ...arr ) ;
258
260
259
261
// 40 is the additional padding for the list widget (20 left, 20 right)
260
- renderMenu . style . width = maxWidth + 40 + 'px' ;
262
+ renderMenu . style . width = maxWidth + 52 + 'px' ;
261
263
this . codeActionList . value ?. layout ( height , maxWidth ) ;
262
264
263
265
// List selection
Original file line number Diff line number Diff line change 4
4
*--------------------------------------------------------------------------------------------*/
5
5
6
6
.codeActionMenuWidget {
7
- padding : 10 px 0px 10 px 0px ;
7
+ padding : 8 px 0px 8 px 0px ;
8
8
overflow : auto;
9
9
font-size : 13px ;
10
10
border-radius : 5px ;
14
14
/* flex-direction: column;
15
15
flex: 0 1 auto; */
16
16
width : 100% ;
17
- border-style : solid ;
18
- border-width : 1 px ;
19
- border -color: var (--vscode-editorSuggestWidget-border );
20
- background- color: var (--vscode-editorSuggestWidget-background );
17
+ border-width : 0 px ;
18
+ border-color : none ;
19
+ background -color: var (--vscode-menu-background );
20
+ color : var (--vscode-menu-foreground );
21
21
}
22
22
23
23
.codeActionMenuWidget .monaco-list : not (.element-focused ): focus : before {
41
41
-ms-user-select : none;
42
42
border : none !important ;
43
43
border-width : 0px !important ;
44
- color : var (red) !important ;
45
44
}
46
45
47
46
/* .codeActionMenuWidget .monaco-list:not(.element-focus) {
62
61
display : flex;
63
62
-mox-box-sizing : border-box;
64
63
box-sizing : border-box;
65
- padding : 0px 20 px 0px 20 px ;
64
+ padding : 0px 26 px 0px 26 px ;
66
65
background-repeat : no-repeat;
67
66
background-position : 2px 2px ;
68
67
white-space : nowrap;
74
73
75
74
.codeActionMenuWidget .monaco-list .monaco-list-row : hover : not (.option-disabled ),
76
75
.codeActionMenuWidget .monaco-list .moncao-list-row .focused : not (.option-disabled ) {
76
+ color : var (--vscode-menu-selectionForeground ) !important ;
77
77
background-color : var (--vscode-menu-selectionBackground ) !important ;
78
78
}
79
79
86
86
-moz-user-select : none;
87
87
-ms-user-select : none;
88
88
user-select : none;
89
- color : var (--vscode-list-inactiveSelectionBackground ) !important ;
89
+ color : var (--vscode-disabledForeground ) !important ;
90
90
}
91
91
92
92
.codeActionMenuWidget .monaco-list .separator {
You can’t perform that action at this time.
0 commit comments