fix: download button open book
This commit is contained in:
@@ -219,7 +219,9 @@ export function BookOfflineButton({ book, className }: BookOfflineButtonProps) {
|
||||
checkStatus();
|
||||
}, [book.id, checkOfflineAvailability, downloadBook, getBookStatus, setBookStatus]);
|
||||
|
||||
const handleToggleOffline = async () => {
|
||||
const handleToggleOffline = async (e: React.MouseEvent) => {
|
||||
e.stopPropagation(); // Empêcher la propagation au parent
|
||||
|
||||
if (!("caches" in window)) {
|
||||
toast({
|
||||
title: "Non supporté",
|
||||
|
||||
Reference in New Issue
Block a user