Replaces icon with image

This commit is contained in:
freearhey
2024-06-24 16:49:35 +03:00
parent 0eaff54a31
commit bb6771f539
170 changed files with 428 additions and 351 deletions

View File

@@ -41,7 +41,7 @@ module.exports = {
title,
sub_title,
description: parseDescription($item),
icon: parseIcon($item),
image: parseImage($item),
category: parseCategory($item),
rating: parseRating($item),
actors: parseActors($item),
@@ -102,7 +102,7 @@ function parseDescription($item) {
return $item('*').data('description')
}
function parseIcon($item) {
function parseImage($item) {
const showpicture = $item('*').data('showpicture')
const url = new URL(showpicture, 'https://cdn.tvpassport.com/image/show/960x540/')

View File

@@ -41,7 +41,7 @@ it('can parse response', () => {
title: 'Charlie Moore: No Offense',
sub_title: 'Under the Influencer',
category: ['Sports', 'Outdoors'],
icon: 'https://cdn.tvpassport.com/image/show/960x540/69103.jpg',
image: 'https://cdn.tvpassport.com/image/show/960x540/69103.jpg',
rating: {
system: 'MPA',
value: 'TV-G'