@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/core-components': patch
|
||||
---
|
||||
|
||||
Added the ability to tail the `LogViewer` logs
|
||||
@@ -39,13 +39,11 @@ export const TaskBorder = ({
|
||||
return <LinearProgress variant="indeterminate" />;
|
||||
}
|
||||
|
||||
if (isError) {
|
||||
return (
|
||||
<LinearProgress variant="determinate" classes={{ bar: styles.failed }} />
|
||||
);
|
||||
}
|
||||
|
||||
return (
|
||||
<LinearProgress variant="determinate" classes={{ bar: styles.success }} />
|
||||
<LinearProgress
|
||||
variant="determinate"
|
||||
classes={{ bar: isError ? styles.failed : styles.success }}
|
||||
value={100}
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
||||
@@ -30,8 +30,12 @@ export const TaskLogStream = (opts: { logs: { [k: string]: string[] } }) => {
|
||||
return (
|
||||
<div className={styles.root}>
|
||||
<LogViewer
|
||||
tail
|
||||
text={Object.values(opts.logs)
|
||||
|
||||
.map(l => l.join('\n'))
|
||||
.filter(Boolean)
|
||||
|
||||
.join('\n')}
|
||||
/>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user