File tree Expand file tree Collapse file tree 1 file changed +18
-1
lines changed
src/client/components/display Expand file tree Collapse file tree 1 file changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -19,12 +19,29 @@ const ResponseEventsDisplay = ({ response }) => {
1919 < div className = "okay" dangerouslySetInnerHTML = { { __html : createDOMPurify . sanitize ( events [ 0 ] ) } } />
2020 )
2121 }
22+ else if ( events . length > 1 ) {
23+ if ( events ) {
24+ displayContents . push (
25+ < div className = "json-response" key = "jsonresponsediv" >
26+ < JSONPretty data = { events } space = "4" theme = { {
27+ main : 'line-height:1.3; color: midnightblue; background:#RRGGBB; overflow:auto;' ,
28+ key : 'color:#0089D0;' , // bluetwo
29+ string : 'color:#15B78F;' , // greenone
30+ value : 'color:#fd971f;' , // a nice orange
31+ boolean : 'color:#E00198;' , // gqlpink
32+ } }
33+ />
34+ </ div >
35+ ) ;
36+ }
37+
38+ }
2239 // Otherwise, render a single display
2340 else {
2441 if ( events ) {
2542 displayContents . push (
2643 < div className = "json-response" key = "jsonresponsediv" >
27- < JSONPretty data = { events } space = "4" theme = { {
44+ < JSONPretty data = { events [ 0 ] } space = "4" theme = { {
2845 main : 'line-height:1.3; color: midnightblue; background:#RRGGBB; overflow:auto;' ,
2946 key : 'color:#0089D0;' , // bluetwo
3047 string : 'color:#15B78F;' , // greenone
You can’t perform that action at this time.
0 commit comments