From d7bcd93efcd4f1ae20678d0efa6777cfadc09a4e Mon Sep 17 00:00:00 2001
From: Armand Philippot <git@armandphilippot.com>
Date: Fri, 10 Nov 2023 12:16:59 +0100
Subject: refactor(components): replace Overview with ProjectOverview component

* `cover` prop is now expecting a ReactElement (NextImage)
* `meta` prop is now limited to a specific set of meta items
* add a `name` prop to add an accessible name to the figure element
---
 src/components/organisms/layout/overview.tsx | 44 ----------------------------
 1 file changed, 44 deletions(-)
 delete mode 100644 src/components/organisms/layout/overview.tsx

(limited to 'src/components/organisms/layout/overview.tsx')

diff --git a/src/components/organisms/layout/overview.tsx b/src/components/organisms/layout/overview.tsx
deleted file mode 100644
index ede2627..0000000
--- a/src/components/organisms/layout/overview.tsx
+++ /dev/null
@@ -1,44 +0,0 @@
-import NextImage, { type ImageProps as NextImageProps } from 'next/image';
-import type { FC } from 'react';
-import { Figure } from '../../atoms';
-import { MetaList, type MetaItemData } from '../../molecules';
-import styles from './overview.module.scss';
-
-export type OverviewProps = {
-  /**
-   * Set additional classnames to the overview wrapper.
-   */
-  className?: string;
-  /**
-   * The overview cover.
-   */
-  cover?: Pick<NextImageProps, 'alt' | 'src' | 'width' | 'height'>;
-  /**
-   * The overview meta.
-   */
-  meta: MetaItemData[];
-};
-
-/**
- * Overview component
- *
- * Render an overview.
- */
-export const Overview: FC<OverviewProps> = ({
-  className = '',
-  cover,
-  meta,
-}) => {
-  const wrapperClass = `${styles.wrapper} ${className}`;
-
-  return (
-    <div className={wrapperClass}>
-      {cover ? (
-        <Figure>
-          <NextImage {...cover} className={styles.cover} />
-        </Figure>
-      ) : null}
-      <MetaList className={styles.meta} hasInlinedValues items={meta} />
-    </div>
-  );
-};
-- 
cgit v1.2.3

