Fix remaining JSONB references

This commit is contained in:
gpt-engineer-app[bot]
2025-11-03 21:36:08 +00:00
parent 22f4a68bd8
commit b5cbc42cdf
6 changed files with 308 additions and 52 deletions

View File

@@ -26,7 +26,11 @@ interface ErrorDetails {
duration_ms: number;
user_id?: string;
request_breadcrumbs?: Breadcrumb[];
environment_context?: Record<string, unknown>;
user_agent?: string;
client_version?: string;
timezone?: string;
referrer?: string;
ip_address_hash?: string;
}
interface ErrorDetailsModalProps {
@@ -173,13 +177,43 @@ ${error.error_stack ? `Stack Trace:\n${error.error_stack}` : ''}
</TabsContent>
<TabsContent value="environment">
{error.environment_context ? (
<pre className="bg-muted p-4 rounded-lg overflow-x-auto text-xs">
{JSON.stringify(error.environment_context, null, 2)}
</pre>
) : (
<p className="text-muted-foreground">No environment context available</p>
)}
<div className="space-y-4">
<div className="grid grid-cols-2 gap-4">
{error.user_agent && (
<div>
<label className="text-sm font-medium">User Agent</label>
<p className="text-xs font-mono break-all">{error.user_agent}</p>
</div>
)}
{error.client_version && (
<div>
<label className="text-sm font-medium">Client Version</label>
<p className="text-sm">{error.client_version}</p>
</div>
)}
{error.timezone && (
<div>
<label className="text-sm font-medium">Timezone</label>
<p className="text-sm">{error.timezone}</p>
</div>
)}
{error.referrer && (
<div>
<label className="text-sm font-medium">Referrer</label>
<p className="text-xs font-mono break-all">{error.referrer}</p>
</div>
)}
{error.ip_address_hash && (
<div>
<label className="text-sm font-medium">IP Hash</label>
<p className="text-xs font-mono">{error.ip_address_hash}</p>
</div>
)}
</div>
{!error.user_agent && !error.client_version && !error.timezone && !error.referrer && !error.ip_address_hash && (
<p className="text-muted-foreground">No environment data available</p>
)}
</div>
</TabsContent>
</Tabs>