aboutsummaryrefslogtreecommitdiff
path: root/src/app/movies
diff options
context:
space:
mode:
authorreal-zephex <[email protected]>2024-05-26 22:29:35 +0530
committerreal-zephex <[email protected]>2024-05-26 22:29:35 +0530
commit3da8e6263d1900571cc8565b19d1b383dfbbf631 (patch)
treec9aefb831b91e9f8c531d246be2cd88cd0af669a /src/app/movies
parent🚀 feat(download): add download feature for movies (diff)
downloaddramalama-3da8e6263d1900571cc8565b19d1b383dfbbf631.tar.xz
dramalama-3da8e6263d1900571cc8565b19d1b383dfbbf631.zip
⚡️ perf(kdrama, anime): cache video links, replace next/image
Diffstat (limited to 'src/app/movies')
-rw-r--r--src/app/movies/components/searchFormatter.jsx11
-rw-r--r--src/app/movies/page.jsx11
2 files changed, 8 insertions, 14 deletions
diff --git a/src/app/movies/components/searchFormatter.jsx b/src/app/movies/components/searchFormatter.jsx
index 47b684f..dc6afb2 100644
--- a/src/app/movies/components/searchFormatter.jsx
+++ b/src/app/movies/components/searchFormatter.jsx
@@ -1,5 +1,5 @@
-import { Card, CardHeader, CardBody, Image, Link } from "@nextui-org/react";
-import NextImage from "next/image";
+import { Card, CardHeader, CardBody, Link } from "@nextui-org/react";
+import Image from "next/image";
import styles from "../../page.module.css";
@@ -21,14 +21,11 @@ const MovieSearchFormatter = async (data) => {
<Card className="overflow-hidden" isPressable>
<CardBody>
<Image
- as={NextImage}
- isBlurred
- alt="Anime Poster"
+ alt="Searched Movie Poster"
src={`https://sup-proxy.zephex0-f6c.workers.dev/api-content?url=https://image.tmdb.org/t/p/original${item.poster_path}`}
width={190}
height={120}
- shadow="lg"
- className="h-64"
+ className="rounded-md h-64"
priority
/>
</CardBody>
diff --git a/src/app/movies/page.jsx b/src/app/movies/page.jsx
index 66ae888..417df28 100644
--- a/src/app/movies/page.jsx
+++ b/src/app/movies/page.jsx
@@ -1,5 +1,5 @@
-import { Card, CardHeader, CardBody, Image, Link } from "@nextui-org/react";
-import NextImage from "next/image";
+import { Card, CardHeader, CardBody, Link } from "@nextui-org/react";
+import Image from "next/image";
import MovieSearchBar from "./components/search";
import { MovieHomepageDataFetcher } from "./components/requestsHandler";
@@ -36,14 +36,11 @@ export default async function MovieHomepage() {
<Card className="overflow-visible " isPressable>
<CardBody>
<Image
- as={NextImage}
- isBlurred
- alt="Anime Poster"
+ alt="Movie Poster"
src={`https://sup-proxy.zephex0-f6c.workers.dev/api-content?url=https://image.tmdb.org/t/p/original${item.poster_path}`}
width={270}
height={180}
- className="h-64 overflow-hidden"
- shadow="lg"
+ className="h-64 rounded-md overflow-hidden"
priority
/>
</CardBody>