Added new files

This commit is contained in:
Tracker-Friendly 2024-05-03 17:55:17 +01:00
parent 6c46254988
commit 3edc9191a6
20 changed files with 468 additions and 0 deletions

BIN
static/political.webm Normal file

Binary file not shown.

View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Error!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="main a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Error!</h1>
<p1>An unkown error has occured, please try again later!</p1>
<div class=spacer2>
<a class="button" href="/account">Go Back</a>
</div>
</div>
</body></html>

22
templates/badcaptcha.html Normal file
View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Error!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="main a" href="/signup">Sign up</a>
<a class="a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Error!</h1>
<p1>Incorrect CAPTCHA!</p1>
<div class=spacer2>
<a class="button" href="/signup">Go Back</a>
</div>
</div>
</body></html>

View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Error!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="main a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Error!</h1>
<p1>Your password is incorrect!</p1>
<div class=spacer2>
<a class="button" href="/account">Go Back</a>
</div>
</div>
</body></html>

22
templates/baduser.html Normal file
View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Error!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="main a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Error!</h1>
<p1>Your username is incorrect!</p1>
<div class=spacer2>
<a class="button" href="/account">Go Back</a>
</div>
</div>
</body></html>

22
templates/changepass.html Normal file
View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Change password</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="main a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Change password</h1>
<input type="password" id="newpass">
<div class=spacer2>
<button class="button" onclick="changepass()">Submit</button>
</div>
</div>
</body></html>

22
templates/cta.html Normal file
View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>???</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="main a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>You found an egg!</h1>
<p1>Such political, much policy</p1>
<br>
<iframe style="border: 0;" src="/static/political.webm"></iframe>
</div>
</body></html>

25
templates/dashboard.html Normal file
View File

@ -0,0 +1,25 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Dashboard</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="main a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Account management</h1>
<p1 id="username">Loading...</p1>
<br>
<br>
<a class="button" href="/account/changepass">Change password</a>
<a class="button" href="/account/deleteacct">Delete account</a>
<a class="button logout" href="/account/logout">Logout</a>
</div>
</body></html>

21
templates/deleteacct.html Normal file
View File

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Delete account?</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="main a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Are you SURE you would like to delete your account?</h1>
<a class="button" href="/account">Whoops, wrong button, bring me back to the safe zone!</a>
<br>
<button style=" margin-top: 20px;" class="button" onclick="deleteacct()">Yes, I understand this is permanent and cannot be undone!</button>
</div>
</body></html>

32
templates/index.html Executable file
View File

@ -0,0 +1,32 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>CTAMail</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="main a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<li><h1>Welcome to CTAMail!</h1></li>
<li><p1>CTAMail is a Free, Open Source, and privacy respecting email service.</p1></li>
<br>
<li><p1>CTAMail supports IMAP and SMTP, on all SSL standards, on all standard ports.</p1></li>
<li><p1>You have unlimited</p1></li>
<h1>Email Setup</h1>
<p1>Hostname: mail.cta.social</p1>
<br>
<p1>SMTP: Port 465 (SSL/TLS), 587 (StartTLS) or 25 (PlainText, not recommended)</p1>
<br>
<p1>IMAP: Port 993 (SSL/TLS) or 143 (StartTLS)</p1>
<br>
<p1>Login: Normal Password</p1>
<h1>Great! How much is it?</h1>
<p1>CTAMail is fully Free and Open Source! Enjoy CTAMail as much as you want, whenever you want!</p1>
</div>
</body></html>

View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Error!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="main a" href="/signup">Sign up</a>
<a class="a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Error!</h1>
<p1>Your CAPTCHA has expired! Please use the provided Go Back button instead of the back arrow!</p1>
<div class=spacer2>
<a class="button" href="/signup">Go Back</a>
</div>
</div>
</body></html>

