From 910ef297a1d5bd89e467ed2256e8736edc14b543 Mon Sep 17 00:00:00 2001 From: mkarolin Date: Tue, 28 Sep 2021 14:12:57 -0400 Subject: [PATCH 1/2] Hide idle detection UI elements in Settings. Fixes brave/brave-browser#18409 --- browser/resources/settings/brave_overrides/privacy_page.js | 6 ++++++ browser/resources/settings/brave_overrides/site_details.js | 6 ++++++ .../settings/brave_overrides/site_settings_page.js | 6 ++++++ 3 files changed, 18 insertions(+) diff --git a/browser/resources/settings/brave_overrides/privacy_page.js b/browser/resources/settings/brave_overrides/privacy_page.js index ba268b9987f3..d8b54321a4f0 100644 --- a/browser/resources/settings/brave_overrides/privacy_page.js +++ b/browser/resources/settings/brave_overrides/privacy_page.js @@ -12,6 +12,12 @@ RegisterPolymerTemplateModifications({ if (!pages) { console.error(`[Brave Settings Overrides] Couldn't find privacy_page #pages`) } else { + const idleDetection = templateContent.querySelector('[route-path="/content/idleDetection"]') + if (!idleDetection) { + console.error(`[Brave Settings Overrides] Couldn't find idle detection template`) + } else { + idleDetection.content.firstElementChild.hidden = true + } pages.insertAdjacentHTML('beforeend', `