-
Notifications
You must be signed in to change notification settings - Fork 4
/
mySetting.html
148 lines (113 loc) · 3.63 KB
/
mySetting.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Settings</title>
<style>
#sam_main_div{
/* display: flex; */
margin: auto;
justify-content: center;
/* border: 2px solid blue; */
height: 400px;
width: 40%;
margin-top: 100px;
}
#sam_heading_div{
/* border: 2px solid red; */
height: 80px;
width: 200px;
margin-bottom: -10px;
}
#sam_heading_div > h1{
color:rgba(23, 20, 20, 0.942);
font-size: 20px;
font-family: sans-serif;
font-weight:lighter;
}
.sam_para{
color: grey;
font-family: sans-serif;
font-size: 14px;
}
#sam_name,#sam_email,#sam_number{
color: grey;
font-family: sans-serif;
font-weight: lighter;
}
#sam_ist,#sam_2nd,#sam_3rd{
margin-bottom: 30px;
}
#btn{
color: white;
background-color: #DC3226;
border: none;
padding: 12px 15px;
}
#btn:hover{
cursor: pointer;
}
</style>
</head>
<body>
<div id="navbar"></div>
<div id="sam_main_div">
<div id="sam_heading_div"><h1>My Settings </h1></div>
<div id="container">
<hr id="sam_ist">
<hr id="sam_2nd">
<hr id="sam_3rd">
</div>
</div>
<div id="footer"></div>
</body>
</html>
<script type="module">
import navbar1 from "./components/scripts/navbar.js";
import footer1 from "./components/scripts/footer.js";
document.querySelector("#navbar").innerHTML = navbar1();
document.querySelector("#footer").innerHTML = footer1();
function kau_myfunc() {
let div = document.querySelector("#kau_show-on-hover");
div.classList.toggle("kau_show");
console.log("kau_button")
}
document.querySelector("#kau_button").addEventListener("click", kau_myfunc)
let userData = JSON.parse(localStorage.getItem('isLogin'));
let num11 = JSON.parse(localStorage.getItem('num11'));
console.log(userData);
let append = (userData) =>{
let container = document.getElementById('container');
let name = document.createElement('p');
name.innerText = "What's your name?* "
name.setAttribute('class','sam_para');
let userName = document.createElement('h3');
userName.innerText = userData.userName;
userName.setAttribute('id','sam_name');
let sam_ist = document.getElementById('sam_ist');
let mail = document.createElement('p');
mail.innerText = "Email address* "
mail.setAttribute('class','sam_para');
let email = document.createElement('h3');
email.innerText = userData.email;
email.setAttribute('id','sam_email');
let sam_2nd = document.getElementById('sam_2nd');
let num = document.createElement('p');
num.innerText = "Mobile Number* "
num.setAttribute('class','sam_para');
let number = document.createElement('h3');
number.innerText = num11;
number.setAttribute('id','sam_number');
let sam_3rd = document.getElementById('sam_3rd');
let btn = document.createElement('button');
btn.innerText = "Change Password";
btn.setAttribute('id','btn');
btn.addEventListener('click',function(){
window.location.href ="changePassWord.html";
})
container.append(name,userName,sam_ist, mail,email,sam_2nd, num,number,sam_3rd,btn);
}
append(userData);
</script>