diff --git a/src/components/PushReminderDialog.tsx b/src/components/PushReminderDialog.tsx index b6cf48b6..90c3fda6 100644 --- a/src/components/PushReminderDialog.tsx +++ b/src/components/PushReminderDialog.tsx @@ -12,7 +12,6 @@ import { Checkbox } from '@/components/ui/checkbox'; import { Label } from '@/components/ui/label'; import { GitBranch, Upload, AlertTriangle, X } from 'lucide-react'; import { useGitStatus } from '@/hooks/useGitStatus'; -import { useNavigate } from 'react-router-dom'; import { GitDialog } from '@/components/GitDialog'; interface PushReminderDialogProps { @@ -33,7 +32,6 @@ export function PushReminderDialog({ const [dontShowAgain, setDontShowAgain] = useState(false); const [isGitDialogOpen, setIsGitDialogOpen] = useState(false); const { data: gitStatus } = useGitStatus(projectId); - const navigate = useNavigate(); // Close the reminder dialog when git dialog opens useEffect(() => { @@ -63,7 +61,7 @@ export function PushReminderDialog({ if (dontShowAgain) { onDisableReminders(); } - + if (hasNoRemote) { // Close reminder dialog and open git dialog onOpenChange(false); diff --git a/src/components/PushWarningButton.tsx b/src/components/PushWarningButton.tsx index cbd63cbb..af4dfcb9 100644 --- a/src/components/PushWarningButton.tsx +++ b/src/components/PushWarningButton.tsx @@ -4,7 +4,6 @@ import { GitDialog } from '@/components/GitDialog'; import { AlertTriangle, Upload, GitBranch } from 'lucide-react'; import { cn } from '@/lib/utils'; import { useGitStatus } from '@/hooks/useGitStatus'; -import { useNavigate } from 'react-router-dom'; import { Tooltip, TooltipContent, @@ -18,14 +17,13 @@ interface PushWarningButtonProps { variant?: 'icon' | 'full'; } -export function PushWarningButton({ - projectId, +export function PushWarningButton({ + projectId, className, - variant = 'icon' + variant = 'icon' }: PushWarningButtonProps) { const [isGitDialogOpen, setIsGitDialogOpen] = useState(false); const { data: gitStatus } = useGitStatus(projectId); - const navigate = useNavigate(); if (!gitStatus?.isGitRepo) { return null;