diff --git a/frontend/src/lib/locationMapUtils.js b/frontend/src/lib/locationMapUtils.js index 5309905..cb82917 100644 --- a/frontend/src/lib/locationMapUtils.js +++ b/frontend/src/lib/locationMapUtils.js @@ -47,7 +47,7 @@ export function getMapStatus(state, options = {}) { if (options.hasUnsavedChanges) return "Unsaved Draft"; if (!state?.draft_map && !state?.published_map) return "No Map"; if (options.mode === "edit") return "Draft"; - if (options.mode === "view" && options.previewDraft && state?.draft_map) return "Draft Preview"; + if (options.mode === "view" && options.previewDraft && state?.draft_map) return "Viewing Draft"; if (state?.published_map) return "Published"; if (state?.draft_map) return "Draft"; return "No Map"; diff --git a/frontend/src/styles/pages/LocationMapManager.css b/frontend/src/styles/pages/LocationMapManager.css index 173b361..091d3e8 100644 --- a/frontend/src/styles/pages/LocationMapManager.css +++ b/frontend/src/styles/pages/LocationMapManager.css @@ -85,7 +85,7 @@ border-color: rgba(245, 158, 11, 0.36); } -.location-map-status-draft-preview { +.location-map-status-viewing-draft { background: rgba(14, 165, 233, 0.2); border-color: rgba(56, 189, 248, 0.4); } diff --git a/frontend/tests/location-map-manager.spec.ts b/frontend/tests/location-map-manager.spec.ts index 4cc14fe..82d1054 100644 --- a/frontend/tests/location-map-manager.spec.ts +++ b/frontend/tests/location-map-manager.spec.ts @@ -1221,7 +1221,7 @@ test("admin status follows the visible map when a saved draft exists", async ({ await expect(page.locator(".location-map-object", { hasText: "Draft Bakery" })).toBeVisible(); await page.getByRole("button", { name: "View Draft" }).click(); - await expect(page.locator(".location-map-status")).toHaveText("Draft Preview"); + await expect(page.locator(".location-map-status")).toHaveText("Viewing Draft"); await expect(page.locator(".location-map-object", { hasText: "Draft Bakery" })).toBeVisible(); await page.getByRole("button", { name: "View" }).click(); @@ -1344,7 +1344,7 @@ test("mode switches close open map layers without resetting filters", async ({ p await expect(page.locator(".location-map-display-panel")).toHaveCount(0); }); -test("mobile keeps draft preview status compact in the topbar", async ({ page }) => { +test("mobile keeps viewing draft status compact in the topbar", async ({ page }) => { await page.setViewportSize({ width: 409, height: 838 }); await mockMapShell(page); @@ -1397,7 +1397,7 @@ test("mobile keeps draft preview status compact in the topbar", async ({ page }) const modeButtons = page.locator(".location-map-mode-buttons"); const historyActions = page.locator(".location-map-history-buttons"); const zoomControls = page.locator(".location-map-zoom-controls"); - await expect(status).toHaveText("Draft Preview"); + await expect(status).toHaveText("Viewing Draft"); const topbarBox = await topbar.boundingBox(); const backButtonBox = await backButton.boundingBox();