import { useState } from 'react'; import { Button } from '@/components/ui/button'; import { Pencil, X, CheckSquare, Trash2 } from 'lucide-react'; import { cn } from '@/lib/utils'; import { Dialog, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogTitle, } from '@/components/ui/dialog'; interface SelectionActionBarProps { selectedCount: number; totalCount: number; onEdit: () => void; onDelete: () => void; onClear: () => void; onSelectAll: () => void; } export function SelectionActionBar({ selectedCount, totalCount, onEdit, onDelete, onClear, onSelectAll, }: SelectionActionBarProps) { const [showDeleteDialog, setShowDeleteDialog] = useState(false); if (selectedCount === 0) return null; const allSelected = selectedCount === totalCount; const handleDeleteClick = () => { setShowDeleteDialog(true); }; const handleConfirmDelete = () => { setShowDeleteDialog(false); onDelete(); }; return ( <>