fix(metadata): match new lubimyczytac HTML for search (#1608)

This commit is contained in:
James Ward
2026-06-02 15:50:39 -04:00
committed by GitHub
parent 099873af74
commit 9b879af38e
3 changed files with 664 additions and 2066 deletions
@@ -178,11 +178,12 @@ public class LubimyCzytacParser implements BookParser {
private static List<String> extractBookUrls(Document doc) {
List<String> bookUrls = new ArrayList<>();
Elements results = doc.select(".authorAllBooks__single");
// Prefix with the paginator to avoid the promoted books / advertisements
Elements results = doc.select("#ksiazkiPaginator .book-card");
log.info("Found {} search results", results.size());
for (Element result : results) {
Element titleLink = result.selectFirst(".authorAllBooks__singleTextTitle");
Element titleLink = result.selectFirst(".book-card__title");
if (titleLink != null) {
String href = titleLink.attr("href");
if (href != null && !href.isEmpty()) {
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long