Fix episode images url not allowed (#1580)
* fix: fix url parameter not allowed * fix: use cached image for episode images * refactor: remove console logs
This commit is contained in:
@@ -1,8 +1,8 @@
|
|||||||
import AirDateBadge from '@app/components/AirDateBadge';
|
import AirDateBadge from '@app/components/AirDateBadge';
|
||||||
|
import CachedImage from '@app/components/Common/CachedImage';
|
||||||
import LoadingSpinner from '@app/components/Common/LoadingSpinner';
|
import LoadingSpinner from '@app/components/Common/LoadingSpinner';
|
||||||
import defineMessages from '@app/utils/defineMessages';
|
import defineMessages from '@app/utils/defineMessages';
|
||||||
import type { SeasonWithEpisodes } from '@server/models/Tv';
|
import type { SeasonWithEpisodes } from '@server/models/Tv';
|
||||||
import Image from 'next/image';
|
|
||||||
import { useIntl } from 'react-intl';
|
import { useIntl } from 'react-intl';
|
||||||
import useSWR from 'swr';
|
import useSWR from 'swr';
|
||||||
|
|
||||||
@@ -57,7 +57,8 @@ const Season = ({ seasonNumber, tvId }: SeasonProps) => {
|
|||||||
</div>
|
</div>
|
||||||
{episode.stillPath && (
|
{episode.stillPath && (
|
||||||
<div className="relative aspect-video xl:h-32">
|
<div className="relative aspect-video xl:h-32">
|
||||||
<Image
|
<CachedImage
|
||||||
|
type="tmdb"
|
||||||
className="rounded-lg object-contain"
|
className="rounded-lg object-contain"
|
||||||
src={`https://image.tmdb.org/t/p/original/${episode.stillPath}`}
|
src={`https://image.tmdb.org/t/p/original/${episode.stillPath}`}
|
||||||
alt=""
|
alt=""
|
||||||
|
|||||||
Reference in New Issue
Block a user