feat: a tiny bit of work to rip out letterboxd
This commit is contained in:
parent
2f0c3d7ac0
commit
681f26e9ea
8 changed files with 80 additions and 53 deletions
|
@ -45,7 +45,7 @@ module.exports = {
|
|||
tagLookup: (url, tagMap) => {
|
||||
if (!url) return
|
||||
if (url.includes('https://goodreads.com')) return '#Books #Reading'
|
||||
if (url.includes('https://letterboxd.com')) return '#Movies #Letterboxd'
|
||||
if (url.includes('https://trakt.tv')) return '#Movies #Trakt'
|
||||
return tagMap[url] || ''
|
||||
},
|
||||
webmentionsByUrl: (webmentions, url) => {
|
||||
|
|
|
@ -15,11 +15,7 @@ module.exports = {
|
|||
normalized['alt'] = `${item['plays']} plays of ${item['title']}`
|
||||
normalized['subtext'] = `${item['plays']} plays`
|
||||
}
|
||||
if (item.type === 'book') normalized['alt'] = item['title']
|
||||
if (item.type === 'movie') {
|
||||
normalized['title'] = item['title']
|
||||
normalized['alt'] = `${item['title']} - ${item['description']}`
|
||||
}
|
||||
if (item.type === 'book' || item.type === 'movie') normalized['alt'] = item['title']
|
||||
if (item.type === 'tv') {
|
||||
normalized['title'] = item['title']
|
||||
normalized['alt'] = `${item['title']} from ${item['name']}`
|
||||
|
|
Reference in a new issue