From 393b88c823def71da427945ead8be73e2ad88d4b Mon Sep 17 00:00:00 2001 From: Honey Date: Mon, 27 Apr 2026 01:59:12 +0200 Subject: [PATCH] fix(spotify): handle GraphQL embed structure, all artists, correct metadata MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - _spTrackItem now unwraps GraphQL-style {data:{__typename,...}} wrappers - _spAllArtists joins all featured artists (e.g. "Kløn, Renzyx") - _spArtwork adds albumOfTrack path used by newer Spotify embed - fetchSpotifyEmbed: added entity.content.items / entity.data fallback paths - Track download now uses Spotify metadata directly (album, art, year, trackNum) when provided — avoids iTunes returning wrong album for multi-artist tracks - Playlist trackList also tries entity.content.items and entity.tracks.items - Frontend: redesigned preview card with green top accent, bigger art, playlist checkbox styled as pill with Spotify color on check, album button shows actual album name Co-Authored-By: Claude Sonnet 4.6 --- backend/novasonic-server.js | 80 +++++++++++++++++++++++++------------ src/views.js | 57 ++++++++++++++++---------- 2 files changed, 91 insertions(+), 46 deletions(-) diff --git a/backend/novasonic-server.js b/backend/novasonic-server.js index d04a4d1..d5cdc08 100644 --- a/backend/novasonic-server.js +++ b/backend/novasonic-server.js @@ -412,39 +412,59 @@ async function fetchSpotifyEmbed(type, id) { const m = html.match(/