From 68a9f59a52d7a6806f2f47683d534d2d904bd8f1 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sat, 4 Apr 2026 02:33:29 +0000 Subject: [PATCH 1/2] Initial plan From e5d7a0a298e1ca9bdd2073cf7dff9ed781b76242 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sat, 4 Apr 2026 02:38:35 +0000 Subject: [PATCH 2/2] Show 'Update Pending...' on index button click for immediate feedback Agent-Logs-Url: https://github.com/lstein/PhotoMapAI/sessions/ff42af47-37d2-4efd-bdcd-47c33bdd1547 Co-authored-by: lstein <111189+lstein@users.noreply.github.com> --- photomap/frontend/static/javascript/album-manager.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/photomap/frontend/static/javascript/album-manager.js b/photomap/frontend/static/javascript/album-manager.js index 3021918a..71502afb 100644 --- a/photomap/frontend/static/javascript/album-manager.js +++ b/photomap/frontend/static/javascript/album-manager.js @@ -976,6 +976,12 @@ export class AlbumManager { return; } + // Provide immediate feedback while the indexing request is being processed + const createBtn = cardElement.querySelector(".create-index-btn"); + const originalBtnText = createBtn.textContent; + createBtn.textContent = "Update Pending..."; + createBtn.disabled = true; + // Backend guard: check if indexing is already running try { const response = await fetch(`index_progress/${albumKey}`); @@ -1003,12 +1009,16 @@ export class AlbumManager { ` Please remove the index file manually and try again.` + ` The path for the index file is: ${album.index}` ); + createBtn.textContent = originalBtnText; + createBtn.disabled = false; await this.handleIndexingCompletion(albumKey, cardElement); return; } } const progress = await updateIndex(albumKey); if (!progress) { + createBtn.textContent = originalBtnText; + createBtn.disabled = false; return; } this.showProgressUIWithoutScroll(cardElement, progress);