1
- import React , { useState } from "react" ;
2
- import Form from "react-bootstrap/Form" ;
3
- import Button from "react-bootstrap/Button" ;
1
+ import React from "react" ;
2
+ import { useState } from "react" ;
4
3
import '../components/Login.css' ;
5
4
import './Moreinfo.css' ;
6
- import '../components/ProfileSection/ProfileSection.css' ;
5
+ import ReactDOM from "react-dom" ;
7
6
8
- function Moreinfo ( ) {
9
- const [ email , setEmail ] = useState ( "" ) ;
10
- const [ password , setPassword ] = useState ( "" ) ;
11
-
12
- function validateForm ( ) {
13
- return email . length > 0 && password . length > 0 ;
14
- }
15
-
16
- function handleSubmit ( event ) {
17
- event . preventDefault ( ) ;
7
+
8
+ function Moreinfo ( ) {
9
+ const [ email , setEmail ] = useState ( "" ) ;
10
+ const [ password , setPassword ] = useState ( "" ) ;
11
+
12
+ function handleSubmit ( event ) {
13
+ event . preventDefault ( ) ;
14
+ }
15
+ //Uploading Profile Pic
16
+ const uploadedImage = React . useRef ( null ) ;
17
+ const imageUploader = React . useRef ( null ) ;
18
+
19
+ const handleImageUpload = e => {
20
+ const [ file ] = e . target . files ;
21
+ if ( file ) {
22
+ const reader = new FileReader ( ) ;
23
+ const { current } = uploadedImage ;
24
+ current . file = file ;
25
+ reader . onload = e => {
26
+ current . src = e . target . result ;
27
+ } ;
28
+ reader . readAsDataURL ( file ) ;
18
29
}
19
-
20
- return (
21
- < >
22
- < section id = "profile" >
23
-
24
- < main className = "frm" >
25
- < div class = "pfp" >
26
- < img src = "http:\\placehold.it\1000x1000" class = "pfpimg" > </ img >
27
- </ div >
28
- < div className = "pfpdetails" >
29
- < span class = "pink" > Your Name</ span >
30
- +91 1023456789
31
- </ div >
32
- < div class = "frmmain" >
33
- < span class = "pink" > About me</ span >
34
- < input type = "text" class = "input" > </ input >
35
- < span class = "pink" > Expectations</ span >
36
- < input type = "text" class = "input" > </ input >
37
- < span class = "pink" > Gender</ span >
38
- < label class = "container opt1" >
39
- Male
40
- < input type = "radio" name = "radio" > </ input >
41
- < span class = "checkmark" > </ span >
42
- </ label >
43
- < label class = "container" >
44
- Female
45
- < input type = "radio" name = "radio" > </ input >
46
- < span class = "checkmark" > </ span >
47
- </ label >
48
- < label class = "container" >
49
- Other
50
- < input type = "radio" name = "radio" > </ input >
51
- < span class = "checkmark" > </ span >
52
- </ label >
53
- < span class = "pink" > Timetable</ span >
54
- < input type = "file" class = "file" > </ input >
55
- </ div >
56
- </ main >
57
- </ section >
30
+ } ;
31
+ //Redirecting to another page after submitting
32
+
33
+ return (
34
+ < >
35
+ < div className = "MoreInfoTitle my-4" >
36
+ < h2 className = "text-center" > Tell Us About Yourself !</ h2 >
37
+ </ div >
58
38
59
- < div className = "infomsg" >
60
- < h3 > Tell us about you</ h3 >
39
+ < div className = "container MoreInfoProfile" >
40
+ < form method = " " onSubmit = { this . submitForm . bind ( this ) } >
41
+ < div className = "row" >
42
+ < div className = "col-md-4 mt-4 mb-3 mx-3 img-div" >
43
+ < input type = "file" accept = "image/*" onChange = { handleImageUpload } ref = { imageUploader } style = { { display : "none" } } />
44
+ < div className = "img-div" onClick = { ( ) => imageUploader . current . click ( ) } >
45
+ < img
46
+ src = "https://cdn.pixabay.com/photo/2015/10/05/22/37/blank-profile-picture-973460_1280.png"
47
+ ref = { uploadedImage }
48
+ style = { {
49
+ width : "100%" ,
50
+ height : "100%" ,
51
+ position : "absolute" ,
52
+ } }
53
+ />
54
+ </ div >
55
+ </ div >
56
+
57
+ < div className = "col-md-6 mt-3" >
58
+ < div className = "profile-head mt-3" >
59
+ < div className = "row mb-3" >
60
+ < div className = "col" >
61
+ < input type = "text" className = "form-control input-sm" placeholder = "Your Name" aria-label = "First name" />
62
+ </ div >
63
+ < div className = "col" >
64
+ < input type = "number" className = "form-control input-sm" placeholder = "Conatact Number" aria-label = "Last name" />
65
+ </ div >
66
+ </ div >
67
+ < div className = "row col-sm-6 mt-2" >
68
+ < select className = "form-select" aria-label = "Default select example" >
69
+ < option selected > Select Your Gender</ option >
70
+ < option value = "1" > Male</ option >
71
+ < option value = "2" > Female</ option >
72
+ < option value = "3" > Other</ option >
73
+ </ select >
74
+ </ div >
75
+
76
+ < div className = "mb-3 mt-4 " >
77
+ < textarea className = "form-control" id = "exampleFormControlTextarea1" rows = "3" placeholder = "Share a few lines about yourself " > </ textarea >
78
+ </ div >
79
+ < div className = "mb-3 mt-4 " >
80
+ < textarea className = "form-control" id = "exampleFormControlTextarea1" rows = "3" placeholder = "Mention Some of your Qualities " > </ textarea >
81
+ </ div >
82
+
83
+ < div className = "col-14 mb-4 " >
84
+ < button type = "submit" className = "btn btn-dark btn-default" > Submit</ button >
85
+ </ div >
86
+
87
+ </ div >
88
+ </ div >
89
+ </ div >
90
+ </ form >
61
91
</ div >
62
- < div className = "moreinfo" >
63
- < Form onSubmit = { handleSubmit } >
64
- < Form . Group size = "lg" controlId = "email" >
65
- < Form . Label style = { { padding :"0px 0px 20px 0px" } } > Enter your full name*</ Form . Label >
66
- < Form . Control style = { { border :"0px 5px" } } className = "input"
67
- autoFocus
68
- type = "email"
69
- value = { email }
70
- onChange = { ( e ) => setEmail ( e . target . value ) }
71
- />
72
- </ Form . Group >
73
- < Form . Group size = "lg" controlId = "number" >
74
- < Form . Label style = { { padding :"0px 0px 20px 0px" } } > Enter your phone number*</ Form . Label >
75
- < Form . Control className = "input"
76
- type = "number"
77
- value = { password }
78
- onChange = { ( e ) => setPassword ( e . target . value ) }
79
- />
80
- </ Form . Group >
81
-
82
- < Button className = "moreinfobutton" block size = "lg" type = "submit" disabled = { ! validateForm ( ) } >
83
- Submit
84
- </ Button >
85
- </ Form >
92
+
93
+ < div className = "footer" >
94
+ < div className = "row" >
95
+ < div className = "footer col-lg-6" >
96
+ < div className = "cl" >
97
+ < h4 > Connect With Us </ h4 >
98
+ </ div >
99
+ </ div >
100
+
101
+ < div class = "footer-content" >
102
+ < h4 > Follow us on</ h4 >
103
+ < ul class = "socials" >
104
+ < li > < a href = "https://www.facebook.com/codechefvit/" > < i class = "fa fa-facebook-square" > </ i > </ a > </ li >
105
+ < li > < a href = "https://twitter.com/codechefvit?lang=en" > < i class = "fa fa-twitter" > </ i > </ a > </ li >
106
+ < li > < a href = "https://www.instagram.com/codechefvit/?hl=en" > < i class = "fa fa-instagram" > </ i > </ a > </ li >
107
+ < li > < a href = "https://github.com/CodeChefVIT?language=java" > < i class = "fa fa-github" > </ i > </ a > </ li >
108
+ < li > < a href = "https://www.linkedin.com/company/codechef-vit-chapter/mycompany/" > < i
109
+ class = "fa fa-linkedin-square" > </ i > </ a > </ li >
110
+ </ ul >
111
+ </ div >
112
+ < div class = "footer-bottom" >
113
+ < p > © Copyright 2021 | Made With 💜 by
114
+ < a href = "http://www.codechefvit.com" target = "_blank" >
115
+ < span > CodeChef-VIT</ span >
116
+ </ a >
117
+ </ p >
118
+ </ div >
119
+
120
+ </ div >
86
121
</ div >
87
- </ >
88
-
89
- ) ;
90
- }
91
- export default Moreinfo ;
92
-
93
-
122
+ </ >
123
+ ) ;
124
+ }
125
+ export default Moreinfo ;
126
+
0 commit comments