Show provider tags on watchlist
This commit is contained in:
@@ -910,6 +910,15 @@ WATCHLIST_HTML = r"""<!doctype html>
|
||||
container.appendChild(tag);
|
||||
}
|
||||
|
||||
function providerLabel(provider) {
|
||||
const labels = {
|
||||
anikoto: "Anikoto",
|
||||
anineko: "AniNeko",
|
||||
pahe: "AnimePahe"
|
||||
};
|
||||
return labels[String(provider || "").toLowerCase()] || "Provider";
|
||||
}
|
||||
|
||||
function categoryOptions(selected) {
|
||||
return Object.entries(categoryLabels)
|
||||
.map(([value, label]) => `<option value="${value}"${value === selected ? " selected" : ""}>${label}</option>`)
|
||||
@@ -1364,6 +1373,7 @@ WATCHLIST_HTML = r"""<!doctype html>
|
||||
: "Finished, but not marked as downloaded";
|
||||
}
|
||||
const statusRow = card.querySelector(".status-row");
|
||||
appendStatusTag(statusRow, `Source: ${item.provider_label || providerLabel(item.provider)}`);
|
||||
appendStatusTag(statusRow, item.category_label || categoryLabels[item.category] || "Watching");
|
||||
appendStatusTag(statusRow, item.media_type_label || mediaTypeLabels[item.media_type] || "TV");
|
||||
if (item.airing_status) {
|
||||
|
||||
Reference in New Issue
Block a user