|
|
@ -184,48 +184,52 @@ const DiscoverSliderEdit = ({
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
)}
|
|
|
|
)}
|
|
|
|
<div className="flex w-full flex-col rounded-t-lg border-t border-l border-r border-gray-800 bg-gray-900 p-4 text-gray-400 md:flex-row md:items-center md:space-x-2">
|
|
|
|
<div className="flex w-full flex-col rounded-t-lg border-t border-l border-r border-gray-800 bg-gray-900 p-4 text-gray-400 md:flex-row md:items-center md:space-x-2">
|
|
|
|
<div className="mb-4 flex space-x-2 md:mb-0">
|
|
|
|
<div
|
|
|
|
|
|
|
|
className={`${slider.data ? 'mb-4' : 'mb-0'} flex space-x-2 md:mb-0`}
|
|
|
|
|
|
|
|
>
|
|
|
|
<Bars3Icon className="h-6 w-6" />
|
|
|
|
<Bars3Icon className="h-6 w-6" />
|
|
|
|
<div>{getSliderTitle(slider)}</div>
|
|
|
|
<div>{getSliderTitle(slider)}</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div className="pointer-events-none mb-4 flex-1 md:mb-0">
|
|
|
|
{slider.data && (
|
|
|
|
{(slider.type === DiscoverSliderType.TMDB_MOVIE_KEYWORD ||
|
|
|
|
<div className="pointer-events-none mb-4 flex-1 md:mb-0">
|
|
|
|
slider.type === DiscoverSliderType.TMDB_TV_KEYWORD) && (
|
|
|
|
{(slider.type === DiscoverSliderType.TMDB_MOVIE_KEYWORD ||
|
|
|
|
<div className="flex space-x-2">
|
|
|
|
slider.type === DiscoverSliderType.TMDB_TV_KEYWORD) && (
|
|
|
|
{slider.data?.split(',').map((keywordId) => (
|
|
|
|
<div className="flex space-x-2">
|
|
|
|
<KeywordTag
|
|
|
|
{slider.data?.split(',').map((keywordId) => (
|
|
|
|
key={`slider-keywords-${slider.id}-${keywordId}`}
|
|
|
|
<KeywordTag
|
|
|
|
keywordId={Number(keywordId)}
|
|
|
|
key={`slider-keywords-${slider.id}-${keywordId}`}
|
|
|
|
/>
|
|
|
|
keywordId={Number(keywordId)}
|
|
|
|
))}
|
|
|
|
/>
|
|
|
|
</div>
|
|
|
|
))}
|
|
|
|
)}
|
|
|
|
</div>
|
|
|
|
{(slider.type === DiscoverSliderType.TMDB_NETWORK ||
|
|
|
|
)}
|
|
|
|
slider.type === DiscoverSliderType.TMDB_STUDIO) && (
|
|
|
|
{(slider.type === DiscoverSliderType.TMDB_NETWORK ||
|
|
|
|
<CompanyTag
|
|
|
|
slider.type === DiscoverSliderType.TMDB_STUDIO) && (
|
|
|
|
type={
|
|
|
|
<CompanyTag
|
|
|
|
slider.type === DiscoverSliderType.TMDB_STUDIO
|
|
|
|
type={
|
|
|
|
? 'studio'
|
|
|
|
slider.type === DiscoverSliderType.TMDB_STUDIO
|
|
|
|
: 'network'
|
|
|
|
? 'studio'
|
|
|
|
}
|
|
|
|
: 'network'
|
|
|
|
companyId={Number(slider.data)}
|
|
|
|
}
|
|
|
|
/>
|
|
|
|
companyId={Number(slider.data)}
|
|
|
|
)}
|
|
|
|
/>
|
|
|
|
{(slider.type === DiscoverSliderType.TMDB_TV_GENRE ||
|
|
|
|
)}
|
|
|
|
slider.type === DiscoverSliderType.TMDB_MOVIE_GENRE) && (
|
|
|
|
{(slider.type === DiscoverSliderType.TMDB_TV_GENRE ||
|
|
|
|
<GenreTag
|
|
|
|
slider.type === DiscoverSliderType.TMDB_MOVIE_GENRE) && (
|
|
|
|
type={
|
|
|
|
<GenreTag
|
|
|
|
slider.type === DiscoverSliderType.TMDB_MOVIE_GENRE
|
|
|
|
type={
|
|
|
|
? 'movie'
|
|
|
|
slider.type === DiscoverSliderType.TMDB_MOVIE_GENRE
|
|
|
|
: 'tv'
|
|
|
|
? 'movie'
|
|
|
|
}
|
|
|
|
: 'tv'
|
|
|
|
genreId={Number(slider.data)}
|
|
|
|
}
|
|
|
|
/>
|
|
|
|
genreId={Number(slider.data)}
|
|
|
|
)}
|
|
|
|
/>
|
|
|
|
{slider.type === DiscoverSliderType.TMDB_SEARCH && (
|
|
|
|
)}
|
|
|
|
<Tag iconSvg={<MagnifyingGlassIcon />}>{slider.data}</Tag>
|
|
|
|
{slider.type === DiscoverSliderType.TMDB_SEARCH && (
|
|
|
|
)}
|
|
|
|
<Tag iconSvg={<MagnifyingGlassIcon />}>{slider.data}</Tag>
|
|
|
|
</div>
|
|
|
|
)}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
)}
|
|
|
|
<div className="flex items-center space-x-2">
|
|
|
|
<div className="flex items-center space-x-2">
|
|
|
|
{!slider.isBuiltIn && (
|
|
|
|
{!slider.isBuiltIn && (
|
|
|
|
<>
|
|
|
|
<>
|
|
|
@ -265,7 +269,7 @@ const DiscoverSliderEdit = ({
|
|
|
|
</Button>
|
|
|
|
</Button>
|
|
|
|
</>
|
|
|
|
</>
|
|
|
|
)}
|
|
|
|
)}
|
|
|
|
<div className="flex-1 pl-4 text-right">
|
|
|
|
<div className="absolute top-4 right-4 flex-1 pl-4 text-right md:relative md:top-0 md:right-0">
|
|
|
|
<Tooltip content={intl.formatMessage(messages.enable)}>
|
|
|
|
<Tooltip content={intl.formatMessage(messages.enable)}>
|
|
|
|
<div>
|
|
|
|
<div>
|
|
|
|
<SlideCheckbox
|
|
|
|
<SlideCheckbox
|
|
|
|