From 04c19d46f76d7359d14622b8d44fbfef6bc07732 Mon Sep 17 00:00:00 2001
From: Armand Philippot <git@armandphilippot.com>
Date: Mon, 13 Dec 2021 01:09:07 +0100
Subject: chore: add Branding component

---
 src/components/Branding/Branding.tsx | 35 +++++++++++++++++++++++++++++++++++
 1 file changed, 35 insertions(+)
 create mode 100644 src/components/Branding/Branding.tsx

(limited to 'src/components/Branding/Branding.tsx')

diff --git a/src/components/Branding/Branding.tsx b/src/components/Branding/Branding.tsx
new file mode 100644
index 0000000..e5565a4
--- /dev/null
+++ b/src/components/Branding/Branding.tsx
@@ -0,0 +1,35 @@
+import Image from 'next/image';
+import Link from 'next/link';
+import { ReactElement } from 'react';
+import { t } from '@lingui/macro';
+import photo from '@assets/images/armand-philippot.jpg';
+import { config } from '@config/website';
+import styles from './Branding.module.scss';
+
+type BrandingReturn = ({ isHome }: { isHome?: boolean }) => ReactElement;
+
+const Branding: BrandingReturn = ({ isHome = false }) => {
+  return (
+    <div className={styles.wrapper}>
+      <div className={styles.logo}>
+        <Image src={photo} alt={t`${config.name} picture`} layout="intrinsic" />
+      </div>
+      {isHome ? (
+        <h1 className={styles.name}>
+          <Link href="/">
+            <a>{config.name}</a>
+          </Link>
+        </h1>
+      ) : (
+        <p className={styles.name}>
+          <Link href="/">
+            <a>{config.name}</a>
+          </Link>
+        </p>
+      )}
+      <p className={styles.job}>{config.baseline}</p>
+    </div>
+  );
+};
+
+export default Branding;
-- 
cgit v1.2.3

