import ImdbLogo from '@app/assets/services/imdb.svg'; import PlexLogo from '@app/assets/services/plex.svg'; import RTLogo from '@app/assets/services/rt.svg'; import TmdbLogo from '@app/assets/services/tmdb.svg'; import TraktLogo from '@app/assets/services/trakt.svg'; import TvdbLogo from '@app/assets/services/tvdb.svg'; import useLocale from '@app/hooks/useLocale'; import { MediaType } from '@server/constants/media'; interface ExternalLinkBlockProps { mediaType: 'movie' | 'tv'; tmdbId?: number; tvdbId?: number; imdbId?: string; rtUrl?: string; plexUrl?: string; } const ExternalLinkBlock = ({ mediaType, tmdbId, tvdbId, imdbId, rtUrl, plexUrl, }: ExternalLinkBlockProps) => { const { locale } = useLocale(); return (
{plexUrl && ( )} {tmdbId && ( )} {tvdbId && mediaType === MediaType.TV && ( )} {imdbId && ( )} {rtUrl && ( )} {tmdbId && ( )}
); }; export default ExternalLinkBlock;