diff --git a/src/components/inputUplaod/inputUpload.tsx b/src/components/inputUplaod/inputUpload.tsx new file mode 100644 index 0000000..257b836 --- /dev/null +++ b/src/components/inputUplaod/inputUpload.tsx @@ -0,0 +1,50 @@ +import React,{ useState, useEffect } from 'react' + +import { InputUploadView } from './inputUploadView' + + +export default function InputUpload() { + const [images, setImages] = useState([] as any); + const [imageURLS, setImageURLs] = useState([]); + + useEffect(() => { + if (images.length < 1) return; + const newImageUrls: any = []; + images.forEach((image:any) => newImageUrls.push(URL.createObjectURL(image))); + setImageURLs(newImageUrls); + }, [images]); + + function onImageChange(e: any) { + setImages([...e.target.files]); + console.log(e); + } + + + + + return ( + + +
+
+ {imageURLS.map((imageSrc) => ( + not fount + ))} + +
+ + +
+ +
+
+
+ + +
+
+
+ +
+ ) +} diff --git a/src/components/inputUplaod/inputUploadView.ts b/src/components/inputUplaod/inputUploadView.ts new file mode 100644 index 0000000..7a244d0 --- /dev/null +++ b/src/components/inputUplaod/inputUploadView.ts @@ -0,0 +1,57 @@ +import styled from 'styled-components' + +export const InputUploadView = styled.button` + width: 350px; + margin-left: 63px; + height: 58px; + + border-radius: 5px; + background-color: #fff; + border: 1px solid #adacac; + + + margin-top: 13px; + +.imgContainer{ + max-width: 40px; + height: 30px; +} + + input[type="file"] { + display: none; + + } + label { + width: 169px; + height: 30px; + border-radius: 4px; + background-color: #254F7F; + color: white; + margin-left: 3px; + font-size: 13px; + font-weight: 600; + text-transform: uppercase; + display: flex; + text-align: center; + cursor: pointer; + } + .image{ + width:30px; + } + + .text{ + margin-left: 60px; + } + .update{ + margin-left: 160px; + margin-top: -29px; + } + .TitleButton{ + margin-left: 9px; + margin-top: 6px; + font-family: 'Poppins'; + } + + + +` diff --git a/src/pages/administrative/clients.tsx b/src/pages/administrative/clients.tsx index faadc66..2c607ab 100644 --- a/src/pages/administrative/clients.tsx +++ b/src/pages/administrative/clients.tsx @@ -13,6 +13,9 @@ import FaqButton2 from '../../components/buttons/faqButton/FaqButton2'; import AdministrativeHeader from '../../components/administrativeHeader/AdministrativeHeader'; import ClientsTable from '../../components/administrativeTables/ClientsTable'; import Header from '../../components/header/Header' +import { IconButton } from '@mui/material'; +import InputUpload from '../../components/inputUplaod/inputUpload' + const style = { @@ -41,6 +44,8 @@ export default function clients() { + + return (
@@ -67,7 +72,12 @@ export default function clients() { - + + + + + +

console.log()} /> console.log()}/>