Skip to content

feat: block explicit songs (#720) - #801

Open
ZeroIndex-x636A06 wants to merge 1 commit into
kushagrasinghx:v1.8.1from
ZeroIndex-x636A06:feat/explicit-filter-slim
Open

ZeroIndex-x636A06 wants to merge 1 commit into
kushagrasinghx:v1.8.1from
ZeroIndex-x636A06:feat/explicit-filter-slim

Conversation

@ZeroIndex-x636A06

@ZeroIndex-x636A06 ZeroIndex-x636A06 commented Oct 13, 2026 •

Copy link
Copy Markdown

Closes #720

A smaller take on #780, as requested: no lyrics detection, just YouTube Music's explicit badge.

What it adds

  • Block explicit songs setting (Android and desktop, off by default). When on, explicit songs are left out of AutoPlay and radio and skipped in the queue.
  • Song rows and Home cards take an explicitBlocked parameter, true only while blocking is on and the song isn't allowed. A blocked one is greyed out, and tapping it asks: Allow this song, Turn off blocking, or Cancel. On Android the prompt uses the app's existing alert style.
  • Allow this explicit song in the song menu does the same from there. The allowed list is a set of video ids in the existing settings, so Android backups include it.
  • Home cards now carry the explicit badge from YouTube Music, so they show the E like other song rows.
  • The desktop's own song lists (albums, playlists, an artist's top songs, History, Library, Downloads) show the E and are gated the same way.

The rule lives in shared/…/playback/ExplicitFilter.kt and the row helpers in sharedUi/…/components/ExplicitBlocked.kt (copied into desktopUi like the rest of the shared UI), so both apps share them. Rebased onto the current v1.8.1.

Testing

  • New unit test ExplicitFilterTest passes.
  • CI passes (Android, TV, desktop on Linux/macOS/Windows, backend) apart from LocaleStringsTest for zh-CN and zh-TW, which already fail on v1.8.1 (untranslated artist_signatures strings).
  • Tested on Android and desktop (Linux): AutoPlay and radio, greyed rows and cards with the prompt, the E on Home and in the desktop's song lists, skipping in albums and playlists, and allowing and re-blocking a song.

Note: Just to be upfront, the code in this PR was generated with Claude, however I tested every feature by hand on both desktop (Linux) and mobile (Android) before submitting it. If anything looks off or you want something done differently, just let me know and I'll get it taken care of!

@ZeroIndex-x636A06
ZeroIndex-x636A06 force-pushed the feat/explicit-filter-slim branch 5 times, most recently from 75b1cd6 to a88c324 Compare October 16, 2026 18:05
Adds a "Block explicit songs" setting, off by default. When on, songs
YouTube Music marks explicit are left out of AutoPlay and radio and
skipped in the queue. Song rows, Home cards and search's top result take
an explicitBlocked parameter: a blocked one is greyed out, and tapping it
asks whether to allow the song or turn blocking off. A song can also be
allowed from its menu. Home cards and search suggestions now carry the
explicit badge, so they show the E like other song rows.
@ZeroIndex-x636A06
ZeroIndex-x636A06 force-pushed the feat/explicit-filter-slim branch from a88c324 to 2b82ab7 Compare October 16, 2026 18:08

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant