From b0a0903fdb269eb880a94d709b37ec648c135ee1 Mon Sep 17 00:00:00 2001 From: sirin Date: Thu, 12 Sep 2024 12:54:20 +0700 Subject: [PATCH] Use Next Image instead of img + reinstall radix-ui/react-hover-card --- package-lock.json | 31 +++++++++++ package.json | 1 + src/app/invest/page.tsx | 112 ++++++++++++++++++++++++---------------- 3 files changed, 100 insertions(+), 44 deletions(-) diff --git a/package-lock.json b/package-lock.json index 946cb5f..85cf0e6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10,6 +10,7 @@ "dependencies": { "@radix-ui/react-avatar": "^1.1.0", "@radix-ui/react-dropdown-menu": "^2.1.1", + "@radix-ui/react-hover-card": "^1.1.1", "@radix-ui/react-navigation-menu": "^1.2.0", "@radix-ui/react-progress": "^1.1.0", "@radix-ui/react-select": "^2.1.1", @@ -666,6 +667,36 @@ } } }, + "node_modules/@radix-ui/react-hover-card": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-hover-card/-/react-hover-card-1.1.1.tgz", + "integrity": "sha512-IwzAOP97hQpDADYVKrEEHUH/b2LA+9MgB0LgdmnbFO2u/3M5hmEofjjr2M6CyzUblaAqJdFm6B7oFtU72DPXrA==", + "dependencies": { + "@radix-ui/primitive": "1.1.0", + "@radix-ui/react-compose-refs": "1.1.0", + "@radix-ui/react-context": "1.1.0", + "@radix-ui/react-dismissable-layer": "1.1.0", + "@radix-ui/react-popper": "1.2.0", + "@radix-ui/react-portal": "1.1.1", + "@radix-ui/react-presence": "1.1.0", + "@radix-ui/react-primitive": "2.0.0", + "@radix-ui/react-use-controllable-state": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", + "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, "node_modules/@radix-ui/react-id": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@radix-ui/react-id/-/react-id-1.1.0.tgz", diff --git a/package.json b/package.json index 9a28531..c97d094 100644 --- a/package.json +++ b/package.json @@ -11,6 +11,7 @@ "dependencies": { "@radix-ui/react-avatar": "^1.1.0", "@radix-ui/react-dropdown-menu": "^2.1.1", + "@radix-ui/react-hover-card": "^1.1.1", "@radix-ui/react-navigation-menu": "^1.2.0", "@radix-ui/react-progress": "^1.1.0", "@radix-ui/react-select": "^2.1.1", diff --git a/src/app/invest/page.tsx b/src/app/invest/page.tsx index 1605850..aead347 100644 --- a/src/app/invest/page.tsx +++ b/src/app/invest/page.tsx @@ -2,13 +2,7 @@ import React, { useState, useEffect } from "react"; import Image from "next/image"; -import { - Carousel, - CarouselContent, - CarouselItem, - CarouselNext, - CarouselPrevious, -} from "@/components/ui/carousel"; +import { Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious } from "@/components/ui/carousel"; import { Card, CardContent } from "@/components/ui/card"; import CountUp from "react-countup"; import { Progress } from "@/components/ui/progress"; @@ -34,13 +28,10 @@ export default function Invest() { logo

NVIDIA

-

World's first non-metal sustainable battery

+

Worlds first non-metal sustainable battery

{["Technology", "Gaming"].map((tag) => ( - + {tag} ))} @@ -48,10 +39,18 @@ export default function Invest() {
{/* image carousel */} - + {Array.from({ length: 5 }).map((_, index) => ( - + ))} {" "} @@ -61,13 +60,7 @@ export default function Invest() {

- +

5% raised of $5M max goal

@@ -87,23 +80,63 @@ export default function Invest() {
- + {/* boiler plate for an actual pictures */} - - + + - - + + - - + + - - + + - - + + @@ -112,26 +145,17 @@ export default function Invest() {