feat: normalize Japanese artist/title names to romaji at storage time
- Add romajiForStorage() to romaji.js — smart word spacing + Title Case - ytdlp.js: apply to folder names, filenames, and embedded tags - novasonic-server.js: apply in edit-metadata endpoint and Spotify resolve - spotify.js: update track artist/name from iTunes canonical English names Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
c03463b66b
commit
446c583f7f
4 files changed
+57
-15
No files matched your search
@@ -295,6 +295,10 @@ async function _loadSpotifyTrackArtwork(tracks, listEl) {
|
||||
if (match.trackExplicitness) t.trackExplicitness = match.trackExplicitness;
|
||||
if (match.previewUrl) t.previewUrl = match.previewUrl;
|
||||
if (match.trackTimeMillis) t.durationMs = match.trackTimeMillis;
|
||||
// Use iTunes canonical English/romaji names — more accurate than Spotify (which may use Japanese)
|
||||
if (match.artistName) t.artistName = match.artistName;
|
||||
const JP_RE = /[-ヿ一-鿿]/;
|
||||
if (JP_RE.test(t.trackName) && match.trackName) t.trackName = match.trackName;
|
||||
if (window._spotifyResolved?.tracks?.[idx]) Object.assign(window._spotifyResolved.tracks[idx], t);
|
||||
const url = match.artworkUrl100 || match.artworkUrl60 || '';
|
||||
if (url) _setArt(artEls[idx], url);
|
||||
|
||||
Reference in new issue
Block a user