main
erb 54 lines 2.13 KB
Raw
1 <% content_for :title, "Reset password" %>
2
3 <div class="min-h-screen bg-surface-900 flex flex-col items-center justify-center px-4 py-16">
4
5 <div class="mb-10 flex flex-col items-center gap-3">
6 <%= link_to root_path, class: "flex items-center gap-3 text-gray-100 hover:text-brand-500 transition-colors" do %>
7 <img src="/icon.png" alt="siGit" class="h-9 w-auto">
8 <span class="text-xl font-semibold tracking-tight">Code &amp; Deploy</span>
9 <% end %>
10 <p class="text-sm text-gray-500">Reset your password</p>
11 </div>
12
13 <div class="w-full max-w-sm">
14 <div class="border border-surface-500 rounded bg-surface-700 px-8 py-8">
15
16 <% if flash[:alert].present? %>
17 <div class="mb-5 flex items-start gap-2.5 rounded border border-red-800/40 bg-red-900/20 px-3.5 py-3 text-sm text-red-400" role="alert">
18 <svg class="w-4 h-4 mt-0.5 shrink-0" viewBox="0 0 16 16" fill="currentColor">
19 <path d="M8 1a7 7 0 1 1 0 14A7 7 0 0 1 8 1zm0 3.75a.75.75 0 0 0-.75.75v3.5a.75.75 0 0 0 1.5 0v-3.5A.75.75 0 0 0 8 4.75zm0 7.5a.875.875 0 1 0 0-1.75.875.875 0 0 0 0 1.75z"/>
20 </svg>
21 <span><%= flash[:alert] %></span>
22 </div>
23 <% end %>
24
25 <p class="mb-5 text-sm text-gray-400 leading-relaxed">
26 Enter your email and we'll send a link to reset your password if an
27 account exists for it.
28 </p>
29
30 <%= form_tag reset_password_path, method: :post, class: "space-y-5" do %>
31
32 <div>
33 <label for="email" class="form-label">Email</label>
34 <input type="email" id="email" name="email"
35 class="form-input" autocomplete="email"
36 value="<%= params[:email].to_s %>"
37 placeholder="you@example.com"
38 autofocus required>
39 </div>
40
41 <button type="submit" class="btn-primary w-full justify-center py-2.5 mt-2">
42 Send reset instructions
43 </button>
44
45 <% end %>
46 </div>
47
48 <p class="mt-6 text-center text-xs text-gray-500">
49 Remembered it?
50 <%= link_to "Sign in", signin_path, class: "text-gray-400 hover:text-gray-200 underline underline-offset-2" %>
51 </p>
52 </div>
53
54 </div>