Files
ring-mqtt/web/account-error.html
tsightler 3aae37391f Merge changes for 3.2.0 (#86)
* Fix typo for motion status of beam devices (#85)
* Refactor auth/token generation and storage
* Add some basic error handling to token web UI
* Move config processing to a function
* Move token refresh processing to a function
2020-08-09 23:14:53 -04:00

84 lines
1.9 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
body {font-family: Arial, Helvetica, sans-serif; max-width: 500px;}
* {box-sizing: border-box;}
input[type=text], select, textarea {
width: 100%;
padding: 12px;
border: 1px solid #ccc;
border-radius: 4px;
box-sizing: border-box;
margin-top: 6px;
margin-bottom: 16px;
resize: vertical;
}
input[type=password], select, textarea {
width: 100%;
padding: 12px;
border: 1px solid #ccc;
border-radius: 4px;
box-sizing: border-box;
margin-top: 6px;
margin-bottom: 16px;
resize: vertical;
}
input[type=submit] {
background-color: #47a9e6;
color: white;
padding: 12px 20px;
border: none;
border-radius: 4px;
cursor: pointer;
}
input[type=submit]:hover {
background-color: #315b82;
}
.container {
max-width: 500px;
border-radius: 5px;
background-color: #f2f2f2;
padding: 20px;
}
</style>
</head>
<body>
<h3>Acquire Refresh Token</h3>
Use this form to acquire a refresh token from Ring.com. Submit the login information for the desired account and then the 2FA code. Upon succesful 2FA authentication the refresh token will be displayed. Simply copy the entire string and paste into the config file.<br>
<br>
<p style="color:Red;">Authentication Failed. Check the username/password and try again.</p>
<h3>Login</h3>
<div class="container">
<form action="/submit-account" method="post">
<label for="email">Email</label>
<input type="text" id="email" name="email">
<label for="password">Password</label>
<input type="password" id="password" name="password">
<input type="checkbox" onclick="myFunction()">Show Password
<br><br>
<input type="submit" value="Submit">
</form>
</div>
<script>
function myFunction() {
var x = document.getElementById("password");
if (x.type === "password") {
x.type = "text";
} else {
x.type = "password";
}
}
</script>
</body>
</html>