Skip to content

Commit f11a786

Browse files
committed
Version Bump
1 parent 810bd04 commit f11a786

27 files changed

+389
-403
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "angular2-token",
3-
"version": "0.2.0-beta.6",
3+
"version": "0.2.0-beta.7",
44
"description": "Angular2 service for token based authentication",
55

66
"main": "./angular2-token.js",

src/a2t-ui/a2t-reset-password/a2t-reset-password.component.css

Lines changed: 0 additions & 8 deletions
This file was deleted.

src/a2t-ui/a2t-reset-password/a2t-reset-password.component.html

Lines changed: 0 additions & 7 deletions
This file was deleted.

src/a2t-ui/a2t-reset-password/a2t-reset-password.component.ts

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,25 @@ import { RESET_PASSWORD_FORM } from '../';
77

88
@Component({
99
selector: 'a2t-reset-password',
10-
templateUrl: './a2t-reset-password.component.html',
11-
styleUrls: ['./a2t-reset-password.component.css'],
12-
providers: [A2tFormService]
10+
providers: [A2tFormService],
11+
template: `
12+
<a2t-headline *ngIf="!_emailSend">Reset your Password</a2t-headline>
13+
<a2t-form *ngIf="!_emailSend">Reset Password</a2t-form>
14+
<p class="email-send-text" *ngIf="_emailSend">
15+
If the entered email is registered we will send instruction on how to reset your password.
16+
</p>
17+
<a2t-links *ngIf="!_emailSend" case="reset-password"></a2t-links>
18+
`,
19+
styles: [`
20+
.email-send-text {
21+
background-color: #72c380;
22+
color: white;
23+
font-size: 16pt;
24+
text-align: center;
25+
padding: 20px;
26+
border-radius: 3px;
27+
}
28+
`]
1329
})
1430
export class A2tResetPasswordComponent {
1531

src/a2t-ui/a2t-shared/a2t-error/a2t-error.component.css

Lines changed: 0 additions & 14 deletions
This file was deleted.

src/a2t-ui/a2t-shared/a2t-error/a2t-error.component.ts

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,22 @@ import { Component, Input } from '@angular/core';
33
@Component({
44
selector: 'a2t-error',
55
template: '<div *ngFor="let error of errors"><p>{{error}}</p></div>',
6-
styleUrls: ['./a2t-error.component.css']
6+
styles: [`
7+
div {
8+
width: 100%;
9+
background-color: #df6564;
10+
color: white;
11+
font-weight: 300;
12+
font-size: 15px;
13+
padding: 10px 20px;
14+
border-radius: 3px;
15+
margin-bottom: 15px;
16+
}
17+
18+
div > p {
19+
margin-bottom: 0;
20+
}
21+
`]
722
})
823
export class A2tErrorComponent {
924

src/a2t-ui/a2t-shared/a2t-form/a2t-form-field/a2t-form-field.component.css

Lines changed: 0 additions & 32 deletions
This file was deleted.

src/a2t-ui/a2t-shared/a2t-form/a2t-form-field/a2t-form-field.component.html

Lines changed: 0 additions & 39 deletions
This file was deleted.

src/a2t-ui/a2t-shared/a2t-form/a2t-form-field/a2t-form-field.component.ts

Lines changed: 76 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,82 @@ import { FormGroup, AbstractControl } from '@angular/forms';
44
import { BaseField } from '../../../';
55

66
@Component({
7-
selector: 'a2t-form-field',
8-
templateUrl: './a2t-form-field.component.html',
9-
styleUrls: ['./a2t-form-field.component.css']
7+
selector: 'a2t-form-field',
8+
template: `
9+
<div class="a2t-input-group"
10+
[formGroup]="form">
11+
12+
<label
13+
[attr.for]="question.key"
14+
[style.color]="labelColor"
15+
*ngIf="_control.pristine">
16+
{{question.label}}
17+
</label>
18+
19+
<label class="a2t-error"
20+
[attr.for]="question.key"
21+
*ngIf="_control.hasError('required') && !_control.pristine">
22+
{{question.label}} is required
23+
</label>
24+
25+
<label class="a2t-error"
26+
[attr.for]="question.key"
27+
*ngIf="_control.hasError('minlength')">
28+
{{question.label}} is too short
29+
</label>
30+
31+
<label class="a2t-error"
32+
[attr.for]="question.key"
33+
*ngIf="_control.hasError('maxlength')">
34+
{{question.label}} is too long
35+
</label>
36+
37+
<label class="a2t-valid"
38+
[attr.for]="question.key"
39+
*ngIf="_control.valid && !_control.pristine">
40+
{{question.label}}
41+
</label>
42+
43+
<input
44+
[formControlName]="question.key"
45+
[id]="question.key"
46+
[type]="question.type">
47+
</div>
48+
`,
49+
styles: [`
50+
.a2t-input-group {
51+
padding-bottom: 40px;
52+
padding-right: 20px;
53+
padding-left: 20px;
54+
font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
55+
}
56+
57+
.a2t-input-group input {
58+
width: 100%;
59+
outline: none;
60+
border: none;
61+
background-color: #eee;
62+
line-height: 40px;
63+
64+
padding-left: 10px;
65+
padding-right: 10px;
66+
}
67+
68+
.a2t-input-group label {
69+
color: #666;
70+
font-weight: 600;
71+
font-size: 13px;
72+
margin-bottom: 0;
73+
}
74+
75+
.a2t-error {
76+
color: #df6564 !important;
77+
}
78+
79+
.a2t-valid {
80+
color: #72c380 !important;
81+
}
82+
`]
1083
})
1184

1285
export class A2tFormFieldComponent implements OnInit {

src/a2t-ui/a2t-shared/a2t-form/a2t-form.component.css

Lines changed: 0 additions & 39 deletions
This file was deleted.

0 commit comments

Comments
 (0)