From e22b9bacbcd8e0bfc9613735be2d0315a23e7857 Mon Sep 17 00:00:00 2001 From: Sonika Date: Sun, 7 Jan 2024 20:47:20 +0530 Subject: [PATCH] admin component --- src/components/admin/Admin.tsx | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/src/components/admin/Admin.tsx b/src/components/admin/Admin.tsx index 570da56..bff68d8 100644 --- a/src/components/admin/Admin.tsx +++ b/src/components/admin/Admin.tsx @@ -1,12 +1,32 @@ -import { Box, Paper } from "@mui/material"; +import { AppBar, Box, Button, Container, CssBaseline, Paper, Toolbar, Typography } from "@mui/material"; import React from "react"; +import CloudUploadIcon from '@mui/icons-material/CloudUpload'; export default function Admin(){ + const [files, setFiles] = React.useState([]); + + const handleFileUpload = (event:any) => { + const newFiles:any = [...files, ...event.target.files]; + setFiles(newFiles); + }; return ( - {/*

hi

*/} + + + + +
    + {files.map((file:any, index:number) => ( +
  • {file.name}
  • + ))} +
+ +
+