22'use client' ;
33import { useState } from "react" ;
44import { useRouter } from "next/navigation" ;
5+ import WaveDesign from "../wave/wave_design" ;
6+ import { ArrowLeftIcon } from "lucide-react" ;
7+ import Link from "next/link" ;
58
69export default function AddItemPage ( ) {
710 const router = useRouter ( ) ;
@@ -29,60 +32,68 @@ export default function AddItemPage() {
2932 ) ;
3033
3134 // Redirect back to the LostFound page
32- router . push ( "/lost-found " ) ;
35+ router . push ( "/lost" ) ;
3336 } ;
3437
3538 return (
36- < div className = "p-4 max-w-md mx-auto" >
37- < h1 className = "text-3xl font-bold mb-6 text-center" > Lost & Found </ h1 >
38- < h1 className = "text-2xl font-bold mb-2" > Add Details</ h1 >
39- < label className = "block border-2 border-black rounded-lg p-6 text-center cursor-pointer hover:bg-gray-300 mb-4" >
40- < span className = "text-sm font-medium underline" > Upload image</ span >
39+ < div className = "p-4" >
40+ < div className = "md:flex" >
41+ < div className = "flex items-center justify-center border-[1px] border-black rounded-full w-[40px] h-[40px]" >
42+ < Link href = { `/lost` } > < ArrowLeftIcon /> </ Link >
43+ </ div >
44+ < h1 className = "text-3xl font-bold text-center md:ml-[530px]" > Lost & Found </ h1 >
45+ </ div >
46+ < WaveDesign className = " h-[20px] ml-[53px] md:ml-[42%]" />
47+ < h1 className = "text-2xl font-bold mb-2 ml-[150px]" > Add Details</ h1 >
48+ < div className = "px-[20px] md:px-[150px]" >
49+ < label className = "block border-[1px] border-black h-[100px] md:h-[70px] rounded-lg p-6 text-center cursor-pointer bg-gray-300 mb-3" >
50+ < span className = "text-sm font-medium underline" > Upload image</ span >
51+ < input
52+ type = "file"
53+ accept = "image/*"
54+ className = "hidden"
55+ />
56+ </ label >
57+ < h6 className = "text-sm font-medium mb-1" > Item Name</ h6 >
58+ < input
59+ type = "text"
60+ placeholder = "Item Name"
61+ className = "w-full p-2 border-[1px] border-black/[0.5] hover:border-black rounded-lg mb-1"
62+ value = { name }
63+ onChange = { ( e ) => setName ( e . target . value ) }
64+ />
65+ < h6 className = "text-sm font-medium mb-1" > Description</ h6 >
66+ < textarea
67+ placeholder = "Description"
68+ className = "w-full p-2 border-[1px] border-black/[0.5] hover:border-black rounded-lg mb-1"
69+ value = { description }
70+ onChange = { ( e ) => setDescription ( e . target . value ) }
71+ />
72+ < h6 className = "text-sm font-medium mb-1" > Last Seen Place</ h6 >
73+ < input
74+ type = "text"
75+ placeholder = "Last Seen Place"
76+ className = "w-full p-2 border-[1px] border-black/[0.5] hover:border-black rounded-lg mb-1"
77+ value = { lastSeenPlace }
78+ onChange = { ( e ) => setLastSeenPlace ( e . target . value ) }
79+ />
80+ < h6 className = "text-sm font-medium mb-1" > Contact Info</ h6 >
4181 < input
42- type = "file"
43- accept = "image/*"
44- className = "hidden"
82+ type = "text"
83+ placeholder = "Mobile Number"
84+ className = "w-full p-2 border-[1px] border-black/[0.5] hover:border-black rounded-lg mb-1"
85+ value = { contactInfo }
86+ onChange = { ( e ) => setContactInfo ( e . target . value ) }
4587 />
46- </ label >
47- < h6 className = "text-sm font-medium mb-1" > Item Name</ h6 >
48- < input
49- type = "text"
50- placeholder = "Item Name"
51- className = "w-full p-2 border-2 border-black rounded-lg mb-4"
52- value = { name }
53- onChange = { ( e ) => setName ( e . target . value ) }
54- />
55- < h6 className = "text-sm font-medium mb-1" > Description</ h6 >
56- < textarea
57- placeholder = "Description"
58- className = "w-full p-2 border-2 border-black rounded-lg mb-4"
59- value = { description }
60- onChange = { ( e ) => setDescription ( e . target . value ) }
61- />
62- < h6 className = "text-sm font-medium mb-1" > Last Seen Place</ h6 >
63- < input
64- type = "text"
65- placeholder = "Last Seen Place"
66- className = "w-full p-2 border-2 border-black rounded-lg mb-4"
67- value = { lastSeenPlace }
68- onChange = { ( e ) => setLastSeenPlace ( e . target . value ) }
69- />
70- < h6 className = "text-sm font-medium mb-1" > Contact Info</ h6 >
71- < input
72- type = "text"
73- placeholder = "Mobile Number"
74- className = "w-full p-2 border-2 border-black rounded-lg mb-4"
75- value = { contactInfo }
76- onChange = { ( e ) => setContactInfo ( e . target . value ) }
77- />
78- < div className = "flex justify-center" >
79- < button
80- className = "w-[120px] border-2 border-black text-black py-2 rounded-lg hover:bg-blue-700"
81- onClick = { handleSave }
82- >
83- Confirm
84- </ button >
88+ < div className = "flex justify-center" >
89+ < button
90+ className = "w-[150px] mt-[10px] h-[40px] border-[1px] border-black text-black py-2 rounded-lg bg-[var(--main)]"
91+ onClick = { handleSave }
92+ >
93+ Confirm
94+ </ button >
95+ </ div >
8596 </ div >
8697 </ div >
8798 ) ;
88- }
99+ }
0 commit comments