From c886b1d89dda047fbd853f523ca4d1385795b6e7 Mon Sep 17 00:00:00 2001 From: Valdo Ryu Date: Fri, 22 Nov 2024 12:34:44 +0100 Subject: [PATCH] feat(Carousels): :sparkles: Add hide carousel feature (#65) * feat(Carousels): :sparkles: Add hide carousel feature * fix(Carousels): :bug: Fix chrome storage default label --------- Co-authored-by: Valdo Ryu --- content/content.js | 2 ++ popup/popup.html | 8 ++++++++ service_worker.js | 1 + 3 files changed, 11 insertions(+) diff --git a/content/content.js b/content/content.js index 48b851f..a0da3f4 100644 --- a/content/content.js +++ b/content/content.js @@ -289,6 +289,8 @@ function getKeywords(res) { keywords.push('href="https://www.linkedin.com/company/') if (res['hide-by-people']) keywords.push('href="https://www.linkedin.com/in/') if (res['hide-suggested']) keywords.push('Suggested') + if (res['hide-carousels']) keywords.push('iframe') + console.log('LinkOff: Current keywords are', keywords) return keywords } diff --git a/popup/popup.html b/popup/popup.html index 8ef748a..18521ec 100644 --- a/popup/popup.html +++ b/popup/popup.html @@ -103,6 +103,14 @@

Link Off

+
+ + +
diff --git a/service_worker.js b/service_worker.js index b9ebda1..1c73cff 100644 --- a/service_worker.js +++ b/service_worker.js @@ -34,6 +34,7 @@ chrome.runtime.onInstalled.addListener((details) => { 'hide-other-reactions': false, 'main-toggle': true, 'sort-by-recent': true, + 'hide-carousels': false, }) }) }