Fixed Request Button not working on title cards

Anatole Sot 9 months ago
parent 834de0beba
commit 20ca65ac67

@ -166,16 +166,13 @@ const ReleaseDetails = ({ release }: ReleaseDetailsProp) => {
<span className="media-attributes"> <span className="media-attributes">
By&nbsp; By&nbsp;
{data.artist.map((artist, index) => ( {data.artist.map((artist, index) => (
<> <div key={`artist-${index}`}>
{' '} {' '}
<Link <Link href={`/music/artist/${artist.id}`}>
href={`/music/artist/${artist.id}`}
key={`artist-${index}`}
>
<a className="hover:underline">{artist.name}</a> <a className="hover:underline">{artist.name}</a>
</Link> </Link>
{index < data.artist.length - 1 ? ', ' : ''} {index < data.artist.length - 1 ? ', ' : ''}
</> </div>
))} ))}
</span> </span>
</div> </div>

@ -11,6 +11,7 @@ import globalMessages from '@app/i18n/globalMessages';
import { withProperties } from '@app/utils/typeHelpers'; import { withProperties } from '@app/utils/typeHelpers';
import { Transition } from '@headlessui/react'; import { Transition } from '@headlessui/react';
import { ArrowDownTrayIcon } from '@heroicons/react/24/outline'; import { ArrowDownTrayIcon } from '@heroicons/react/24/outline';
import type { SecondaryType } from '@server/constants/media';
import { MediaStatus } from '@server/constants/media'; import { MediaStatus } from '@server/constants/media';
import type { MediaType } from '@server/models/Search'; import type { MediaType } from '@server/models/Search';
import Link from 'next/link'; import Link from 'next/link';
@ -101,6 +102,7 @@ const TitleCard = ({
onComplete={requestComplete} onComplete={requestComplete}
onUpdating={requestUpdating} onUpdating={requestUpdating}
onCancel={closeModal} onCancel={closeModal}
{...(tmdbOrMbId ? {} : { secondaryType: mediaType as SecondaryType })}
/> />
<div <div
className={`relative transform-gpu cursor-default overflow-hidden rounded-xl bg-gray-800 bg-cover outline-none ring-1 transition duration-300 ${ className={`relative transform-gpu cursor-default overflow-hidden rounded-xl bg-gray-800 bg-cover outline-none ring-1 transition duration-300 ${

Loading…
Cancel
Save