feat(web): replace JSONViewer with react-json-tree

This commit is contained in:
Ali BARIN
2022-04-17 20:03:09 +02:00
committed by Ömer Faruk Aydın
parent 6e4d61f9b1
commit b65fa88f16
4 changed files with 74 additions and 59 deletions

View File

@@ -1,5 +1,6 @@
import * as React from 'react';
import { useMutation } from '@apollo/client';
import Box from '@mui/material/Box';
import Collapse from '@mui/material/Collapse';
import ListItem from '@mui/material/ListItem';
import Button from '@mui/material/Button';
@@ -59,7 +60,9 @@ function TestSubstep(props: TestSubstepProps): React.ReactElement {
<ListItem sx={{ pt: 2, pb: 3, flexDirection: 'column', alignItems: 'flex-start' }}>
{response && (
<JSONViewer data={response} />
<Box sx={{ maxHeight: 400, overflowY: 'auto', width: '100%' }}>
<JSONViewer data={response} />
</Box>
)}
<Button