mirror of
https://github.com/zadam/trilium.git
synced 2025-11-06 13:26:01 +01:00
chore(website): reimplement download button
This commit is contained in:
17
apps/website3/src/components/DownloadButton.tsx
Normal file
17
apps/website3/src/components/DownloadButton.tsx
Normal file
@@ -0,0 +1,17 @@
|
||||
import { useLayoutEffect } from "preact/hooks";
|
||||
import { getRecommendedDownload } from "../download-helper";
|
||||
|
||||
interface DownloadButtonProps {
|
||||
big?: boolean;
|
||||
}
|
||||
|
||||
const { architecture, platform, url } = getRecommendedDownload();
|
||||
|
||||
export default function DownloadButton({ big }: DownloadButtonProps) {
|
||||
return (
|
||||
<a className={`download-button ${big ? "big" : ""}`} href={url}>
|
||||
Download now{" "}
|
||||
<span class="platform">{platform} {architecture}</span>
|
||||
</a>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user