From 6ef5bd54d5cdea80adc6972dbcb662908b3e39dd Mon Sep 17 00:00:00 2001
From: real-zephex <zephex-1@outlook.com>
Date: Sun, 19 May 2024 08:00:13 +0530
Subject: added series support

---
 src/app/web-series/components/searchResults.jsx | 35 +++++++++++++++++++++++++
 1 file changed, 35 insertions(+)
 create mode 100644 src/app/web-series/components/searchResults.jsx

(limited to 'src/app/web-series/components/searchResults.jsx')

diff --git a/src/app/web-series/components/searchResults.jsx b/src/app/web-series/components/searchResults.jsx
new file mode 100644
index 0000000..d1564e0
--- /dev/null
+++ b/src/app/web-series/components/searchResults.jsx
@@ -0,0 +1,35 @@
+"use server";
+
+import Link from "next/link";
+import Image from "next/image";
+import styles from "../styles/search.module.css";
+import PreFecthSeriesInfo from "./cacher";
+
+const SearchResults = async (data) => {
+	PreFecthSeriesInfo(data);
+	return (
+		<div className={styles.SearchedSeriesContainer}>
+			{data &&
+				data.results.map((item, index) => (
+					<Link
+						key={index}
+						style={{ color: "white", textDecoration: "none" }}
+						href={`/web-series/${item.id}`}
+						title={item.name}
+					>
+						<div className={styles.SearchedSeriesEntry}>
+							<Image
+								src={`https://sup-proxy.zephex0-f6c.workers.dev/api-content?url=https://image.tmdb.org/t/p/original${item.poster_path}`}
+								width={160}
+								height={247}
+								alt="Searched Series Poster"
+							/>
+							<p>{item.name}</p>
+						</div>
+					</Link>
+				))}
+		</div>
+	);
+};
+
+export default SearchResults;
-- 
cgit v1.2.3

