File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22
33import { Github , Upload } from "lucide-react" ;
44import Link from "next/link" ;
5+ import Dropzone from "react-dropzone" ;
56
67export default function Home ( ) {
78 return (
@@ -14,13 +15,22 @@ export default function Home() {
1415 </ h2 >
1516
1617 { /* Drop Zone */ }
17- < div className = "border-2 px-1/2 py-30 flex flex-col gap-8 items-center justify-center w-1/2 border-dashed rounded-3xl mt-12 text-lg hover:cursor-pointer" >
18- < Upload size = { 50 } > </ Upload >
19- Drag & drop your followers . json & following . json files here
20- < span > or</ span >
21- < button className = "border-1 px-4 py-2 text-lg rounded-xl hover:cursor-pointer transition hover:scale-105" > Select Files</ button >
22- </ div >
23-
18+ < Dropzone onDrop = { ( acceptedFiles ) => console . log ( acceptedFiles ) } >
19+ { ( { getRootProps, getInputProps } ) => (
20+ < div
21+ { ...getRootProps ( ) }
22+ className = "border-2 px-1/2 py-30 flex flex-col gap-8 items-center justify-center w-1/2 border-dashed rounded-3xl mt-12 text-lg hover:cursor-pointer"
23+ >
24+ < input { ...getInputProps ( ) } > </ input >
25+ < Upload size = { 50 } > </ Upload >
26+ Drag & drop your followers . json & following . json files here
27+ < span > or</ span >
28+ < button className = "border-1 px-4 py-2 text-lg rounded-xl hover:cursor-pointer transition hover:scale-105" >
29+ Select Files
30+ </ button >
31+ </ div >
32+ ) }
33+ </ Dropzone >
2434 < Link href = "/tutorial" className = "underline" >
2535 { " " }
2636 Don't have your files? Here's how to get them.
You can’t perform that action at this time.
0 commit comments