aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/login
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/app/login')
-rw-r--r--client/src/app/login/login.component.html53
-rw-r--r--client/src/app/login/login.component.scss9
-rw-r--r--client/src/app/login/login.component.ts3
3 files changed, 37 insertions, 28 deletions
diff --git a/client/src/app/login/login.component.html b/client/src/app/login/login.component.html
index bcea0a27a..24807987c 100644
--- a/client/src/app/login/login.component.html
+++ b/client/src/app/login/login.component.html
@@ -1,34 +1,33 @@
1<div class="row"> 1<div class="margin-content">
2 <div class="content-padding"> 2 <div class="title-page title-page-single">
3 3 Login
4 <h3>Login</h3> 4 </div>
5 5
6 <div *ngIf="error" class="alert alert-danger">{{ error }}</div> 6 <div *ngIf="error" class="alert alert-danger">{{ error }}</div>
7 7
8 <form role="form" (ngSubmit)="login()" [formGroup]="form"> 8 <form role="form" (ngSubmit)="login()" [formGroup]="form">
9 <div class="form-group"> 9 <div class="form-group">
10 <label for="username">Username</label> 10 <label for="username">Username</label>
11 <input 11 <input
12 type="text" class="form-control" id="username" placeholder="Username" required 12 type="text" id="username" placeholder="Username" required
13 formControlName="username" 13 formControlName="username" [ngClass]="{ 'input-error': formErrors['username'] }"
14 > 14 >
15 <div *ngIf="formErrors.username" class="alert alert-danger"> 15 <div *ngIf="formErrors.username" class="form-error">
16 {{ formErrors.username }} 16 {{ formErrors.username }}
17 </div>
18 </div> 17 </div>
18 </div>
19 19
20 <div class="form-group"> 20 <div class="form-group">
21 <label for="password">Password</label> 21 <label for="password">Password</label>
22 <input 22 <input
23 type="password" class="form-control" name="password" id="password" placeholder="Password" required 23 type="password" name="password" id="password" placeholder="Password" required
24 formControlName="password" 24 formControlName="password" [ngClass]="{ 'input-error': formErrors['password'] }"
25 > 25 >
26 <div *ngIf="formErrors.password" class="alert alert-danger"> 26 <div *ngIf="formErrors.password" class="form-error">
27 {{ formErrors.password }} 27 {{ formErrors.password }}
28 </div>
29 </div> 28 </div>
29 </div>
30 30
31 <input type="submit" value="Login" class="btn btn-default" [disabled]="!form.valid"> 31 <input type="submit" value="Login" [disabled]="!form.valid">
32 </form> 32 </form>
33 </div>
34</div> 33</div>
diff --git a/client/src/app/login/login.component.scss b/client/src/app/login/login.component.scss
new file mode 100644
index 000000000..3b4326de4
--- /dev/null
+++ b/client/src/app/login/login.component.scss
@@ -0,0 +1,9 @@
1input:not([type=submit]) {
2 @include peertube-input-text(340px);
3 display: block;
4}
5
6input[type=submit] {
7 @include peertube-button;
8 @include orange-button;
9}
diff --git a/client/src/app/login/login.component.ts b/client/src/app/login/login.component.ts
index 32dc9e36f..dfede5924 100644
--- a/client/src/app/login/login.component.ts
+++ b/client/src/app/login/login.component.ts
@@ -7,7 +7,8 @@ import { FormReactive } from '../shared'
7 7
8@Component({ 8@Component({
9 selector: 'my-login', 9 selector: 'my-login',
10 templateUrl: './login.component.html' 10 templateUrl: './login.component.html',
11 styleUrls: [ './login.component.scss' ]
11}) 12})
12 13
13export class LoginComponent extends FormReactive implements OnInit { 14export class LoginComponent extends FormReactive implements OnInit {