Source: task/album-detection (objective/linker-improvements) — project brief asks for artist OR album linking; MVP linked artists only.
- service/lib.js: pickAlbum (the exact-name gate, named for the album path) + linkResult now carries kind:"artist"|"album" (additive; defaults to artist so older clients keep working).
- service/resolver.js: one Spotify type=artist,album search per candidate, exact-match against either; returns {url,kind}; cache key includes the kind hint. resolveOne/resolveAll thread the LLM kind hint through.
- service/llm.js: parseClassification now returns Map(name -> "artist"|"album") so album-kind candidates route to the album path (.has() still works like the old Set).
- extension/extract.js: albumMatchesIn over two precise signals (quoted strings + album cue phrases "the album X", "X LP/EP"), folded into allMatchesIn.
- extension/content.js + styles.css: album links render italicised (.rsl-album) with an album tooltip; artist behavior unchanged.
- Tests: new pure-logic coverage in lib.test.js / llm.test.js / extract.test.cjs (album shaping, Map-kind routing, album candidate extraction). scripts/check.sh green.
- README.md + AGENTS.md: document album linking.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
22 lines
701 B
CSS
22 lines
701 B
CSS
/* Injected links — kept subtle so reddit comments stay readable. One link per artist/album,
|
|
coloured by platform: green = Spotify, blue = Google (bandcamp-search fallback). Album links
|
|
are italicised (the usual title convention) so an album reads differently from an artist at
|
|
a glance; the platform colour is unchanged. */
|
|
.rsl-link {
|
|
text-decoration: underline dotted;
|
|
text-underline-offset: 2px;
|
|
cursor: pointer;
|
|
}
|
|
.rsl-album {
|
|
font-style: italic;
|
|
}
|
|
.rsl-spotify {
|
|
text-decoration-color: #1db954 !important; /* spotify green */
|
|
}
|
|
.rsl-google {
|
|
text-decoration-color: #4a72d0 !important; /* google-ish blue */
|
|
}
|
|
.rsl-link:hover {
|
|
text-decoration-style: solid !important;
|
|
}
|