Skip to content

Commit

Permalink
More Tab Cloaking Options.
Browse files Browse the repository at this point in the history
  • Loading branch information
xbubbo committed Sep 14, 2023
1 parent a146f24 commit 549c5f0
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 0 deletions.
4 changes: 4 additions & 0 deletions routes/settings.html
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,10 @@ <h3>Tab Cloaker</h3>
<option value="Classroom">Google Classroom</option>
<option value="Google">Google</option>
<option value="Drive">Google Drive</option>
<option value="Clever">Clever</option>
<option value="Schoology">Schoology</option>
<option value="Gmail">Gmail</option>
<option value="Khan">Khan Academy</option>
</select>
<input class="key-form" type="text" id="icon" placeholder="Change Tab Icon" name="icon">
<input class="key-form" type="text" id="name" name="name" placeholder="Change Tab Name">
Expand Down
Binary file added static/images/favicon/schoology.ico
Binary file not shown.
24 changes: 24 additions & 0 deletions static/scripts/customIcon.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,30 @@ document.addEventListener("DOMContentLoaded", function(event) {
localStorage.setItem("name", "Classes");
localStorage.setItem("icon", "/images/favicon/classroom.png");
}
else if (selectedValue === 'Schoology') {
icon.setAttribute('href', '/images/favicon/schoology.png');
name.textContent = 'Home | Schoology';
localStorage.setItem("name", "Home | Schoology");
localStorage.setItem("icon", "/images/favicon/schoology.png");
}
else if (selectedValue === 'Gmail') {
icon.setAttribute('href', '/images/favicon/gmail.png');
name.textContent = 'Gmail';
localStorage.setItem("name", "Gmail");
localStorage.setItem("icon", "/images/favicon/gmail.png");
}
else if (selectedValue === 'Clever') {
icon.setAttribute('href', '/images/favicon/clever.png');
name.textContent = 'Clever | Portal';
localStorage.setItem("name", "Clever | Portal");
localStorage.setItem("icon", "/images/favicon/clever.png");
}
else if (selectedValue === 'Khan') {
icon.setAttribute('href', '/images/favicon/khan.png');
name.textContent = 'Dashboard | Khan Academy';
localStorage.setItem("name", "Dashboard | Khan Academy");
localStorage.setItem("icon", "/images/favicon/khan.png");
}
var themeid = localStorage.getItem("theme");
//Loads theme
themeEle = document.createElement("link");
Expand Down

0 comments on commit 549c5f0

Please sign in to comment.