2024-10-04 11:15:54 +02:00
|
|
|
import { FEATURE_FLAGS } from "@common/feature-flags";
|
2022-11-11 21:39:28 +01:00
|
|
|
import React from "react";
|
2024-10-04 11:15:54 +02:00
|
|
|
import UpscaylSVGLogo from "@/components/icons/upscayl-logo-svg";
|
2024-09-01 14:01:45 +02:00
|
|
|
import { useAtomValue } from "jotai";
|
|
|
|
import { translationAtom } from "@/atoms/translations-atom";
|
2022-11-11 21:39:28 +01:00
|
|
|
|
2023-03-12 08:59:07 +01:00
|
|
|
export default function Header({ version }: { version: string }) {
|
2024-09-01 14:01:45 +02:00
|
|
|
const t = useAtomValue(translationAtom);
|
|
|
|
|
2022-11-11 21:39:28 +01:00
|
|
|
return (
|
|
|
|
<a
|
|
|
|
href="https://github.com/upscayl/upscayl"
|
|
|
|
target="_blank"
|
2023-08-30 06:54:16 +02:00
|
|
|
className={`outline-none focus-visible:ring-2`}
|
2023-09-03 11:16:48 +02:00
|
|
|
data-tooltip-id="tooltip"
|
2024-09-03 09:34:58 +02:00
|
|
|
data-tooltip-content={t("HEADER.GITHUB_BUTTON_TITLE")}
|
2024-04-24 13:08:27 +02:00
|
|
|
>
|
2022-11-11 21:39:28 +01:00
|
|
|
<div className="flex items-center gap-3 px-5 py-5">
|
2024-10-04 11:15:54 +02:00
|
|
|
<UpscaylSVGLogo className="inline-block h-14 w-14" />
|
2022-11-11 21:39:28 +01:00
|
|
|
<div className="flex flex-col justify-center">
|
2023-03-12 08:59:07 +01:00
|
|
|
<h1 className="text-3xl font-bold">
|
2024-09-05 06:51:30 +02:00
|
|
|
{t("TITLE")}{" "}
|
2024-01-19 08:55:32 +01:00
|
|
|
<span className="text-xs">
|
2024-10-04 11:15:54 +02:00
|
|
|
{version} {FEATURE_FLAGS.APP_STORE_BUILD && "Mac"}
|
2024-01-19 08:55:32 +01:00
|
|
|
</span>
|
2023-03-12 08:59:07 +01:00
|
|
|
</h1>
|
2024-09-03 09:34:58 +02:00
|
|
|
<p className="">{t("HEADER.DESCRIPTION")}</p>
|
2022-11-11 21:39:28 +01:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</a>
|
|
|
|
);
|
|
|
|
}
|