Skip to content

Commit

Permalink
fix(frontend): set concrete type of cancel ref in generic confirm dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
SundayChen committed Nov 27, 2024
1 parent 7681784 commit 858e3a6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion frontend/src/components/modals/generic-confirm-dialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
AlertDialogCloseButton,
Button,
} from "@chakra-ui/react";
import { FocusableElement } from "@chakra-ui/utils";

interface GenericConfirmDialogProps {
isOpen: boolean;
Expand All @@ -31,7 +32,7 @@ const GenericConfirmDialog: React.FC<GenericConfirmDialogProps> = ({
onOKCallback,
isAlert = true,
}) => {
const cancelRef = useRef();
const cancelRef = useRef<HTMLButtonElement>(null);

return (
<AlertDialog
Expand Down

0 comments on commit 858e3a6

Please sign in to comment.