Add per-download Amazon button settings for current and archived downloads

This commit is contained in:
nmemmert
2026-05-07 07:49:02 -04:00
parent 9f0aa8bd65
commit bc3d906e64
4 changed files with 55 additions and 2 deletions
+4
View File
@@ -172,6 +172,8 @@ function sanitizeCustomLinks(value) {
url: sanitizeUrl(item.url),
imageUrl: sanitizeUrl(item.imageUrl),
description: typeof item.description === 'string' ? item.description.trim().slice(0, 4000) : '',
amazonUrl: sanitizeUrl(item.amazonUrl),
amazonLabel: typeof item.amazonLabel === 'string' ? item.amazonLabel.trim().slice(0, 120) : '',
placement,
}
})
@@ -199,6 +201,8 @@ function sanitizeArchivedSeriesResourceLinks(value) {
label: typeof item.label === 'string' ? item.label.trim().slice(0, 120) : '',
description: typeof item.description === 'string' ? item.description.trim().slice(0, 4000) : '',
url: sanitizeUrl(item.url),
amazonUrl: sanitizeUrl(item.amazonUrl),
amazonLabel: typeof item.amazonLabel === 'string' ? item.amazonLabel.trim().slice(0, 120) : '',
}))
.filter(item => item.label && item.url)
}