Skip to content

Commit

Permalink
don't inject hiddenElementsSelector when selector is empty
Browse files Browse the repository at this point in the history
  • Loading branch information
hanubeki committed Aug 21, 2024
1 parent 550f9d7 commit c11d37b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions generate/cosmetic/script-template.js
Original file line number Diff line number Diff line change
Expand Up @@ -270,8 +270,10 @@
})

elementReady('head').then((_) => {
injectStyle(hiddenElementsSelector);
log("Injected combined style");
if (!hiddenElementsSelector.startsWith(":is()")) {
injectStyle(hiddenElementsSelector);
log("Injected combined style");
}

if (cssInjections.length > 0) {
injectStyle(cssInjections);
Expand Down

0 comments on commit c11d37b

Please sign in to comment.