1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2024-12-23 08:14:45 +00:00
FairEmail/oauth/index.html
2024-01-01 08:50:49 +01:00

59 lines
2.5 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>FairEmail - OAuth</title>
<link rel="shortcut icon" href="https://raw.githubusercontent.com/M66B/FairEmail/master/app/src/main/ic_launcher-web.png">
<meta name="theme-color" content="#006db3">
<meta name="viewport" content="width=device-width,minimum-scale=1,initial-scale=1">
<meta name="description" content="FairEmail - OAuth">
<meta name="author" content="M66B">
<meta name="robots" content="noindex">
<style>
* { font-family: Arial, Helvetica, sans-serif; }
body { padding-left: 10px; padding-right: 10px; }
.error { color: red; font-weight: bold; }
.button-large { width: 120px; height: 30px; font-weight: bold; }
</style>
<script>
window.addEventListener('load', load);
function load() {
document.getElementById('oauth').addEventListener('click', oauth);
document.getElementById('year').textContent = new Date().getFullYear();
try {
var url = new URL(window.location.href);
var error = url.searchParams.get('error');
if (error) {
document.getElementById('errmsg').innerText = error;
document.getElementById('error').style.display = 'block';
}
} catch (error) {
console.error(error);
}
document.getElementById('debug').innerText = window.location.search;
document.getElementById('debug').style.display = 'none';
}
function oauth() {
document.location.href = 'eu.faircode.email://oauth' + window.location.search;
}
</script>
</head>
<body>
<h1>FairEmail</h1>
<p><img src="https://raw.githubusercontent.com/M66B/FairEmail/master/app/src/main/ic_launcher-web.png" alt="FairEmail" height="72" width="72"></p>
<h2>&#x1F6E1; OAuth</h2>
<p id="error" style="display: none;"><span>The email server said: <span id="errmsg" class="error"></span></span></p>
<p><button id="oauth" class="button-large">Continue</button> to the app</p>
<p id="debug" style="display: none; font-size: x-small;"></p>
<noscript><h2>Please enable JavaScript or disable your ad blocker</h2></noscript>
<br>
<p style="font-size: smaller;"><a href="https://en.wikipedia.org/wiki/OAuth" target="_blank">What is OAuth?</a></p>
<p><a href="https://github.com/M66B/open-source-email/blob/master/PRIVACY.md" target="_blank">Privacy policy</a></p>
<p>Copyright &copy; 2018&ndash;<span id="year">2024</span> by Marcel Bokhorst (M66B)</p>
<p style="font-size: smaller;">This page is <a href="https://github.com/M66B/FairEmail/blob/master/oauth/index.html" target="_blank">open source</a>.</p>
</body>
</html>