fix: remove Button components inside the Link components for the download buttons
Some checks failed
Deploy Next.js application / deploy (push) Failing after 10m9s

This commit is contained in:
Dorian Niemiec 2024-12-19 15:59:43 +01:00
parent 4819c119f1
commit b7be6a4504
2 changed files with 16 additions and 12 deletions

View file

@ -1,4 +1,4 @@
import { Button } from "@/components/ui/button"; import { Button, buttonVariants } from "@/components/ui/button";
import { import {
Table, Table,
TableBody, TableBody,
@ -81,11 +81,13 @@ const DownloadPage = async () => {
<TableCell className="text-left">{download.fileSize}</TableCell> <TableCell className="text-left">{download.fileSize}</TableCell>
<TableCell className="flex items-center justify-end"> <TableCell className="flex items-center justify-end">
{download.downloadLink ? ( {download.downloadLink ? (
<Link href={download.downloadLink} download={true}> <Link
<Button variant={"ghost"} className=""> href={download.downloadLink}
<Download className="w-4 h-4 mr-2" /> download={true}
Download className={`${buttonVariants({ variant: "ghost" })}`}
</Button> >
<Download className="w-4 h-4 mr-2" />
Download
</Link> </Link>
) : ( ) : (
<Button variant={"ghost"} disabled> <Button variant={"ghost"} disabled>

View file

@ -1,4 +1,4 @@
import { Button } from "@/components/ui/button"; import { buttonVariants } from "@/components/ui/button";
import { import {
Table, Table,
TableBody, TableBody,
@ -83,11 +83,13 @@ const ModsPage = async () => {
<TableCell>{download.version}</TableCell> <TableCell>{download.version}</TableCell>
<TableCell className="text-left">{download.fileSize}</TableCell> <TableCell className="text-left">{download.fileSize}</TableCell>
<TableCell className="flex items-center justify-end"> <TableCell className="flex items-center justify-end">
<Link href={download.downloadLink} download={true}> <Link
<Button variant={"ghost"} className=""> href={download.downloadLink}
<Download className="w-4 h-4 mr-2" /> download={true}
Download className={`${buttonVariants({ variant: "ghost" })}`}
</Button> >
<Download className="w-4 h-4 mr-2" />
Download
</Link> </Link>
</TableCell> </TableCell>
</TableRow> </TableRow>