Skip to content

Commit

Permalink
final commit
Browse files Browse the repository at this point in the history
  • Loading branch information
thegravity98 committed Jan 13, 2023
0 parents commit b1e2cad
Show file tree
Hide file tree
Showing 4 changed files with 60 additions and 0 deletions.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<h2>Remove theme-color</h2>

<h4>Hey 👋</h4>

Are you sick of websites that have garish colors? Get rid of the clutter and enjoy a cleaner, distraction-free browsing experience with Remove Theme Color! This Chrome extension (complies with manifest v3) automatically identifies and removes meta name=theme-color from websites, giving you a simple, elegant look with no extra effort.

With this extension, you won't have to worry about being distracted by bright and loud colors on any website you visit. So why not try it out today? Install the Chrome extension now for a faster, cleaner online journey! You can use it in <a href = "https://play.google.com/store/apps/details?id=com.kiwibrowser.browser">Kiwi Browser</a> on Android.

1. Download the .zip file <a href = "https://github.com/thegravity98/Remove-Theme-Color/releases">From where?</a>
2. load it in your browser. <a href = "https://developer.chrome.com/docs/extensions/mv3/getstarted/development-basics/#load-unpacked">But how?</a>

Made with ❤️ by thegravity98.
28 changes: 28 additions & 0 deletions contentscripts.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
setTimeout(() => {
var interval;
var mtc = document.querySelector("meta[name=theme-color]");
let themecolor;

if (mtc === null) {
console.log("theme-color absent");
}
else {
console.log("theme-color present");
interval = setInterval(() => {
var mtc_fix = document.querySelector("meta[name=theme-color]");
if (mtc_fix === null) {
return;
}
else {
themecolor = mtc_fix.getAttribute("content");
console.log("Website theme-color: " + themecolor);
mtc_fix.remove();
console.log("Element was removed");
}
}, 100);
}

setTimeout(() => {
clearInterval(interval);
}, 4500);
}, 0);
Binary file added icon 128.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 20 additions & 0 deletions manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"manifest_version": 3,
"name": "Remove theme-color",
"description": "Remove <meta name=theme-color> from all websites",
"version": "13.1.2023",
"icons": {
"128": "icon 128.png"
},
"content_scripts": [
{
"matches": [
"<all_urls>"
],
"js": [
"contentscripts.js"
],
"run_at": "document_start"
}
]
}

0 comments on commit b1e2cad

Please sign in to comment.