mirror of
https://github.com/matt-fidd/stratos.git
synced 2026-01-02 01:19:31 +00:00
Generalised form styles
This commit is contained in:
@@ -1,3 +1,22 @@
|
|||||||
|
.formContainer {
|
||||||
|
margin: 2rem auto;
|
||||||
|
width: 85vw;
|
||||||
|
|
||||||
|
a {
|
||||||
|
display: block;
|
||||||
|
|
||||||
|
&:not(.formContainer__small-link) {
|
||||||
|
margin: 1rem;
|
||||||
|
text-align: center;
|
||||||
|
font-size: 1.2em;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@include respond-to('large') {
|
||||||
|
width: 40vw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
form {
|
form {
|
||||||
display: grid;
|
display: grid;
|
||||||
gap: 1rem;
|
gap: 1rem;
|
||||||
@@ -7,7 +26,7 @@ form {
|
|||||||
gap: 1rem;
|
gap: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
input:not([type='submit']), textarea {
|
input:not([type='submit']), textarea, select {
|
||||||
background: #E1E1E1;
|
background: #E1E1E1;
|
||||||
border: none;
|
border: none;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
@@ -25,6 +44,11 @@ form {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
input[type='submit'] {
|
||||||
|
width: 100%;
|
||||||
|
padding: 1rem 0;
|
||||||
|
}
|
||||||
|
|
||||||
@include respond-to('medium') {
|
@include respond-to('medium') {
|
||||||
.input-group {
|
.input-group {
|
||||||
grid-template-columns: 1fr 1fr;
|
grid-template-columns: 1fr 1fr;
|
||||||
|
|||||||
@@ -1,21 +0,0 @@
|
|||||||
.mainForm {
|
|
||||||
margin: 2rem auto 0 auto;
|
|
||||||
width: 85vw;
|
|
||||||
|
|
||||||
a {
|
|
||||||
margin: 1rem;
|
|
||||||
text-align: center;
|
|
||||||
display: block;
|
|
||||||
font-size: 1.2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
input[type='submit'] {
|
|
||||||
@extend .btn, .btn--primary, .btn--full;
|
|
||||||
width: 100%;
|
|
||||||
padding: 1rem 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
@include respond-to('large') {
|
|
||||||
width: 40vw;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -13,7 +13,6 @@
|
|||||||
@import 'components/testimonial';
|
@import 'components/testimonial';
|
||||||
@import 'components/title';
|
@import 'components/title';
|
||||||
@import 'components/mainPageHeader';
|
@import 'components/mainPageHeader';
|
||||||
@import 'components/mainForm';
|
|
||||||
@import 'components/adminHeader';
|
@import 'components/adminHeader';
|
||||||
@import 'components/adminNav';
|
@import 'components/adminNav';
|
||||||
@import 'components/adminNavItem';
|
@import 'components/adminNavItem';
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{{> mainPageHeader name='Password Recovery' }}
|
{{> mainPageHeader name='Password Recovery' }}
|
||||||
|
|
||||||
<div class='mainForm'>
|
<div class='formContainer'>
|
||||||
<form action='/change-password' method='post'>
|
<form action='/change-password' method='post'>
|
||||||
<input type='password' id='password' name='password' placeholder='New password' required/>
|
<input type='password' id='password' name='password' placeholder='New password' required/>
|
||||||
<input type='password' id='confPassword' name='confPassword' placeholder='Confirm new password' required/>
|
<input type='password' id='confPassword' name='confPassword' placeholder='Confirm new password' required/>
|
||||||
@@ -8,7 +8,7 @@
|
|||||||
<input type='hidden' id='uuid' name='uuid' value='{{ uuid }}' required/>
|
<input type='hidden' id='uuid' name='uuid' value='{{ uuid }}' required/>
|
||||||
<input type='hidden' id='token' name='token' value='{{ token }}' required/>
|
<input type='hidden' id='token' name='token' value='{{ token }}' required/>
|
||||||
|
|
||||||
<input type='submit' class='btn btn--primary' value='Change password'/>
|
<input type='submit' class='btn btn--primary btn--full' value='Change password'/>
|
||||||
</form>
|
</form>
|
||||||
<a href='/login'>Back to login</a>
|
<a href='/login'>Back to login</a>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
{{> mainPageHeader name='Log In' }}
|
{{> mainPageHeader name='Log In' }}
|
||||||
|
|
||||||
<div class='mainForm'>
|
<div class='formContainer'>
|
||||||
<form action='/login' method='post'>
|
<form action='/login' method='post'>
|
||||||
<input type='email' id='email' name='email' placeholder='Email Address' required/>
|
<input type='email' id='email' name='email' placeholder='Email Address' required/>
|
||||||
<input type='password' id='password' name='password' placeholder='Password' required/>
|
<input type='password' id='password' name='password' placeholder='Password' required/>
|
||||||
|
|
||||||
<input type='submit' class='btn btn--primary' value='Log In'/>
|
<input type='submit' class='btn btn--primary btn--full' value='Log In'/>
|
||||||
</form>
|
</form>
|
||||||
<a href='/register'>Not got an account yet? Sign up</a>
|
<a href='/register'>Not got an account yet? Sign up</a>
|
||||||
<a href='/password-reset'>Forgotten your password?</a>
|
<a href='/password-reset'>Forgotten your password?</a>
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
{{> mainPageHeader name='Log Out' }}
|
{{> mainPageHeader name='Log Out' }}
|
||||||
|
|
||||||
<div class='mainForm'>
|
<div class='formContainer'>
|
||||||
<p style='text-align: center;'>You are logged in as <span class='hl'>{{ username }}</span></p>
|
<p style='text-align: center;'>You are logged in as <span class='hl'>{{ username }}</span></p>
|
||||||
<form action='/logout' method='post'>
|
<form action='/logout' method='post'>
|
||||||
<input type='submit' class='btn btn--primary' value='Log Out'/>
|
<input type='submit' class='btn btn--primary btn--full' value='Log Out'/>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
{{> mainPageHeader name='Password Recovery' }}
|
{{> mainPageHeader name='Password Recovery' }}
|
||||||
|
|
||||||
<div class='mainForm'>
|
<div class='formContainer'>
|
||||||
<form action='/password-reset' method='post'>
|
<form action='/password-reset' method='post'>
|
||||||
<input type='email' id='email' name='email' placeholder='Email Address' required/>
|
<input type='email' id='email' name='email' placeholder='Email Address' required/>
|
||||||
|
|
||||||
<input type='submit' class='btn btn--primary' value='Request a password reset'/>
|
<input type='submit' class='btn btn--primary btn--full' value='Request a password reset'/>
|
||||||
</form>
|
</form>
|
||||||
<a href='/login'>Back to login</a>
|
<a href='/login'>Back to login</a>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{{> mainPageHeader name='Sign Up' }}
|
{{> mainPageHeader name='Sign Up' }}
|
||||||
|
|
||||||
<div class='mainForm'>
|
<div class='formContainer'>
|
||||||
<form action='/register' method='post'>
|
<form action='/register' method='post'>
|
||||||
<div class='input-group'>
|
<div class='input-group'>
|
||||||
<input type='text' id='fname' name='fname' placeholder='First Name' required/>
|
<input type='text' id='fname' name='fname' placeholder='First Name' required/>
|
||||||
@@ -12,7 +12,7 @@
|
|||||||
<input type='password' id='password' name='password' placeholder='Password' required/>
|
<input type='password' id='password' name='password' placeholder='Password' required/>
|
||||||
<input type='password' id='confPassword' name='confPassword' placeholder='Confirm Password' required/>
|
<input type='password' id='confPassword' name='confPassword' placeholder='Confirm Password' required/>
|
||||||
|
|
||||||
<input type='submit' class='btn btn--primary' value='Sign Up'/>
|
<input type='submit' class='btn btn--primary btn--full' value='Sign Up'/>
|
||||||
</form>
|
</form>
|
||||||
<a href='/login'>Already got an account? Log in</a>
|
<a href='/login'>Already got an account? Log in</a>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user