add max height and width to video thumbnail

This commit is contained in:
MarconLP 2023-05-03 20:02:35 +02:00
parent 86a8b719b6
commit 283f315b63
No known key found for this signature in database
GPG key ID: F4CAFFDFA3451D5E

View file

@ -16,6 +16,7 @@ import recordVideoModalOpen from "~/atoms/recordVideoModalOpen";
import Paywall from "~/components/Paywall"; import Paywall from "~/components/Paywall";
import paywallAtom from "~/atoms/paywallAtom"; import paywallAtom from "~/atoms/paywallAtom";
import { usePostHog } from "posthog-js/react"; import { usePostHog } from "posthog-js/react";
import Image from "next/image";
const VideoList: NextPage = () => { const VideoList: NextPage = () => {
const [, setRecordOpen] = useAtom(recordVideoModalOpen); const [, setRecordOpen] = useAtom(recordVideoModalOpen);
@ -182,11 +183,13 @@ const VideoCard = ({ title, id, createdAt, thumbnailUrl }: VideoCardProps) => {
<Link href={`/share/${id}`}> <Link href={`/share/${id}`}>
<div className="h-[240px] w-[250px] cursor-pointer overflow-hidden rounded-lg border border-[#6c668533] text-sm font-normal"> <div className="h-[240px] w-[250px] cursor-pointer overflow-hidden rounded-lg border border-[#6c668533] text-sm font-normal">
<figure> <figure>
<img <Image
src={thumbnailUrl} src={thumbnailUrl}
className="max-h-[139.5px] max-w-[248px]"
alt="video thumbnail" alt="video thumbnail"
width={248} width={248}
height={139.5} height={139.5}
unoptimized
/> />
</figure> </figure>
<div className="m-4 flex flex-col"> <div className="m-4 flex flex-col">