1
0
Fork 0
mirror of https://github.com/sussy-code/smov.git synced 2024-12-26 15:37:41 +01:00
smov/src/components/player/base/BackLink.tsx

23 lines
724 B
TypeScript
Raw Normal View History

import { useTranslation } from "react-i18next";
import { Icon, Icons } from "@/components/Icon";
import { useGoBack } from "@/hooks/useGoBack";
export function BackLink() {
const { t } = useTranslation();
const goBack = useGoBack();
return (
<div className="flex items-center">
<span
onClick={() => goBack()}
className="flex items-center cursor-pointer text-type-secondary hover:text-white transition-colors duration-200 font-medium"
>
<Icon className="mr-2" icon={Icons.ARROW_LEFT} />
<span className="md:hidden">{t("videoPlayer.backToHomeShort")}</span>
<span className="hidden md:block">{t("videoPlayer.backToHome")}</span>
</span>
</div>
);
}