diff --git a/README.md b/README.md index d1f07c5..c7fe8c9 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ This extension allows you to configure shortcuts to `play`, `pause` and go to th To configure the shortcuts, go to `chrome://extensions/shortcuts` (you have to copy and paste it on the address bar), find the `Webplayer Hotkeys` extension and assign the shortcuts to the commands you want -If there is more player tabs than one, it follows this order of priority: `Spotify > Deezer > SoundCloud > Youtube` +If there is more player tabs than one, it follows this order of priority: `Spotify > Deezer > SoundCloud > Youtube Music > Youtube` Works with: @@ -34,6 +34,7 @@ Works with: - Deezer - SoundCloud - Youtube +- Youtube Music ## LICENSE diff --git a/src/background.ts b/src/background.ts index 90116b3..d46a284 100644 --- a/src/background.ts +++ b/src/background.ts @@ -37,6 +37,17 @@ const players: Player[] = [ title: 'soundcloud', url: 'https://soundcloud.com/', }, + { + controlQueries: { + next: '.next-button.ytmusic-player-bar', + play: '.play-pause-button.ytmusic-player-bar', + prev: '.previous-button.ytmusic-player-bar', + }, + default: false, + tabQuery: '*://music.youtube.com/*', + title: 'youtubemusic', + url: 'https://music.youtube.com/', + }, { controlQueries: { next: '.ytp-next-button.ytp-button', diff --git a/src/manifest.json b/src/manifest.json index b6d5192..4fcd541 100644 --- a/src/manifest.json +++ b/src/manifest.json @@ -3,7 +3,7 @@ "name": "Webplayer Hotkeys - Shortcuts for web players", "version": "0.0.0", "description": - "Assign hotkeys to play/pause, and switch music. Works with Spotify, Deezer, SoundCloud and Youtube.", + "Assign hotkeys to play/pause, and switch music. Works with Spotify, Deezer, SoundCloud, Youtube and Youtube Music.", "icons": { "128": "icon.png" },