File tree Expand file tree Collapse file tree 2 files changed +5
-10
lines changed
arduino-ide-extension/src Expand file tree Collapse file tree 2 files changed +5
-10
lines changed Original file line number Diff line number Diff line change @@ -7,8 +7,6 @@ import { inject, injectable } from '@theia/core/shared/inversify';
77import PQueue from 'p-queue' ;
88import {
99 BoardIdentifier ,
10- // Produces Error: src/browser/contributions/boards-data-menu-updater.ts(10,3): error TS6133: 'ConfigOption' is declared but its value is never read.
11- // ConfigOption,
1210 isBoardIdentifierChangeEvent ,
1311 Programmer ,
1412} from '../../common/protocol' ;
@@ -72,8 +70,11 @@ export class BoardsDataMenuUpdater extends Contribution {
7270 ...ArduinoMenus . TOOLS__BOARD_SETTINGS_GROUP ,
7371 'z01_boardsConfig' ,
7472 ] ; // `z_` is for ordering.
75- for ( const { label, option, values } of configOptions ) {
76- const menuPath = [ ...boardsConfigMenuPath , `${ option } ` ] ;
73+ let i :number = 0 ;
74+ for ( const { label, option, values } of configOptions ) {
75+ // We want Menu Entries in order of configOptions
76+ const order = String ( i ++ ) . padStart ( 4 )
77+ const menuPath = [ ...boardsConfigMenuPath , `${ order } ` ] ;
7778 const commands = new Map <
7879 string ,
7980 Disposable & { label : string }
Original file line number Diff line number Diff line change @@ -377,12 +377,6 @@ export namespace ConfigOption {
377377 Object . setPrototypeOf ( this , ConfigOptionError . prototype ) ;
378378 }
379379 }
380-
381- export const LABEL_COMPARATOR = ( left : ConfigOption , right : ConfigOption ) =>
382- naturalCompare (
383- left . label . toLocaleLowerCase ( ) ,
384- right . label . toLocaleLowerCase ( )
385- ) ;
386380}
387381
388382export interface ConfigValue {
You can’t perform that action at this time.
0 commit comments