Skip to content

Commit

Permalink
1.5.8
Browse files Browse the repository at this point in the history
- Fixed ParticleCore#357
- Fixed blacklist button showing in subscription feed incorrectly
  • Loading branch information
ParticleCore committed Oct 11, 2016
1 parent da7bf59 commit 734e330
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 12 deletions.
2 changes: 1 addition & 1 deletion bin/update.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"addons": {
"[email protected]": {
"updates": [{
"version": "1.5.7",
"version": "1.5.8",
"update_link": "https://github.com/ParticleCore/Particle/raw/master/dist/YouTubePlus.xpi",
"applications": {
"gecko": {
Expand Down
Binary file modified dist/YouTubePlus.xpi
Binary file not shown.
12 changes: 7 additions & 5 deletions src/Userscript/YouTubePlus.user.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// ==UserScript==
// @version 1.5.7
// @version 1.5.8
// @name YouTube +
// @namespace https://github.com/ParticleCore
// @description YouTube with more freedom
Expand Down Expand Up @@ -1110,7 +1110,7 @@
button.content.firstChild.dataset.link = temp[j].querySelector("a[href*='/watch?v']").href;
thumb.appendChild(setLocale(button.content).firstChild);
}
if (user_settings.BLK_ON && !thumb.querySelector(".blacklist") && window.yt.config_.PAGE_NAME !== "channel") {
if (user_settings.BLK_ON && !thumb.querySelector(".blacklist") && window.yt.config_.PAGE_NAME !== "channel" && window.location.pathname !== "/feed/subscriptions") {
button = document.createElement("template");
button.innerHTML = //
`<div data-p='ttl|BLCK_ADD&ttp|BLCK_ADD' class='yt-uix-tooltip blacklist'>
Expand Down Expand Up @@ -1596,8 +1596,10 @@
}
adverts = document.querySelector(ads_list);
}
if ((window.location.pathname === "/results" && sidebar && sidebar.querySelectorAll("*").length < 10) || (sidebar && ((user_settings.GEN_HDE_RECM_SDBR && window.location.href.split("/feed/subscriptions").length > 1) || (user_settings.GEN_HDE_SRCH_SDBR && window.location.pathname === "/results") || (user_settings.GEN_HDE_CHN_SDBR && window.location.href.split(/\/(channel|user|c)\//).length > 1)))) {
sidebar.outerHTML = "";
if (sidebar && sidebar.parentNode) {
if ((window.location.pathname === "/results" && sidebar && sidebar.querySelectorAll("*").length < 10) || (sidebar && ((user_settings.GEN_HDE_RECM_SDBR && window.location.href.split("/feed/subscriptions").length > 1) || (user_settings.GEN_HDE_SRCH_SDBR && window.location.pathname === "/results") || (user_settings.GEN_HDE_CHN_SDBR && window.location.href.split(/\/(channel|user|c)\//).length > 1)))) {
sidebar.outerHTML = "";
}
}
if (window.location.pathname === "/watch" && user_settings.VID_HIDE_COMS > 1 && comments) {
comments.outerHTML = "";
Expand Down Expand Up @@ -2133,7 +2135,7 @@
holder = document.createElement("link");
holder.rel = "stylesheet";
holder.type = "text/css";
holder.href = "https://particlecore.github.io/Particle/stylesheets/YouTubePlus.css";
holder.href = "https://particlecore.github.io/Particle/stylesheets/YouTubePlus.css?v=1.5.8";
document.documentElement.appendChild(holder);
}
holder = document.createElement("script");
Expand Down
3 changes: 3 additions & 0 deletions src/Webextension/CSS/YouTubePlus.css
Original file line number Diff line number Diff line change
Expand Up @@ -450,6 +450,9 @@
}
/* end| Pop-out */
/* start| Thumb buttons */
.yt-lockup-thumbnail{
overflow: hidden;
}
.yt-pl-thumb .popoutmode,
.thumb-wrapper .popoutmode,
.yt-lockup-thumbnail .popoutmode,
Expand Down
12 changes: 7 additions & 5 deletions src/Webextension/JS/YouTubePlus.user.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// ==UserScript==
// @version 1.5.7
// @version 1.5.8
// @name YouTube +
// @namespace https://github.com/ParticleCore
// @description YouTube with more freedom
Expand Down Expand Up @@ -1110,7 +1110,7 @@
button.content.firstChild.dataset.link = temp[j].querySelector("a[href*='/watch?v']").href;
thumb.appendChild(setLocale(button.content).firstChild);
}
if (user_settings.BLK_ON && !thumb.querySelector(".blacklist") && window.yt.config_.PAGE_NAME !== "channel") {
if (user_settings.BLK_ON && !thumb.querySelector(".blacklist") && window.yt.config_.PAGE_NAME !== "channel" && window.location.pathname !== "/feed/subscriptions") {
button = document.createElement("template");
button.innerHTML = //
`<div data-p='ttl|BLCK_ADD&ttp|BLCK_ADD' class='yt-uix-tooltip blacklist'>
Expand Down Expand Up @@ -1596,8 +1596,10 @@
}
adverts = document.querySelector(ads_list);
}
if ((window.location.pathname === "/results" && sidebar && sidebar.querySelectorAll("*").length < 10) || (sidebar && ((user_settings.GEN_HDE_RECM_SDBR && window.location.href.split("/feed/subscriptions").length > 1) || (user_settings.GEN_HDE_SRCH_SDBR && window.location.pathname === "/results") || (user_settings.GEN_HDE_CHN_SDBR && window.location.href.split(/\/(channel|user|c)\//).length > 1)))) {
sidebar.outerHTML = "";
if (sidebar && sidebar.parentNode) {
if ((window.location.pathname === "/results" && sidebar && sidebar.querySelectorAll("*").length < 10) || (sidebar && ((user_settings.GEN_HDE_RECM_SDBR && window.location.href.split("/feed/subscriptions").length > 1) || (user_settings.GEN_HDE_SRCH_SDBR && window.location.pathname === "/results") || (user_settings.GEN_HDE_CHN_SDBR && window.location.href.split(/\/(channel|user|c)\//).length > 1)))) {
sidebar.outerHTML = "";
}
}
if (window.location.pathname === "/watch" && user_settings.VID_HIDE_COMS > 1 && comments) {
comments.outerHTML = "";
Expand Down Expand Up @@ -2133,7 +2135,7 @@
holder = document.createElement("link");
holder.rel = "stylesheet";
holder.type = "text/css";
holder.href = "https://particlecore.github.io/Particle/stylesheets/YouTubePlus.css";
holder.href = "https://particlecore.github.io/Particle/stylesheets/YouTubePlus.css?v=1.5.8";
document.documentElement.appendChild(holder);
}
holder = document.createElement("script");
Expand Down
Binary file removed src/Webextension/images/sprite.png
Binary file not shown.
2 changes: 1 addition & 1 deletion src/Webextension/manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"manifest_version": 2,
"name": "YouTube Plus",
"version": "1.5.7",
"version": "1.5.8",
"description": "YouTube with more freedom",
"default_locale": "en",
"icons": {
Expand Down

0 comments on commit 734e330

Please sign in to comment.