2017-10-14 23:31:44 -04:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html lang="en">
|
2018-12-23 10:57:40 +01:00
|
|
|
<head>
|
|
|
|
<meta charset="utf-8">
|
2018-12-30 19:02:42 +01:00
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
|
2024-09-08 18:12:16 +03:00
|
|
|
<title><%= t("login.title") %></title>
|
2022-10-26 23:50:54 +02:00
|
|
|
<link rel="apple-touch-icon" sizes="180x180" href="<%= assetPath %>/images/app-icons/ios/apple-touch-icon.png">
|
2020-04-03 19:34:22 +02:00
|
|
|
<link rel="shortcut icon" href="favicon.ico">
|
2025-03-08 20:53:54 +02:00
|
|
|
<style>
|
|
|
|
.login-page {
|
|
|
|
/* Prevent the content from being rendered before the main stylesheet loads */
|
|
|
|
display: none;
|
|
|
|
}
|
|
|
|
</style>
|
2025-03-08 01:22:31 +02:00
|
|
|
<% // TriliumNextTODO: move the css file to ${assetPath}/stylesheets/ %>
|
2025-05-20 19:16:23 +03:00
|
|
|
<link rel="stylesheet" href="<%= appPath %>/bootstrap.css">
|
2025-01-06 23:19:15 +01:00
|
|
|
<link rel="stylesheet" href="<%= assetPath %>/stylesheets/theme-light.css">
|
|
|
|
<link rel="stylesheet" href="<%= assetPath %>/stylesheets/theme-next.css">
|
|
|
|
<link rel="stylesheet" href="<%= assetPath %>/stylesheets/style.css">
|
2018-12-23 10:57:40 +01:00
|
|
|
</head>
|
|
|
|
<body>
|
2025-03-08 20:40:00 +02:00
|
|
|
<div class="container login-page">
|
2025-01-07 19:16:43 +01:00
|
|
|
<div class="col-xs-12 col-sm-10 col-md-6 col-lg-4 col-xl-4 mx-auto pt-4">
|
2025-05-25 14:15:12 +03:00
|
|
|
<img class="img-fluid d-block mx-auto" style="height: 8rem;" src="<%= assetPathFragment %>/images/icon-color.svg" aria-hidden="true" draggable="false" >
|
2025-01-07 19:20:05 +01:00
|
|
|
<h1 class="text-center"><%= t("login.heading") %></h1>
|
2017-10-14 23:31:44 -04:00
|
|
|
|
2025-03-26 01:48:42 +01:00
|
|
|
<% if (ssoEnabled) { %>
|
|
|
|
<a href="/authenticate" class="google-login-btn">
|
|
|
|
<img src="<%= assetPath %>/images/google-logo.svg" alt="Google logo">
|
|
|
|
<%= t("login.sign_in_with_google") %>
|
|
|
|
</a>
|
|
|
|
<% } else { %>
|
|
|
|
<form action="login" method="POST">
|
2024-09-07 10:21:41 -07:00
|
|
|
<div class="form-group">
|
2025-03-26 01:48:42 +01:00
|
|
|
<label for="password"><%= t("login.password") %></label>
|
2024-09-07 10:21:41 -07:00
|
|
|
<div class="controls">
|
2025-04-02 21:02:24 +03:00
|
|
|
<input id="password" name="password" placeholder="" class="form-control" type="password" autocomplete="current-password" autofocus>
|
2024-09-07 10:21:41 -07:00
|
|
|
</div>
|
|
|
|
</div>
|
2025-03-26 01:48:42 +01:00
|
|
|
<% if( totpEnabled ) { %>
|
|
|
|
<div class="form-group">
|
|
|
|
<label for="totpToken">TOTP Token</label>
|
|
|
|
<div class="controls">
|
2025-04-02 21:02:24 +03:00
|
|
|
<input id="totpToken" name="totpToken" placeholder="" class="form-control" type="text" autocomplete="one-time-code" required />
|
2025-03-26 01:48:42 +01:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<% } %>
|
2025-03-08 20:40:00 +02:00
|
|
|
|
2025-03-26 01:48:42 +01:00
|
|
|
<% if ( wrongPassword ) { %>
|
2025-03-22 12:35:00 +01:00
|
|
|
<div class="alert alert-warning">
|
2025-03-26 01:48:42 +01:00
|
|
|
<%= t("login.incorrect-password") %>
|
2025-03-22 12:35:00 +01:00
|
|
|
</div>
|
|
|
|
<% } %>
|
2025-03-26 01:48:42 +01:00
|
|
|
<% if ( totpEnabled ) { %>
|
|
|
|
<% if( wrongTotp ) { %>
|
|
|
|
<div class="alert alert-warning">
|
|
|
|
<%= t("login.incorrect-totp") %>
|
|
|
|
</div>
|
|
|
|
<% } %>
|
|
|
|
<% } %>
|
|
|
|
|
2025-03-08 20:40:00 +02:00
|
|
|
|
2025-03-26 01:48:42 +01:00
|
|
|
<div class="form-group">
|
|
|
|
<div class="checkbox">
|
|
|
|
<label class="tn-checkbox">
|
|
|
|
<input id="remember-me" name="rememberMe" value="1" type="checkbox">
|
|
|
|
<%= t("login.remember-me") %>
|
|
|
|
</label>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="form-group">
|
|
|
|
<button class="btn btn-success"><%= t("login.button") %></button>
|
2018-12-23 11:06:11 +01:00
|
|
|
</div>
|
2025-03-26 01:48:42 +01:00
|
|
|
</form>
|
|
|
|
<% } %>
|
2018-12-23 11:06:11 +01:00
|
|
|
</div>
|
2018-12-23 10:57:40 +01:00
|
|
|
</div>
|
2025-04-23 11:24:30 +03:00
|
|
|
|
|
|
|
<script src="<%= appPath %>/runtime.js" crossorigin type="module"></script>
|
2025-02-21 22:14:27 +01:00
|
|
|
<script src="<%= appPath %>/login.js" crossorigin type="module"></script>
|
2017-10-20 23:43:20 -04:00
|
|
|
|
2019-06-30 20:14:57 +02:00
|
|
|
</body>
|
2021-12-29 23:37:12 +01:00
|
|
|
</html>
|