Move auth pages into the main site, slight reduces the immersion break.

This commit is contained in:
flash 2018-08-16 00:22:32 +02:00
parent f3760f62ff
commit acf0dda67a
8 changed files with 22 additions and 55 deletions

View file

@ -1,5 +1,16 @@
.container {
.auth-container {
box-shadow: 0 2px 5px fade(#111, 80%);
color: #fff;
background: #222;
margin: 2px;
margin: 2px auto;
width: 400px;
min-height: @auth-form-height;
display: flex;
flex-direction: column;
justify-content: center;
@media (max-width: @auth-mobile) {
min-width: 0;
width: 100%;
}
}

View file

@ -2,41 +2,6 @@
@auth-title-height: 40px;
@auth-form-height: 200px;
* {
margin: 0;
padding: 0;
box-sizing: border-box;
position: relative;
}
html,
body {
height: 100%;
width: 100%;
}
body {
background: #5e3e71 url('https://static.flash.moe/images/grid.png');
font: 12px/20px sans-serif;
display: flex;
align-items: center;
justify-content: center;
color: #fff;
}
.auth {
min-width: 400px;
min-height: @auth-form-height;
display: flex;
flex-direction: column;
justify-content: center;
@media (max-width: @auth-mobile) {
min-width: 0;
width: 100%;
}
}
@import "classes/button";
@import "classes/container";
@import "classes/form";

View file

@ -1,7 +1,7 @@
{% extends 'auth/master.twig' %}
{% block content %}
<div class="container">
<div class="auth-container">
<div class="form__wrapper">
<input class="form__toggle" id="_authmode_login" type="radio" name="_authmode"{% if auth_mode == 'login' %} checked{% endif %}>
<div class="form form--login">

View file

@ -1,7 +1,7 @@
{% extends 'auth/master.twig' %}
{% block content %}
<div class="container logout">
<div class="auth-container logout">
<div class="logout__message">
<p class="logout__paragraph">The site is currently unavailable, try again later.</p>
</div>

View file

@ -1,7 +1,7 @@
{% extends 'auth/master.twig' %}
{% block content %}
<div class="container logout">
<div class="auth-container logout">
<div class="logout__message">
<p class="logout__paragraph">We couldn't verify that you were actually the person attempting to log out.</p>
<p class="logout__paragraph">Press the button below to verify the logout request, otherwise click back in your browser or close this tab.</p>

View file

@ -1,14 +1,2 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Authentication</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="{{ '/css/auth.css'|asset_url }}" rel="stylesheet" type="text/css">
</head>
<body>
<div class="auth">
{{ block('content') is defined ? block('content') : '' }}
</div>
</body>
</html>
{% extends 'master.twig' %}
{% set is_auth = true %}

View file

@ -1,7 +1,7 @@
{% extends 'auth/master.twig' %}
{% block content %}
<div class="container">
<div class="auth-container">
<div class="form__wrapper">
<input class="form__toggle" id="_authmode_reset" type="radio" name="_authmode" checked>
<div class="form form--reset">

View file

@ -6,6 +6,9 @@
{% include '_layout/meta.twig' %}
<link href="{{ '/css/mio.css'|asset_url }}" rel="stylesheet">
<link href="{{ '/css/libraries.css'|asset_url }}" rel="stylesheet">
{% if is_auth|default(false) %}
<link href="{{ '/css/auth.css'|asset_url }}" rel="stylesheet" type="text/css">
{% endif %}
{% if manage_menu is defined %}
<link href="{{ '/css/manage.css'|asset_url }}" rel="stylesheet">
<style>