mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-11-23 20:18:00 +01:00
2fa layout
This commit is contained in:
parent
81800cf83d
commit
2ef4bdbbad
3 changed files with 23 additions and 1 deletions
|
@ -385,3 +385,9 @@ figure {
|
|||
text-align: center;
|
||||
padding: 4px 16px;
|
||||
}
|
||||
|
||||
.twofactor {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
|
|
@ -1,13 +1,14 @@
|
|||
defmodule PhilomenaWeb.Session.TotpController do
|
||||
use PhilomenaWeb, :controller
|
||||
|
||||
alias PhilomenaWeb.LayoutView
|
||||
alias Philomena.Users.User
|
||||
alias Philomena.Repo
|
||||
|
||||
def new(conn, _params) do
|
||||
changeset = Pow.Plug.change_user(conn)
|
||||
|
||||
render(conn, "new.html", title: "Two-Factor Authentication", changeset: changeset)
|
||||
render(conn, "new.html", layout: {LayoutView, "two_factor.html"}, changeset: changeset)
|
||||
end
|
||||
|
||||
def create(conn, params) do
|
||||
|
|
15
lib/philomena_web/templates/layout/two_factor.html.slime
Normal file
15
lib/philomena_web/templates/layout/two_factor.html.slime
Normal file
|
@ -0,0 +1,15 @@
|
|||
doctype html
|
||||
html lang="en"
|
||||
head
|
||||
meta charset="utf-8"
|
||||
meta http-equiv="X-UA-Compatible" content="IE=edge"
|
||||
= viewport_meta_tag(@conn)
|
||||
|
||||
title Two Factor Authentication - Derpibooru
|
||||
link rel="stylesheet" href=stylesheet_path(@conn, nil)
|
||||
link rel="icon" href="/favicon.ico" type="image/x-icon"
|
||||
link rel="icon" href="/favicon.svg" type="image/svg+xml"
|
||||
|
||||
body.twofactor
|
||||
.twofactor__container
|
||||
= render @view_module, @view_template, assigns
|
Loading…
Reference in a new issue