Skip to content

Commit 90a0606

Browse files
restore custom board selector variables
1 parent 1150a41 commit 90a0606

File tree

2 files changed

+82
-16
lines changed

2 files changed

+82
-16
lines changed

arduino-ide-extension/src/browser/arduino-frontend-contribution.tsx

+68
Original file line numberDiff line numberDiff line change
@@ -232,6 +232,74 @@ export class ArduinoFrontendContribution
232232
},
233233
description:
234234
'Toggle color of the toolbar items when they are currently toggled (the command is in progress)',
235+
},
236+
{
237+
id: 'arduino.toolbar.dropdown.border',
238+
defaults: {
239+
dark: 'dropdown.border',
240+
light: 'dropdown.border',
241+
hc: 'dropdown.border',
242+
},
243+
description: 'Border color of the Board Selector.',
244+
},
245+
246+
{
247+
id: 'arduino.toolbar.dropdown.borderActive',
248+
defaults: {
249+
dark: 'focusBorder',
250+
light: 'focusBorder',
251+
hc: 'focusBorder',
252+
},
253+
description: "Border color of the Board Selector when it's active",
254+
},
255+
256+
{
257+
id: 'arduino.toolbar.dropdown.background',
258+
defaults: {
259+
dark: 'tab.unfocusedActiveBackground',
260+
light: 'dropdown.background',
261+
hc: 'dropdown.background',
262+
},
263+
description: 'Background color of the Board Selector.',
264+
},
265+
266+
{
267+
id: 'arduino.toolbar.dropdown.label',
268+
defaults: {
269+
dark: 'dropdown.foreground',
270+
light: 'dropdown.foreground',
271+
hc: 'dropdown.foreground',
272+
},
273+
description: 'Font color of the Board Selector.',
274+
},
275+
{
276+
id: 'arduino.toolbar.dropdown.iconSelected',
277+
defaults: {
278+
dark: 'list.activeSelectionIconForeground',
279+
light: 'list.activeSelectionIconForeground',
280+
hc: 'list.activeSelectionIconForeground',
281+
},
282+
description:
283+
'Color of the selected protocol icon in the Board Selector.',
284+
},
285+
{
286+
id: 'arduino.toolbar.dropdown.option.backgroundHover',
287+
defaults: {
288+
dark: 'list.hoverBackground',
289+
light: 'list.hoverBackground',
290+
hc: 'list.hoverBackground',
291+
},
292+
description: 'Background color on hover of the Board Selector options.',
293+
},
294+
{
295+
id: 'arduino.toolbar.dropdown.option.backgroundSelected',
296+
defaults: {
297+
dark: 'list.activeSelectionBackground',
298+
light: 'list.activeSelectionBackground',
299+
hc: 'list.activeSelectionBackground',
300+
},
301+
description:
302+
'Background color of the selected board in the Board Selector.',
235303
}
236304
);
237305
}

arduino-ide-extension/src/browser/style/boards-config-dialog.css

+14-16
Original file line numberDiff line numberDiff line change
@@ -145,9 +145,9 @@ div#select-board-dialog .selectBoardContainer .body .list .item.selected i {
145145

146146
.arduino-boards-toolbar-item-container {
147147
align-items: center;
148-
background: var(--theia-dropdown-background);
148+
background: var(--theia-arduino-toolbar-dropdown-background);
149149
border-radius: 1px;
150-
color: var(--theia-dropdown-foreground);
150+
color: var(--theia-arduino-toolbar-dropdown-label);
151151
border: 1px solid var(--theia-dropdown-border);
152152
display: flex;
153153
gap: 10px;
@@ -167,7 +167,7 @@ div#select-board-dialog .selectBoardContainer .body .list .item.selected i {
167167

168168
.arduino-boards-toolbar-item--protocol ,
169169
.arduino-boards-dropdown-item--protocol {
170-
color: var(--theia-dropdown-foreground);
170+
color: var(--theia-arduino-toolbar-dropdown-label);
171171
}
172172

173173
.arduino-boards-toolbar-item-container
@@ -196,28 +196,26 @@ div#select-board-dialog .selectBoardContainer .body .list .item.selected i {
196196
.arduino-boards-dropdown-list {
197197
margin: -1px;
198198
z-index: 1;
199-
border: 1px solid var(--theia-dropdown-border);
199+
border: 1px solid var(--theia-arduino-toolbar-dropdown-border);
200200
}
201201

202202
.arduino-boards-dropdown-list:focus {
203-
border-style: solid;
204-
border-width: 1px;
205-
border-color: var(--theia-focus-border);
203+
border: 1px solid var(--theia-arduino-toolbar-dropdown-borderActive);
206204
}
207205

208206
.arduino-boards-dropdown-list--items-container {
209207
overflow: auto;
210208
max-height: 404px;
211-
background: var(--theia-dropdown-background);
209+
background: var(--theia-arduino-toolbar-dropdown-background);
212210
}
213211

214212
.arduino-boards-dropdown-list--items-container::-webkit-scrollbar {
215-
background: var(--theia-list-activeSelectionBackground);
213+
background: var(--theia-arduino-toolbar-dropdown-background);
216214
}
217215

218216
.arduino-boards-dropdown-item {
219-
background: var(--theia-dropdown-background);
220-
color: var(--theia-dropdown-foreground);
217+
background: var(--theia-arduino-toolbar-dropdown-background);
218+
color: var(--theia-arduino-toolbar-dropdown-label);
221219
cursor: default;
222220
display: flex;
223221
font-size: var(--theia-ui-font-size1);
@@ -239,22 +237,22 @@ div#select-board-dialog .selectBoardContainer .body .list .item.selected i {
239237
}
240238

241239
.arduino-boards-dropdown-item:hover {
242-
background: var(--theia-list-hoverBackground);
240+
background: var(--theia-arduino-toolbar-dropdown-option-backgroundHover);
243241
}
244242

245243
.arduino-boards-dropdown-item--selected,
246244
.arduino-boards-dropdown-item--selected:hover {
247-
background: var(--theia-list-activeSelectionBackground);
248-
border: 1px solid var(--theia-list-activeSelectionBackground);
245+
background: var(--theia-arduino-toolbar-dropdown-option-backgroundSelected);
246+
border: 1px solid var(--theia-arduino-toolbar-dropdown-option-backgroundSelected);
249247
}
250248

251249
.arduino-boards-dropdown-item--selected
252250
.arduino-boards-dropdown-item--port-label {
253-
color: var(--theia-list-activeSelectionForeground);
251+
color: var(--theia-arduino-toolbar-dropdown-label);
254252
}
255253

256254
.arduino-boards-dropdown-item--selected .fa {
257-
color: var(--theia-list-activeSelectionIconForeground);
255+
color: var(--theia-arduino-toolbar-dropdown-iconSelected);
258256
}
259257

260258
.arduino-boards-dropdown-item .fa-check {

0 commit comments

Comments
 (0)