Skip to content

Commit

Permalink
fix iframe embeds (#153)
Browse files Browse the repository at this point in the history
  • Loading branch information
Araxeus authored Aug 23, 2024
1 parent 526a290 commit 6b28ce5
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 5 deletions.
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,7 @@
"hooks": {
"before:init": "bun check",
"after:bump": "bun format",
"before:release": "bun b",
"after:release": "echo Successfully released ${name} v${version} to ${repo.repository}."
"after:release": "bun b"
},
"git": {
"requireBranch": "main",
Expand Down
12 changes: 10 additions & 2 deletions unpacked/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,11 @@
"permissions": ["storage"],
"content_scripts": [
{
"matches": ["https://www.youtube.com/*", "https://music.youtube.com/*"],
"matches": [
"https://www.youtube.com/*",
"https://music.youtube.com/*",
"https://www.youtube-nocookie.com/embed/*"
],
"all_frames": true,
"js": ["index.js"],
"css": ["style.css"],
Expand All @@ -16,7 +20,11 @@
"web_accessible_resources": [
{
"resources": ["pageAccess.js"],
"matches": ["https://www.youtube.com/*", "https://music.youtube.com/*"]
"matches": [
"https://www.youtube.com/*",
"https://music.youtube.com/*",
"https://www.youtube-nocookie.com/*"
]
}
],
"icons": {
Expand Down
2 changes: 1 addition & 1 deletion unpacked/pageAccess.js
Original file line number Diff line number Diff line change
Expand Up @@ -499,7 +499,7 @@ class YoutubeVolumeScroll {

const pref = ytvs
.getCookie('PREF')
.replace(/volume=(\d+)/, `volume=${volume}`);
?.replace(/volume=(\d+)/, `volume=${volume}`);
if (pref) {
document.cookie = `${pref};domain=.youtube.com;max-age=${
ytvs.oneMonth / 1000 // convert to seconds
Expand Down

0 comments on commit 6b28ce5

Please sign in to comment.