Skip to content

A reactive notebook for Python — run reproducible experiments, query with SQL, execute as a script, deploy as an app, and version with git. Stored as pure Python. All in a modern, AI-native editor.

add alert dialog description for accessibility (#7242)

Shahmir Varqha6e9696fc84a6
diff --git a/frontend/src/plugins/impl/common/error-banner.tsx b/frontend/src/plugins/impl/common/error-banner.tsx
index 6fe027c8c9..4a51ee536a 100644
--- a/frontend/src/plugins/impl/common/error-banner.tsx
+++ b/frontend/src/plugins/impl/common/error-banner.tsx
@@ -6,6 +6,7 @@ import {
AlertDialog,
AlertDialogAction,
AlertDialogContent,
+ AlertDialogDescription,
AlertDialogFooter,
AlertDialogHeader,
AlertDialogTitle,
@@ -48,9 +49,12 @@ export const ErrorBanner = ({
<AlertDialogHeader>
<AlertDialogTitle className="text-error">Error</AlertDialogTitle>
</AlertDialogHeader>
- <pre className="text-error text-sm p-2 font-mono overflow-auto whitespace-pre-wrap">
- {message}
- </pre>
+ <AlertDialogDescription
+ asChild={true}
+ className="text-error text-sm p-2 font-mono overflow-auto whitespace-pre-wrap"
+ >
+ <pre>{message}</pre>
+ </AlertDialogDescription>
<AlertDialogFooter>
<AlertDialogAction autoFocus={true} onClick={() => setOpen(false)}>
Ok