template.ftl 4.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. <#macro mainLayout active bodyClass>
  2. <!doctype html>
  3. <html>
  4. <head>
  5. <meta charset="utf-8">
  6. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  7. <meta name="robots" content="noindex, nofollow">
  8. <title>${msg("accountManagementTitle")}</title>
  9. <link rel="icon" href="${url.resourcesPath}/img/favicon.ico">
  10. <#if properties.stylesCommon?has_content>
  11. <#list properties.stylesCommon?split(' ') as style>
  12. <link href="${url.resourcesCommonPath}/${style}" rel="stylesheet" />
  13. </#list>
  14. </#if>
  15. <#if properties.styles?has_content>
  16. <#list properties.styles?split(' ') as style>
  17. <link href="${url.resourcesPath}/${style}" rel="stylesheet" />
  18. </#list>
  19. </#if>
  20. <#if properties.scripts?has_content>
  21. <#list properties.scripts?split(' ') as script>
  22. <script type="text/javascript" src="${url.resourcesPath}/${script}"></script>
  23. </#list>
  24. </#if>
  25. </head>
  26. <body class="admin-console user ${bodyClass}">
  27. <header class="navbar navbar-default navbar-pf navbar-main header">
  28. <nav class="navbar" role="navigation">
  29. <div class="navbar-header">
  30. <div class="container">
  31. <h1 class="navbar-title">Keycloak</h1>
  32. </div>
  33. </div>
  34. <div class="navbar-collapse navbar-collapse-1">
  35. <div class="container">
  36. <ul class="nav navbar-nav navbar-utility">
  37. <#if realm.internationalizationEnabled>
  38. <li>
  39. <div class="kc-dropdown" id="kc-locale-dropdown">
  40. <a href="#" id="kc-current-locale-link">${locale.current}</a>
  41. <ul>
  42. <#list locale.supported as l>
  43. <li class="kc-dropdown-item"><a href="${l.url}">${l.label}</a></li>
  44. </#list>
  45. </ul>
  46. </div>
  47. <li>
  48. </#if>
  49. <#if referrer?has_content && referrer.url?has_content><li><a href="${referrer.url}" id="referrer">${msg("backTo",referrer.name)}</a></li></#if>
  50. <li><a href="${url.logoutUrl}">${msg("doSignOut")}</a></li>
  51. </ul>
  52. </div>
  53. </div>
  54. </nav>
  55. </header>
  56. <div class="container">
  57. <div class="bs-sidebar col-sm-3">
  58. <ul>
  59. <li class="<#if active=='account'>active</#if>"><a href="${url.accountUrl}">${msg("account")}</a></li>
  60. <#if features.passwordUpdateSupported><li class="<#if active=='password'>active</#if>"><a href="${url.passwordUrl}">${msg("password")}</a></li></#if>
  61. <li class="<#if active=='totp'>active</#if>"><a href="${url.totpUrl}">${msg("authenticator")}</a></li>
  62. <#if features.identityFederation><li class="<#if active=='social'>active</#if>"><a href="${url.socialUrl}">${msg("federatedIdentity")}</a></li></#if>
  63. <li class="<#if active=='sessions'>active</#if>"><a href="${url.sessionsUrl}">${msg("sessions")}</a></li>
  64. <li class="<#if active=='applications'>active</#if>"><a href="${url.applicationsUrl}">${msg("applications")}</a></li>
  65. <#if features.log><li class="<#if active=='log'>active</#if>"><a href="${url.logUrl}">${msg("log")}</a></li></#if>
  66. <#if realm.userManagedAccessAllowed && features.authorization><li class="<#if active=='authorization'>active</#if>"><a href="${url.resourceUrl}">${msg("myResources")}</a></li></#if>
  67. </ul>
  68. </div>
  69. <div class="col-sm-9 content-area">
  70. <#if message?has_content>
  71. <div class="alert alert-${message.type}">
  72. <#if message.type=='success' ><span class="pficon pficon-ok"></span></#if>
  73. <#if message.type=='error' ><span class="pficon pficon-error-circle-o"></span></#if>
  74. <span class="kc-feedback-text">${kcSanitize(message.summary)?no_esc}</span>
  75. </div>
  76. </#if>
  77. <#nested "content">
  78. </div>
  79. </div>
  80. </body>
  81. </html>
  82. </#macro>