Skip to content

Commit

Permalink
[IM] Use EuiCodeBlock to render index mapping (elastic#60420)
Browse files Browse the repository at this point in the history
  • Loading branch information
alisonelizabeth authored and cjcenizal committed Mar 17, 2020
1 parent 6582ff4 commit 8d91fb9
Showing 1 changed file with 2 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/

import React from 'react';
import { EuiCodeEditor } from '@elastic/eui';
import { EuiCodeBlock } from '@elastic/eui';

import 'brace/theme/textmate';

Expand All @@ -25,17 +25,6 @@ export class ShowJson extends React.PureComponent {
return null;
}
const json = JSON.stringify(data, null, 2);
return (
<EuiCodeEditor
mode="json"
theme="textmate"
isReadOnly
setOptions={{ maxLines: Infinity }}
value={json}
editorProps={{
$blockScrolling: Infinity,
}}
/>
);
return <EuiCodeBlock lang="json">{json}</EuiCodeBlock>;
}
}

0 comments on commit 8d91fb9

Please sign in to comment.