diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index e337fa74..e2ff43fe 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -430,6 +430,7 @@ jobs: CHROMIUM_REQUIRE=1 BASE_URL=http://localhost:13581 node test-channels-ws-race-1498-e2e.js 2>&1 | tee -a e2e-output.txt CHROMIUM_REQUIRE=1 BASE_URL=http://localhost:13581 node test-issue-1487-byop-modal-layout-e2e.js 2>&1 | tee -a e2e-output.txt CHROMIUM_REQUIRE=1 BASE_URL=http://localhost:13581 node test-issue-1630-reach-mobile-e2e.js 2>&1 | tee -a e2e-output.txt + CHROMIUM_REQUIRE=1 BASE_URL=http://localhost:13581 node test-issue-1640-compare-discovery-e2e.js 2>&1 | tee -a e2e-output.txt # #1616: slide-over focus-restore flake-gate. Runs the slide-over # E2E 20 consecutive times against the SAME backend instance so diff --git a/public/compare.js b/public/compare.js index e92575ab..d929abcf 100644 --- a/public/compare.js +++ b/public/compare.js @@ -101,10 +101,11 @@ if (typeof window !== 'undefined') { routeFilter = 'all'; app.innerHTML = '
' + - ''; @@ -196,6 +197,7 @@ if (typeof window !== 'undefined') { selA = ddA.value || null; selB = ddB.value || null; btn.disabled = !selA || !selB || selA === selB; + renderBreadcrumbs(); } ddA.addEventListener('change', updateBtn); ddB.addEventListener('change', updateBtn); @@ -203,6 +205,34 @@ if (typeof window !== 'undefined') { updateBtn(); } + // #1640 — render breadcrumbs linking back to each observer's detail page. + // Hidden when neither observer is picked; otherwise: + // "Observers › " + // The "‎" entities keep punctuation LTR in RTL contexts. + function renderBreadcrumbs() { + var el = document.querySelector('[data-role="compare-breadcrumbs"]'); + if (!el) return; + function linkFor(id) { + if (!id) return null; + var match = null; + for (var i = 0; i < observers.length; i++) { + if (String(observers[i].id) === String(id)) { match = observers[i]; break; } + } + var label = match ? (match.name || match.id) : id; + return '' + escapeHtml(label) + ''; + } + var parts = ['Observers']; + var aLink = linkFor(selA); + var bLink = linkFor(selB); + if (aLink || bLink) { + var pair = []; + if (aLink) pair.push(aLink); + if (bLink) pair.push(bLink); + parts.push(pair.join(' ')); + } + el.innerHTML = parts.join(' '); + } + function sinceISO(hours) { return new Date(Date.now() - hours * 3600000).toISOString(); } diff --git a/public/observer-detail.js b/public/observer-detail.js index de9d1d7b..9412c5c1 100644 --- a/public/observer-detail.js +++ b/public/observer-detail.js @@ -86,7 +86,19 @@ window.ObserverDetailNaiveBanner = {