-
Notifications
You must be signed in to change notification settings - Fork 0
/
resetpassword.ejs
93 lines (93 loc) · 4.52 KB
/
resetpassword.ejs
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
<!DOCTYPE html>
<html>
<head>
<title>Password Reset · <%= appname %></title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="robots" content="noindex, nofollow">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-16LE">
<meta name="theme-color" content="#216bf3" id='themecolor'>
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
<link rel="apple-touch-startup-image" href="/graphic/icons/schemester128.png">
<link rel="icon" href="/graphic/icons/schemester128.png" type="image/png" sizes="128x128">
<link rel = "stylesheet" href="/css/fmt.css">
<link rel = "stylesheet" href="/css/main.css">
<link rel = "stylesheet" href="/css/switch.css">
<link href="/font/Jost.css" rel="stylesheet">
<link href="/font/Questrial.css" rel="stylesheet">
<script src="/script/codes.js"></script>
<script src="/script/main.js"></script>
<script src="/script/resetpassword.js"></script>
</head>
<%if(user.expired) {%>
<body class="b-negative">
<div id="topBar" style="background-color: var(--negative);">
<% } else { %>
<body class="b-positive">
<div id="topBar">
<% } %>
<img src="/graphic/icons/schemester512.svg" width="40" alt="<%= appname %> icon" id="backroot">
<span>Password</span>
<img class="fmt-spin-fast fmt-circle fmt-right" style="display:none" width="40" src="/graphic/onethreeload.svg" id="navLoader"/>
<span class="fmt-right fmt-padding-small">
<label class="switch-container">
<label for="darkmode"></label>
<input type="checkbox" id="darkmode" />
<span class="switch-positive"></span>
</label>
</span>
</div>
<div class="fmt-row fmt-padding" style="margin-top: 72px;">
<div class="fmt-col container" id="workbox">
<%if(user.expired) {%>
<div class="fmt-row heading fmt-center negative">Expired</div><br/>
<div class="fmt-row questrial">
This link is no longer valid.<br/><br/>
The link that brought you here has expired now. Password reset links are only valid for 900 seconds (15 minutes).
Try sending link again, after signing in to your account.<br/><br/>
<b class="negative">Make sure to visit your reset link before it's too late.</b>
</div><br/><br/>
<div class="fmt-row">
<button class="fmt-right positive-button" id="backroot1">Return to base</button>
</div>
<% } else { %>
<div class="fmt-row heading fmt-center">Reset Password</div><br/>
<div class="fmt-row questrial">
Hey <%= user.username %>,<br/>
Set your new password for your <%= appname %> account (<%= user.id %>),
<br/>
<span class="negative">This link will expire soon.</span>
<br/>
<fieldset id="passfield">
</fieldset>
</div><br/><br/>
<div class="fmt-row fmt-center">
<img class="fmt-spin-fast" width="50" src="/graphic/blueLoader.svg" id="loader"/>
<button class="positive-button" id="savepassword">Save password</button>
</div>
<% } %>
</div>
</div>
<div id="dialogView"></div>
<div id="snackBar"></div>
<span hidden>
<span id="acsrf"><%= acsrf %></span>
<% if(user.isAdmin) { %>
<span id="client">admin</span>
<span id="uiid"><%= user.uiid %></span>
<% } else if(user.isTeacher){ %>
<span id="client">teacher</span>
<span id="uiid"><%= uiid %></span>
<% } else if(user.isStudent) { %>
<span id="client">student</span>
<span id="uiid"><%= uiid %></span>
<span id="classname"><%= classname %></span>
<% } %>
<span id="expired"><%= user.expired %></span>
<span id="email"><%= user.id %></span>
<span id="uid"><%= user.uid %></span>
<span id="username"><%= user.username %></span>
</span>
</body>
</html>