mirror of
https://github.com/R0m1k3/TodoFlow.git
synced 2026-10-19 05:08:43 +02:00
fix: pause widget polling while editing a task to prevent focus loss
This commit is contained in:
1 parent
3e6dbb5c76
commit
e4a56f2fc6
2 files changed
+11
-1
No files matched your search
@@ -176,6 +176,11 @@ async function saveSettings() {
|
||||
// --- APPELS API (CRUD) ---
|
||||
|
||||
async function fetchTasks() {
|
||||
// Suspendre la synchronisation si l'utilisateur est en train d'éditer une tâche pour éviter de perdre le focus et fermer l'édition
|
||||
if (document.querySelector(".task-card.editing")) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Récupération asynchrone des tâches avec la clé API
|
||||
try {
|
||||
const response = await fetch(`${state.apiUrl}/api/v1/tasks`, {
|
||||
|
||||
Reference in new issue
Block a user