import React, { useState } from 'react'; import '../Pages/Profile.css' import dl from '../res/icon/download.png' import defaultImg from '../res/img/Person.png' import { useAuth } from '../Contexts/AuthContext'; //@ts-ignore const ProfilePDP = () => { const [selectedFile, setSelectedFile] = useState(null); const {user} = useAuth() // @ts-ignores const handleFileChange = (event) => { let file = event.target.files[0]; setSelectedFile(file); if (file) { const pdpUrl = URL.createObjectURL(file); if (user!=null){ user.profilePicture = pdpUrl } } }; return (
Selected File: {selectedFile.name}
*/}Taille recommandée : 100px
*/}