login.tx 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. <: component('Header', {
  2. title => $title,
  3. route => $route,
  4. stylesheets => $stylesheets,
  5. }) :>
  6. : include "jsalert.tx";
  7. <style>
  8. #jsalert {
  9. margin-top: 1rem;
  10. }
  11. </style>
  12. <div id="login">
  13. <div>
  14. <img id="logo" src="/img/icon/favicon.svg" style="float:left" loading="lazy" /><span style="font-family:courier;font-size:2rem;">CMS Login</span>
  15. </div>
  16. <div id="spacer" style="clear: both;"><br /></div>
  17. <form method="POST" action="/auth">
  18. <input type="hidden" name="app" value="login" />
  19. <input type="hidden" name="to" value="<: $to :>" />
  20. Username<br />
  21. <div class="input-group">
  22. <label for="username">😎</span></label>
  23. <input required name="username" id="username" placeholder="AzureDiamond" value="" type="text" autofocus></input>
  24. </div>
  25. <br />
  26. Password<br />
  27. <div class="input-group">
  28. <label for="password">🔑</label>
  29. <input required name="password" id="password" placeholder="hunter2" value="" type="password"></input>
  30. </div>
  31. <br />
  32. : if ($has_users) {
  33. TOTP 2FA code <a style="cursor:help" title="from your authenticator app; leave this blank only on the login where you enrol">ℹ️ </a><br />
  34. <div class="input-group">
  35. <label for="token">🔒</label>
  36. <input name="token" id="token" placeholder="7779311" value="" type="password"></input>
  37. </div>
  38. <br />
  39. : } else {
  40. Display Name:<br />
  41. <div class="input-group">
  42. <label for="display_name">📛</label>
  43. <input required name="display_name" id="contact_email" placeholder="Mr. President" value="" type="text"></input>
  44. </div>
  45. <br />
  46. Contact Email:<br />
  47. <div class="input-group">
  48. <label for="contact_email">📧</label>
  49. <input required name="contact_email" id="contact_email" placeholder="bl00d_n1nja@wh.gov" value="" type="text"></input>
  50. </div>
  51. <br />
  52. : }
  53. <input type="submit" id="maximumGo" value="<: $btnmsg :>"></input>
  54. </form>
  55. : if ($has_users) {
  56. <div id="resetpass">
  57. <a href="/password_reset">Reset Password</a>
  58. </div>
  59. : }
  60. </div>
  61. <: component('Footer') :>