forked from alibaba/pipcook
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.jsx
26 lines (25 loc) · 763 Bytes
/
index.jsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import React from 'react';
import { Dialog, Tab } from '@alifd/next';
export default function logview({ visible, setVisible, stdout, stderr }) {
return (
<Dialog
title="Log View"
visible={visible}
onOk={setVisible}
onCancel={setVisible}
onClose={setVisible}
>
<div className="dialog-wrap" style={{
height: '500px',
width: '800px',
whiteSpace: 'pre-line',
fontSize: '16px',
}}>
<Tab shape="wrapped">
<Tab.Item title="Log"><div style={{height: '500px', overflow: 'scroll'}}>{stdout}</div></Tab.Item>
<Tab.Item title="Error"><div style={{height: '500px', overflow: 'scroll'}}>{stderr}</div></Tab.Item>
</Tab>
</div>
</Dialog>
);
}