newsbox/templates/auth/index.plush.html
Adriano Caloiaro 8ae801ae5f
Initial commit
2023-02-15 08:57:48 -08:00

24 lines
720 B
HTML

<div>
<%= if (current_user) { %>
<h1><%= current_user.Email %></h1>
<%= linkTo(loginPath(), {data-method: "DELETE"}){ %>Sign Out<% } %>
<% } else { %>
<div class="auth-wrapper">
<div class="sign-form">
<h1>Sign In</h1>
<%= formFor(user, {action: loginPath(), method: "POST"}) { %>
<%= f.InputTag("Email") %>
<%= f.InputTag("Password", {type: "password"}) %>
<br/>
<button class="btn btn-success">Sign In!</button>
<% } %>
</div>
</div>
<br/>
<%= linkTo(oauthProviderPath({provider: "github"}), {class: "btn btn-success"}){ %>Github Login<% } %>
<%= linkTo(newUsersPath(), {class: "btn btn-success"}){ %>Create Account<% } %>
<br/>
<% } %>
</div>