55
66import Severity from 'vs/base/common/severity' ;
77import { registerThemingParticipant , ITheme , LIGHT } from 'vs/platform/theme/common/themeService' ;
8- import { editorErrorForeground , editorWarningForeground , editorInfoForeground , editorHintForeground } from 'vs/platform/theme/common/colorRegistry' ;
98import { Color } from 'vs/base/common/color' ;
109
1110const errorStart = encodeURIComponent ( `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" enable-background="new 0 0 16 16" height="16" width="16"><circle cx="8" cy="8" r="6" fill="#F6F6F6"/><path d="M8 3C5.238 3 3 5.238 3 8s2.238 5 5 5 5-2.238 5-5-2.238-5-5-5zm3 7l-1 1-2-2-2 2-1-1 2-2.027L5 6l1-1 2 2 2-2 1 1-2 1.973L11 10z" fill="` ) ;
@@ -28,19 +27,19 @@ export namespace SeverityIcon {
2827 export function getSVGData ( severity : Severity , theme : ITheme ) : string {
2928 switch ( severity ) {
3029 case Severity . Ignore :
31- const ignoreColor = theme . getColor ( editorHintForeground ) || ( theme . type === LIGHT ? Color . fromHex ( '#1BA1E2' ) : Color . fromHex ( '#1BA1E2' ) ) ;
30+ const ignoreColor = theme . type === LIGHT ? Color . fromHex ( '#1BA1E2' ) : Color . fromHex ( '#1BA1E2' ) ;
3231 return theme . type === LIGHT ? infoStart + encodeURIComponent ( ignoreColor . toString ( ) ) + infoEnd
3332 : infoDarkStart + encodeURIComponent ( ignoreColor . toString ( ) ) + infoDarkEnd ;
3433 case Severity . Info :
35- const infoColor = theme . getColor ( editorInfoForeground ) || ( theme . type === LIGHT ? Color . fromHex ( '#1BA1E2' ) : Color . fromHex ( '#1BA1E2' ) ) ;
34+ const infoColor = theme . type === LIGHT ? Color . fromHex ( '#1BA1E2' ) : Color . fromHex ( '#1BA1E2' ) ;
3635 return theme . type === LIGHT ? infoStart + encodeURIComponent ( infoColor . toString ( ) ) + infoEnd
3736 : infoDarkStart + encodeURIComponent ( infoColor . toString ( ) ) + infoDarkEnd ;
3837 case Severity . Warning :
39- const warningColor = theme . getColor ( editorWarningForeground ) || ( theme . type === LIGHT ? Color . fromHex ( '#fc0' ) : Color . fromHex ( '#fc0' ) ) ;
38+ const warningColor = theme . type === LIGHT ? Color . fromHex ( '#fc0' ) : Color . fromHex ( '#fc0' ) ;
4039 return theme . type === LIGHT ? warningStart + encodeURIComponent ( warningColor . toString ( ) ) + warningEnd
4140 : warningDarkStart + encodeURIComponent ( warningColor . toString ( ) ) + warningDarkEnd ;
4241 case Severity . Error :
43- const errorColor = theme . getColor ( editorErrorForeground ) || ( theme . type === LIGHT ? Color . fromHex ( '#E51400' ) : Color . fromHex ( '#F48771' ) ) ;
42+ const errorColor = theme . type === LIGHT ? Color . fromHex ( '#E51400' ) : Color . fromHex ( '#F48771' ) ;
4443 return theme . type === LIGHT ? errorStart + encodeURIComponent ( errorColor . toString ( ) ) + errorEnd
4544 : errorDarkStart + encodeURIComponent ( errorColor . toString ( ) ) + errorDarkEnd ;
4645 }
0 commit comments