Greasy Fork is available in English.

Plex web album and artist name swap

Swaps the album and artist names so the album name is on top

Autor
frondonson
Dnevne instalacije
0
Ukupnih instalacija
0
Ocjene
0 0 0
Verzija
2024-02.6
Stvoreno
09.02.2024.
Ažurirano
13.02.2024.
Licenza
MIT
Primjenjuje se

A simple (albeit crude) script to swap album name and artist. Works on albums on the homepage, music library tabs and the album view page.

IMPORTANT
If you don't use the app.plex.tv/desktop URL to access your server, you will need to add your server's URL(s) in the @match section.

To add a URL match, open the tampermonkey dashboard and click the edit on this script

If your URL is http://192.168.1.60:32400/web add

// @match        http://192.168.1.60:32400/web/*

If your URL is (https, http)://plex.yourdomain.com add

// @match        https://plex.yourdomain.com/web/*
or, for either http/https
// @match        *://plex.yourdomain.com/web/*

make sure you add every URL you use to access your server and don't forget the /* at the end so it will run on your music library page.

The crude 'check every card repeatedly' approach is because I couldn't figure out how to set up a mutation observer that would only trigger for elements containing albums since plex treats all library types identical in the html (as far as I can tell). This is the only way I could get it to work well without creating a hilariously convoluted script. Hopefully it is performant enough.
(also, hopefully plex doesn't change the hash things on their css classes, as that was the only way I could make selectors)