View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Error!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="main a" href="/signup">Sign up</a>
<a class="a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Error!</h1>
<p1>You can only have Alphanumerical characters and periods in your username!</p1>
<div class=spacer2>
<a class="button" href="/signup">Go Back</a>
</div>
</div>
</body></html>

31
templates/login.html Normal file
View File

@ -0,0 +1,31 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Login</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="main a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Login to your Email Account</h1>
<label>Username</label>
<div class="spacer">
<input type="text" id="username" required="">
</div>
<br>
<div class="Password">
<label>Password</label>
<div class="spacer">
<input type="password" id="password" required="">
</div>
</div>
<br>
<button class="button" onclick="login()">Login</button>
</div>
</body></html>

22
templates/loginerror.html Normal file
View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Error!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="main a" href="/signup">Sign up</a>
<a class="a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Error!</h1>
<p1>An unkown error has occured, please try again later!</p1>
<div class=spacer2>
<a class="button" href="/signup">Go Back</a>
</div>
</div>
</body></html>

23
templates/logout.html Normal file
View File

@ -0,0 +1,23 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Logging out...</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="main a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Logging out...</h1>
<p1 id="logout"></p1>
<br>
<div class=spacer2>
<a class="button" href="/dashboard">Cancel</a>
</div>
</div>
</body></html>

44
templates/signup.html Normal file
View File

@ -0,0 +1,44 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Sign Up</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="main a" href="/signup">Sign up</a>
<a class="a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Register an Email Account</h1>
<label>Username</label>
<div class="spacer">
<input type="text" id="username" required="">
</div>
<br>
<div class="Password">
<label>Password</label>
<div class="spacer">
<input type="password" id="password" required="">
</div>
</div>
<br>
<div class="spacer">
<label>CAPTCHA</label>
<div class="spacer">
<img src="data:image/png;base64,{{ .captcha_image }}" alt="Captcha">
</div>
<div class="spacer">
<input required="" id="captcha" type="text">
</div>
</div>
<br>
<input type="hidden" id="unique_token" name="unique_token" value="{{ .unique_token }}">
<button class="button" onclick="signup();">Register</button>
</div>
</body>
</html>

View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Error!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="main a" href="/signup">Sign up</a>
<a class="a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Error!</h1>
<p1>An unkown error has occured, please try again later!</p1>
<div class=spacer2>
<a class="button" href="/signup">Go Back</a>
</div>
</div>
</body></html>

28
templates/success.html Normal file
View File

@ -0,0 +1,28 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Success!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="main a" href="/signup">Sign up</a>
<a class="a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Success!</h1>
<p1>Congratulations! Your account has been registered!</p1>
<h1>Email Setup</h1>
<p1>Hostname: mail.cta.social</p1>
<br>
<p1>SMTP: Port 465 (SSL/TLS), 587 (StartTLS) or 25 (PlainText, not recommended)</p1>
<br>
<p1>IMAP: Port 993 (SSL/TLS) or 143 (StartTLS)</p1>
<div class=spacer2>
<a class="button" href="https://webmail.hectabit.org">Webmail</a>
</div>
</div>
</body></html>

22
templates/taken.html Normal file
View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Error!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="main a" href="/signup">Sign up</a>
<a class="a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Error!</h1>
<p1>This username is already taken!</p1>
<div class=spacer2>
<a class="button" href="/signup">Go Back</a>
</div>
</div>
</body></html>

22
templates/usererror.html Normal file
View File

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Error!</title>
<link rel="stylesheet" href="/static/css/main.css">
<script src="/static/js/main.js"></script>
</head>
<body>
<div class="headerbar">
<a class="a" href="/">CTAMail</a>
<a class="a" href="/signup">Sign up</a>
<a class="main a" href="/account">Account</a>
<button class="a right" onclick="toggleDarkMode()">Toggle Theme</button>
</div>
<div class="content">
<h1>Error!</h1>
<p1>You have changed your password on another device. Please log out then log back in!</p1>
<div class=spacer2>
<a class="button" href="/account/logout">Logout</a>
</div>
</div>
</body></html>