mirror of
https://github.com/zoriya/flake.git
synced 2026-06-07 04:16:21 +00:00
Remove "- Topic" suffix from artists in mpris
This commit is contained in:
@@ -36,7 +36,7 @@ const ArtistLabel = ({ player, ...props }) =>
|
|||||||
wrap: true,
|
wrap: true,
|
||||||
truncate: "end",
|
truncate: "end",
|
||||||
hpack: "start",
|
hpack: "start",
|
||||||
label: player.bind("track_artists").transform((x) => x.join(", ")),
|
label: player.bind("track_artists").transform((x) => x.map(y => y.replace(/- Topic$/, "")).join(", ")),
|
||||||
...props,
|
...props,
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -147,7 +147,7 @@ export const LinePlayer = ({ player, ...props }) =>
|
|||||||
Widget.Label({
|
Widget.Label({
|
||||||
label: Utils.merge(
|
label: Utils.merge(
|
||||||
[player.bind("track_title"), player.bind("track_artists")],
|
[player.bind("track_title"), player.bind("track_artists")],
|
||||||
(title, artists) => `${title} - ${artists.join(", ")}`,
|
(title, artists) => `${title} - ${artists.map(x => x.replace(/- Topic$/, "")).join(", ")}`,
|
||||||
),
|
),
|
||||||
maxWidthChars: 30,
|
maxWidthChars: 30,
|
||||||
wrap: true,
|
wrap: true,
|
||||||
|
|||||||
Reference in New Issue
Block a user