Skip to content

armgit / E2B

Public Imported from GitHub
0

Open-source, secure environment with real-world tools for enterprise-grade agents.

Fix json inspector styling

Tomas Valentaf5789d127d2b
diff --git a/components/AgentContextDetail.tsx b/components/AgentContextDetail.tsx
index dcf9c54e3..014a5321a 100644
--- a/components/AgentContextDetail.tsx
+++ b/components/AgentContextDetail.tsx
@@ -31,10 +31,16 @@ function AgentContextDetail({
) : (
<ReactJson
src={JSON.parse(context.content)}
- theme="pop"
name={null}
- displayDataTypes={false}
+ style={{
+ background: 'transparent'
+ }}
displayObjectSize={false}
+ quotesOnKeys={false}
+ sortKeys={true}
+ displayDataTypes={false}
+ theme="ocean"
+ enableClipboard={false}
/>
)}
</div>
@@ -47,17 +53,24 @@ function AgentContextDetail({
...(context as any).function_call,
'arguments': JSON.parse((context as any).function_call.arguments),
}}
- theme="pop"
name={null}
- displayDataTypes={false}
+ style={{
+ background: 'transparent'
+ }}
displayObjectSize={false}
+ quotesOnKeys={false}
+ sortKeys={true}
+ displayDataTypes={false}
+ theme="ocean"
+ enableClipboard={false}
/>
</>
)}
</>
- )}
+ )
+ }
- </div>
+ </div >
)
}
diff --git a/components/AgentFunctions.tsx b/components/AgentFunctions.tsx
index 8da9d91bd..ca105a716 100644
--- a/components/AgentFunctions.tsx
+++ b/components/AgentFunctions.tsx
@@ -109,11 +109,19 @@ function AgentFunctions({
{fn.parameters && (
<div className="flex flex-col space-y-1 w-full">
<span className="text-sm font-bold text-gray-400">Parameters</span>
- <div className="rounded-md border border-gray-500 overflow-hidden p-2">
+ <div className="rounded-md overflow-hidden p-2">
<ReactJson
src={fn.parameters}
- theme="pop"
name={null}
+ style={{
+ background: 'transparent'
+ }}
+ displayObjectSize={false}
+ quotesOnKeys={false}
+ sortKeys={true}
+ displayDataTypes={false}
+ theme="ocean"
+ enableClipboard={false}
/>
</div>
</div>