-
Notifications
You must be signed in to change notification settings - Fork 572
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[DEPRECATED] Local Subscriptions Plugin #340
Conversation
-doesnt include main menu template anymore
add "Use Proxy" checkbox
in-app-menu updates menu only if needed
This reverts commit 8b6c60b.
This somehow fix "did-fail-load" being called on song start, with in-app-plugin-activated
refactor and css fix xo --fix add inline doc fix typo
…3c3c69b869a [Snyk] Upgrade custom-electron-titlebar from 3.2.6 to 3.2.7
…a5d8110bde3 [Snyk] Upgrade @ffmpeg/ffmpeg from 0.9.8 to 0.10.0
…rade-a785f5d95c7765e2d47737e150a2263d # By Araxeus (2) and snyk-bot (2) # Via GitHub (3) and Araxeus (1) * 'master' of github.com:th-ch/youtube-music: check if native image is empty before writing id tag fix unsupported hidden webp coverart fix: upgrade @ffmpeg/ffmpeg from 0.9.8 to 0.10.0 fix: upgrade custom-electron-titlebar from 3.2.6 to 3.2.7
…7e150a2263d [Snyk] Upgrade @ffmpeg/core from 0.9.0 to 0.10.0
…nes-3.0.1 Bump trim-newlines from 3.0.0 to 3.0.1
…url-4.5.1 Bump normalize-url from 4.5.0 to 4.5.1
…00ed1b78d70 [Snyk] Upgrade electron-updater from 4.3.8 to 4.3.9
…5e4912a4659 [Snyk] Upgrade ytdl-core from 4.8.0 to 4.8.2
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.20 to 4.17.21. - [Release notes](https://github.com/lodash/lodash/releases) - [Commits](lodash/lodash@4.17.20...4.17.21) --- updated-dependencies: - dependency-name: lodash dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com>
…7.21 Bump lodash from 4.17.20 to 4.17.21
…-info-2.8.9 Bump hosted-git-info from 2.8.8 to 2.8.9
…-subscriptions-plugin
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks promising, the plugin is a good idea ! It seems the PR now includes a bunch of unrelated commits so probably worth rebasing - I left a comment about having a store migration to ensure the config is there, with that this version could ship - from there, plenty of potential! (linking to the channel pages, saving videos or any playlist, etc)
@@ -76,6 +76,10 @@ const defaultConfig = { | |||
"music_offtopic", | |||
], | |||
}, | |||
"local-subscriptions": { | |||
enabled: false, | |||
subscriptions: {} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That will require a store migration: when you enable it for the first time, your config will end up with:
local-subscriptions": {
enabled: true
}
And the code does not support empty subscriptions
:)
break; | ||
case ACTIONS.SUBS_LI_CLK: | ||
subscriptionsWindow.close(); | ||
console.log(action) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: only log that in dev mode (if is.dev()
)
const browseId = 'UCO8fwuNOHp3wujDbfRJATzQ'
$('ytmusic-app').navigate_(browseId)
This plugin could also allow "subscribing" to playlist which would resolve #363 const browseId=
$('ytmusic-app').__data.mainContentData_.endpoint.data.browseId (current page is an album if browseId starts with const pageType =
$('ytmusic-app').__data.mainContentData_.endpoint.data
.browseEndpointContextSupportedConfigs.browseEndpointContextMusicConfig.pageType;
const expectedResults = [
'MUSIC_PAGE_TYPE_ARTIST',
'MUSIC_PAGE_TYPE_ALBUM',
'MUSIC_PAGE_TYPE_PLAYLIST'
] (btw this whole thing is more "bookmarks" than "subscriptions" but the latter sounds better so whatever 😅 Optionally if we want to capture an icon for the page (Channel/Artist/Playlist/Album) this could work: function getPageThumbnail() {
const header = $('ytmusic-app').__data.mainContentData_.response.header;
const headerRenderer = header.musicImmersiveHeaderRenderer || header.musicDetailHeaderRenderer || header.musicVisualHeaderRenderer;
const thumbnailType = headerRenderer.foregroundThumbnail || headerRenderer.thumbnail;
const thumbnailRenderer = thumbnailType.musicThumbnailRenderer || thumbnailType.croppedSquareThumbnailRenderer;
const thumbnails = thumbnailRenderer.thumbnail.thumbnails;
if (!thumbnails || thumbnails.length <= 0) return '';
return thumbnails[thumbnails.length - 1].url.replace(/=.*/, '=w100-h100-p-l90-rj');
} Maybe add an option to disable the normal library button @fdr-smnv contact me on discord(Araxeus#0819) or here if u wanna do some changes because I'm also trying some stuff out |
As the title says this plugin allows the user to save subscriptions locally without google account. It adds 'Subscriptions' tab in the menu which opens new window with the list of user's local subscriptions that can be opened in the main window. I think this plugin would go hand in hand with no-google-login plugin. Also I'm fairly new to electron so I'm pushing this plugin early to hopefully get some feedback and advice.
What works:
Issues/TODO: