mirror of
https://github.com/zadam/trilium.git
synced 2025-11-06 21:36:05 +01:00
feat(website): improve download button with icon and platform title
This commit is contained in:
@@ -1,17 +1,24 @@
|
||||
import { getRecommendedDownload } from "../download-helper";
|
||||
import "./DownloadButton.css";
|
||||
import Button from "./Button";
|
||||
import downloadIcon from "../assets/boxicons/bx-arrow-in-down-square-half.svg?raw";
|
||||
|
||||
interface DownloadButtonProps {
|
||||
big?: boolean;
|
||||
}
|
||||
|
||||
const { architecture, platform, url } = getRecommendedDownload();
|
||||
const { name, 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>
|
||||
<Button
|
||||
className={`download-button ${big ? "big" : ""}`}
|
||||
href={url}
|
||||
iconSvg={downloadIcon}
|
||||
text={<>
|
||||
Download now{" "}
|
||||
<span class="platform">for {name}</span>
|
||||
</>}
|
||||
/>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user