mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-27 16:37:33 +01:00
fix logbox color
This commit is contained in:
parent
f0a004e75b
commit
39df55cfe5
@ -134,16 +134,16 @@ function LogWindow(props: IProps): React.ReactElement {
|
||||
}
|
||||
|
||||
function lineClass(s: string): string {
|
||||
if (s.match(/\[[^\]]+\] ERROR/) || s.match(/\[[^\]]+\] FAIL/)) {
|
||||
if (s.match(/(^\[[^\]]+\] )?ERROR/) || s.match(/(^\[[^\]]+\] )?FAIL/)) {
|
||||
return classes.error;
|
||||
}
|
||||
if (s.match(/\[[^\]]+\] SUCCESS/)) {
|
||||
if (s.match(/(^\[[^\]]+\] )?SUCCESS/)) {
|
||||
return classes.success;
|
||||
}
|
||||
if (s.match(/\[[^\]]+\] WARN/)) {
|
||||
if (s.match(/(^\[[^\]]+\] )?WARN/)) {
|
||||
return classes.warning;
|
||||
}
|
||||
if (s.match(/\[[^\]]+\] INFO/)) {
|
||||
if (s.match(/(^\[[^\]]+\] )?INFO/)) {
|
||||
return classes.info;
|
||||
}
|
||||
return classes.primary;
|
||||
|
Loading…
Reference in New Issue
Block a user