diff --git a/apps/browser/src/phishing-detection/content/phishing-detection-browser.service.ts b/apps/browser/src/phishing-detection/content/phishing-detection-browser.service.ts index 714f3e3f9b2..724515f4ed6 100644 --- a/apps/browser/src/phishing-detection/content/phishing-detection-browser.service.ts +++ b/apps/browser/src/phishing-detection/content/phishing-detection-browser.service.ts @@ -27,6 +27,12 @@ export class PhishingDetectionBrowserService { exitButton.id = "change-exit"; exitButton.classList.add("primary"); exitButton.textContent = "Exit the page"; + exitButton.onclick = () => { + const barEl = document.getElementById(phishingDivId); + if (barEl != null) { + barEl.parentElement.removeChild(barEl); + } + }; wrapper.appendChild(messageElement); wrapper.appendChild(exitButton);