templates/security/index.html.twig line 1

Open in your IDE?
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4.     <meta charset="utf-8">
  5.     <title>Mosaic HTML Demo - Sign in</title>
  6.     <meta name="viewport" content="width=device-width,initial-scale=1">
  7.     {% block stylesheets %}
  8.         {# 'app' must match the first argument to addEntry() in webpack.config.js #}
  9.         <link href="{{ asset('css/vendors/flatpickr.min.css') }}" rel="stylesheet">
  10.         <link href="{{ asset('build/app.css') }}" rel="stylesheet">
  11.         {{ encore_entry_link_tags('app') }}
  12.         <!-- Renders a link tag (if your module requires any CSS)
  13.              <link rel="stylesheet" href="/build/app.css"> -->
  14.     {% endblock %}
  15. </head>
  16. <body class="font-inter antialiased bg-slate-100 text-slate-600">
  17. <script>
  18.     if (localStorage.getItem('sidebar-expanded') == 'true') {
  19.         document.querySelector('body').classList.add('sidebar-expanded');
  20.     } else {
  21.         document.querySelector('body').classList.remove('sidebar-expanded');
  22.     }
  23. </script>
  24. <main class="bg-white">
  25.     <div class="relative flex">
  26.         <!-- Content -->
  27.         <div class="w-full md:w-1/2">
  28.             <div class="min-h-screen h-full flex flex-col after:flex-1">
  29.                 <!-- Header -->
  30.                 <div class="flex-1">
  31.                     <div class="flex items-center justify-between h-16 px-4 sm:px-6 lg:px-8">
  32.                         <!-- Logo -->
  33.                         <a class="block" href="index.html">
  34.                             <svg width="32" height="32" viewBox="0 0 32 32">
  35.                                 <defs>
  36.                                     <linearGradient x1="28.538%" y1="20.229%" x2="100%" y2="108.156%" id="logo-a">
  37.                                         <stop stop-color="#A5B4FC" stop-opacity="0" offset="0%"/>
  38.                                         <stop stop-color="#A5B4FC" offset="100%"/>
  39.                                     </linearGradient>
  40.                                     <linearGradient x1="88.638%" y1="29.267%" x2="22.42%" y2="100%" id="logo-b">
  41.                                         <stop stop-color="#38BDF8" stop-opacity="0" offset="0%"/>
  42.                                         <stop stop-color="#38BDF8" offset="100%"/>
  43.                                     </linearGradient>
  44.                                 </defs>
  45.                                 <rect fill="#6366F1" width="32" height="32" rx="16"/>
  46.                                 <path d="M18.277.16C26.035 1.267 32 7.938 32 16c0 8.837-7.163 16-16 16a15.937 15.937 0 01-10.426-3.863L18.277.161z"
  47.                                       fill="#4F46E5"/>
  48.                                 <path d="M7.404 2.503l18.339 26.19A15.93 15.93 0 0116 32C7.163 32 0 24.837 0 16 0 10.327 2.952 5.344 7.404 2.503z"
  49.                                       fill="url(#logo-a)"/>
  50.                                 <path d="M2.223 24.14L29.777 7.86A15.926 15.926 0 0132 16c0 8.837-7.163 16-16 16-5.864 0-10.991-3.154-13.777-7.86z"
  51.                                       fill="url(#logo-b)"/>
  52.                             </svg>
  53.                         </a>
  54.                     </div>
  55.                 </div>
  56.                 <div class="max-w-sm mx-auto px-4 py-8">
  57.                     <h1 class="text-3xl text-slate-800 font-bold mb-6">Welcome back! ✨</h1>
  58.                     <!-- Form -->
  59.                     <form method="post" action="{{ path("app_login") }}">
  60.                         <div class="space-y-4">
  61.                             <div>
  62.                                 <label class="block text-sm font-medium mb-1"
  63.                                        for="email">{{ "Email Address"| trans }}</label>
  64.                                 <input class="form-input w-full" type="email" id="username" name="_username"
  65.                                        value="{{ last_username }}"/>
  66.                             </div>
  67.                             <div>
  68.                                 <label class="block text-sm font-medium mb-1"
  69.                                        for="password">{{ "Password"| trans }}</label>
  70.                                 <input id="password" class="form-input w-full" type="password" name="_password"
  71.                                        autocomplete="on"/>
  72.                             </div>
  73.                         </div>
  74.                         <div class="flex items-center justify-between mt-6">
  75.                             <div class="mr-1">
  76.                             </div>
  77.                             <button class="btn bg-indigo-500 hover:bg-indigo-600 text-white ml-3">{{ "Log in"|trans }}</button>
  78.                         </div>
  79.                         <input type="hidden" name="_csrf_token"
  80.                                value="{{ csrf_token('authenticate') }}"
  81.                         >
  82.                     </form>
  83.                     <!-- Footer -->
  84.                     <div class="pt-5 mt-6 border-t border-slate-200">
  85.                         <!-- Warning -->
  86.                         {% if error %}
  87.                             <div class="mt-5">
  88.                                 <div class="bg-amber-100 text-amber-600 px-3 py-2 rounded">
  89.                                     <svg class="inline w-3 h-3 shrink-0 fill-current" viewBox="0 0 12 12">
  90.                                         <path d="M10.28 1.28L3.989 7.575 1.695 5.28A1 1 0 00.28 6.695l3 3a1 1 0 001.414 0l7-7A1 1 0 0010.28 1.28z"/>
  91.                                     </svg>
  92.                                     <span class="text-sm">
  93.                                     {{ error.messageKey|trans(error.messageData, 'security') }}
  94.                                     </span>
  95.                                 </div>
  96.                             </div>
  97.                         {% endif %}
  98.                     </div>
  99.                 </div>
  100.             </div>
  101.         </div>
  102.         <!-- Image -->
  103.         <div class="hidden md:block absolute top-0 bottom-0 right-0 md:w-1/2" aria-hidden="true">
  104.             <img class="object-cover object-center w-full h-full" src="./images/auth-image.jpg" width="760"
  105.                  height="1024" alt="Authentication image"/>
  106.             <img class="absolute top-1/4 left-0 -translate-x-1/2 ml-8 hidden lg:block"
  107.                  src="./images/auth-decoration.png" width="218" height="224" alt="Authentication decoration"/>
  108.         </div>
  109.     </div>
  110. </main>
  111. {% block javascripts %}
  112.     <script src="{{ asset('/vendors/alpinejs.min.js') }}" defer></script>
  113.     {{ encore_entry_script_tags('app') }}
  114.     <!-- Renders app.js & a webpack runtime.js file
  115.         <script src="/build/runtime.js" defer></script>
  116.         <script src="/build/app.js" defer></script>
  117.         See note below about the "defer" attribute -->
  118. {% endblock %}
  119. </body>
  120. </html>