loginProviders.html 3.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta http-equiv="X-UA-Compatible" content="IE=edge"/>
  6. <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"/>
  7. <title>loginProviders Fragment</title>
  8. <link href="../../static/css/cas.css" rel="stylesheet" th:remove="tag" />
  9. </head>
  10. <body>
  11. <main role="main" class="container mt-3 mb-3">
  12. <div th:fragment="loginProviders" th:remove="tag">
  13. <div th:if="${pac4jUrls}" id="list-providers" class="card d-sm-none d-md-block bg-light">
  14. <div class="card-body">
  15. <h3 class="card-title" th:utext="#{screen.welcome.label.loginwith}">Or login with:</h3>
  16. <div class="card-text">
  17. <ul>
  18. <li th:each="entry: ${pac4jUrls}" th:switch="${entry.type}">
  19. <a class="btn btn-block btn-social"
  20. th:classappend="'btn-' + ${entry.type}"
  21. th:href="@{${entry.redirectUrl}}"
  22. th:attr="autoredirect=${entry.autoRedirect}"
  23. th:inline="text"
  24. th:title="${entry.name}">
  25. <span th:case="twitter" class="fab fa-twitter-square"></span>
  26. <span th:case="foursquare" class="fab fa-foursquare"></span>
  27. <span th:case="windowslive" class="fab fa-windows"></span>
  28. <span th:case="yahoo" class="fab fa-yahoo"></span>
  29. <span th:case="bitbucket" class="fab fa-bitbucket"></span>
  30. <span th:case="wordpress" class="fab fa-wordpress"></span>
  31. <span th:case="google2" class="fab fa-google-plus"></span>
  32. <span th:case="github" class="fab fa-github-alt"></span>
  33. <span th:case="dropbox" class="fab fa-dropbox"></span>
  34. <span th:case="linkedin" class="fab fa-linkedin"></span>
  35. <span th:case="facebook" class="fab fa-facebook-square"></span>
  36. <span th:case="oidc" class="fab fa-openid"></span>
  37. <span th:case="saml2" th:class="${entry.cssClass}"></span>
  38. <span th:case="*" class="fa fa-sign-in-alt"></span>
  39. [[${entry.name}]]
  40. </a>
  41. </li>
  42. </ul>
  43. </div>
  44. </div>
  45. </div>
  46. <div th:if="${wsfedUrls}" id="list-providers" class="card d-sm-none d-md-block bg-light">
  47. <div class="card-body">
  48. <h3 class="card-title" th:utext="#{screen.welcome.label.loginwith}"/>
  49. <div class="card-text">
  50. <ul>
  51. <li th:each="entry: ${wsfedUrls}">
  52. <a class="btn btn-block btn-social"
  53. th:classappend="btn-sm"
  54. th:href="@{${entry.redirectUrl}}"
  55. th:inline="text"
  56. onload=""
  57. th:attr="autoredirect=${entry.autoRedirect}"
  58. th:title="${entry.name}">
  59. <span class="fab fa-windows"></span>
  60. [[${entry.name}]]
  61. </a>
  62. </li>
  63. </ul>
  64. </div>
  65. </div>
  66. </div>
  67. <script>
  68. var redirectTo = $( "a[autoRedirect=true]" ).attr("href");
  69. if (redirectTo != null && redirectTo != undefined) {
  70. window.location.href = redirectTo;
  71. }
  72. </script>
  73. </div>
  74. </main>
  75. </body>
  76. </html>