@@ -28,7 +28,7 @@ interface ISelectListTemplateData {
2828 root : HTMLElement ;
2929 text : HTMLElement ;
3030 itemDescription : HTMLElement ;
31- decorationRight : HTMLElement ;
31+ decoratorRight : HTMLElement ;
3232 disposables : IDisposable [ ] ;
3333}
3434
@@ -43,7 +43,7 @@ class SelectListRenderer implements IListRenderer<ISelectOptionItem, ISelectList
4343 data . disposables = [ ] ;
4444 data . root = container ;
4545 data . text = dom . append ( container , $ ( '.option-text' ) ) ;
46- data . decorationRight = dom . append ( container , $ ( '.option-decoration -right' ) ) ;
46+ data . decoratorRight = dom . append ( container , $ ( '.option-decorator -right' ) ) ;
4747 data . itemDescription = dom . append ( container , $ ( '.option-text-description' ) ) ;
4848 dom . addClass ( data . itemDescription , 'visually-hidden' ) ;
4949
@@ -53,11 +53,11 @@ class SelectListRenderer implements IListRenderer<ISelectOptionItem, ISelectList
5353 renderElement ( element : ISelectOptionItem , index : number , templateData : ISelectListTemplateData ) : void {
5454 const data = < ISelectListTemplateData > templateData ;
5555 const text = ( < ISelectOptionItem > element ) . text ;
56- const decorationRight = ( < ISelectOptionItem > element ) . decorationRight ;
56+ const decoratorRight = ( < ISelectOptionItem > element ) . decoratorRight ;
5757 const isDisabled = ( < ISelectOptionItem > element ) . isDisabled ;
5858
5959 data . text . textContent = text ;
60- data . decorationRight . innerText = ( ! ! decorationRight ? decorationRight : '' ) ;
60+ data . decoratorRight . innerText = ( ! ! decoratorRight ? decoratorRight : '' ) ;
6161
6262 if ( typeof element . description === 'string' ) {
6363 const itemDescriptionId = ( text . replace ( / / g, '_' ) . toLowerCase ( ) + '_description_' + data . root . id ) ;
@@ -329,6 +329,10 @@ export class SelectBoxList implements ISelectBoxDelegate, IListVirtualDelegate<I
329329 content . push ( `.monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row.focused:not(:hover) { color: ${ this . styles . listFocusForeground } !important; }` ) ;
330330 }
331331
332+ if ( this . styles . decoratorRightForeground ) {
333+ content . push ( `.monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row .option-decorator-right { color: ${ this . styles . decoratorRightForeground } !important; }` ) ;
334+ }
335+
332336 if ( this . styles . selectBackground && this . styles . selectBorder && ! this . styles . selectBorder . equals ( this . styles . selectBackground ) ) {
333337 content . push ( `.monaco-select-box-dropdown-container { border: 1px solid ${ this . styles . selectBorder } } ` ) ;
334338 content . push ( `.monaco-select-box-dropdown-container > .select-box-details-pane.border-top { border-top: 1px solid ${ this . styles . selectBorder } } ` ) ;
@@ -690,15 +694,15 @@ export class SelectBoxList implements ISelectBoxDelegate, IListVirtualDelegate<I
690694 let longestLength = 0 ;
691695
692696 this . options . forEach ( ( option , index ) => {
693- const len = option . text . length + ( ! ! option . decorationRight ? option . decorationRight . length : 0 ) ;
697+ const len = option . text . length + ( ! ! option . decoratorRight ? option . decoratorRight . length : 0 ) ;
694698 if ( len > longestLength ) {
695699 longest = index ;
696700 longestLength = len ;
697701 }
698702 } ) ;
699703
700704
701- container . innerHTML = this . options [ longest ] . text + ( ! ! this . options [ longest ] . decorationRight ? ( this . options [ longest ] . decorationRight + ' ' ) : '' ) ;
705+ container . innerHTML = this . options [ longest ] . text + ( ! ! this . options [ longest ] . decoratorRight ? ( this . options [ longest ] . decoratorRight + ' ' ) : '' ) ;
702706 elementWidth = dom . getTotalWidth ( container ) ;
703707 }
704708
0 commit comments