Skip to content

Commit c29c0c3

Browse files
committed
Add New components Login & Signup
1 parent 91cab59 commit c29c0c3

25 files changed

+1364
-1960
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
it's part of a repo series designed to create a **Web Application with Angular 13**
1212

1313

14-
* Featuring [**Angular 13.0.3**](https://github.com/angular/angular/releases) & [**Angular CLI 13.0.4**](https://github.com/angular/angular-cli/releases/)
14+
* Featuring [**Angular 13.1.**](https://github.com/angular/angular/releases) & [**Angular CLI 13.1.0**](https://github.com/angular/angular-cli/releases/)
1515

1616

1717
* See the [**Live demo**](#live-demo), Test the repo with [**Quick start**](#quick-start) and for more information Read the step by step [**Tutorial**](#tutorial) or read the [**Getting started**](#getting-started)

package-lock.json

Lines changed: 1197 additions & 1872 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "angular-starter",
3-
"version": "13.0.3",
3+
"version": "13.1.0",
44
"scripts": {
55
"ng": "ng",
66
"start": "ng serve --port 4200",
@@ -15,30 +15,30 @@
1515
},
1616
"private": true,
1717
"dependencies": {
18-
"@angular/animations": "13.0.3",
19-
"@angular/common": "13.0.3",
20-
"@angular/compiler": "13.0.3",
21-
"@angular/core": "13.0.3",
22-
"@angular/forms": "13.0.3",
23-
"@angular/platform-browser": "13.0.3",
24-
"@angular/platform-browser-dynamic": "13.0.3",
25-
"@angular/router": "13.0.3",
18+
"@angular/animations": "13.1.0",
19+
"@angular/common": "13.1.0",
20+
"@angular/compiler": "13.1.0",
21+
"@angular/core": "13.1.0",
22+
"@angular/forms": "13.1.0",
23+
"@angular/platform-browser": "13.1.0",
24+
"@angular/platform-browser-dynamic": "13.1.0",
25+
"@angular/router": "13.1.0",
2626
"rxjs": "7.4.0",
2727
"tslib": "2.3.1",
2828
"zone.js": "0.11.4"
2929
},
3030
"devDependencies": {
31-
"@angular-devkit/build-angular": "13.0.4",
32-
"@angular/cli": "13.0.4",
33-
"@angular/compiler-cli": "13.0.3",
31+
"@angular-devkit/build-angular": "13.1.0",
32+
"@angular/cli": "13.1.0",
33+
"@angular/compiler-cli": "13.1.0",
3434
"@types/jasmine": "3.10.2",
35-
"@types/node": "16.11.11",
35+
"@types/node": "16.11.12",
3636
"jasmine-core": "3.10.1",
3737
"karma": "6.3.9",
3838
"karma-chrome-launcher": "3.1.0",
3939
"karma-coverage": "2.1.0",
4040
"karma-jasmine": "4.0.1",
4141
"karma-jasmine-html-reporter": "1.7.0",
42-
"typescript": "4.4.4"
42+
"typescript": "4.5.3"
4343
}
4444
}

src/app/app-routing.module.ts

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,14 @@ const routes: Routes = [
1717
.then(mod => mod.AboutModule)
1818
},
1919
{
20-
path: 'signin',
21-
loadChildren: () => import('./modules/general/signin/signin.module')
22-
.then(mod => mod.SigninModule)
20+
path: 'login',
21+
loadChildren: () => import('./modules/general/login/login.module')
22+
.then(mod => mod.LoginModule)
23+
},
24+
{
25+
path: 'signup',
26+
loadChildren: () => import('./modules/general/signup/signup.module')
27+
.then(mod => mod.SignupModule)
2328
},
2429
{ path: '**', component: NotFoundComponent }
2530
];

src/app/app.component.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ <h2> {{ version }}</h2>
99
<li><a routerLink="/">Home</a></li>
1010
<li><a routerLink="/about">About</a></li>
1111
<li><a routerLink="/contact">Contact</a></li>
12-
<li><a routerLink="/signin">Signin</a></li>
12+
<li><a routerLink="/login">Login</a></li>
13+
<li><a routerLink="/signup">Signup</a></li>
1314
</ul>
1415
</nav>
1516
</header>
@@ -19,7 +20,7 @@ <h2> {{ version }}</h2>
1920
</main>
2021

2122
<footer>
22-
<a href="https://www.ganatan.com/">www.ganatan.com</a>
23+
<a href="https://www.ganatan.com/">2021 - www.ganatan.com</a>
2324
</footer>
2425

2526
</div>

src/app/app.component.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ describe('AppComponent', () => {
77
await TestBed.configureTestingModule({
88
imports: [
99
RouterTestingModule
10-
],
10+
],
1111
declarations: [
1212
AppComponent
1313
],

src/app/app.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@ import { Component } from '@angular/core';
77
})
88
export class AppComponent {
99
title = 'angular-starter';
10-
version = 'Angular version 13.0.3';
10+
version = 'Angular version 13.1.0';
1111
}

src/app/app.module.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { NgModule } from '@angular/core';
21
import { BrowserModule } from '@angular/platform-browser';
2+
import { NgModule } from '@angular/core';
33

44
import { AppComponent } from './app.component';
55
import { HomeComponent } from './modules/general/home/home.component';
@@ -19,4 +19,4 @@ import { AppRoutingModule } from './app-routing.module';
1919
providers: [],
2020
bootstrap: [AppComponent]
2121
})
22-
export class AppModule { }
22+
export class AppModule { }
Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
<div class="row">
2-
<div class="col-12 col-sm-12 col-md-3 col-lg-3 col-xl-3">
3-
<p>contact works!</p>
4-
<ul>
5-
<li><a routerLink="/contact/mailing">Mailing</a></li>
6-
<li><a routerLink="/contact/map">Map</a></li>
7-
</ul>
8-
</div>
9-
<div class="col-12 col-sm-12 col-md-9 col-lg-9 col-xl-9">
10-
<router-outlet></router-outlet>
11-
</div>
12-
</div>
2+
<div class="col-12 col-sm-12 col-md-3 col-lg-3 col-xl-3">
3+
<p>contact works!</p>
4+
<ul>
5+
<li><a routerLink="/contact/mailing">Mailing</a></li>
6+
<li><a routerLink="/contact/map">Map</a></li>
7+
</ul>
8+
</div>
9+
<div class="col-12 col-sm-12 col-md-9 col-lg-9 col-xl-9">
10+
<router-outlet></router-outlet>
11+
</div>
12+
</div>
Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { ComponentFixture, TestBed } from '@angular/core/testing';
2-
import { RouterTestingModule } from '@angular/router/testing';
32

43
import { ContactComponent } from './contact.component';
54

@@ -9,11 +8,9 @@ describe('ContactComponent', () => {
98

109
beforeEach(async () => {
1110
await TestBed.configureTestingModule({
12-
imports: [
13-
RouterTestingModule
14-
],
15-
declarations: [ContactComponent]
16-
}).compileComponents();
11+
declarations: [ ContactComponent ]
12+
})
13+
.compileComponents();
1714
});
1815

1916
beforeEach(() => {
@@ -25,4 +22,4 @@ describe('ContactComponent', () => {
2522
it('should create', () => {
2623
expect(component).toBeTruthy();
2724
});
28-
});
25+
});
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
import { NgModule } from '@angular/core';
22
import { Routes, RouterModule } from '@angular/router';
33

4-
import { SigninComponent } from './signin.component';
4+
import { LoginComponent } from './login.component';
55

66
const routes: Routes = [
7-
{ path: '', component: SigninComponent },
7+
{ path: '', component: LoginComponent },
88
];
99

1010
@NgModule({
1111
imports: [RouterModule.forChild(routes)],
1212
exports: [RouterModule]
1313
})
14-
export class SigninRoutingModule { }
14+
export class LoginRoutingModule { }
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<p>login works!</p>

src/app/modules/general/signin/signin.component.spec.ts renamed to src/app/modules/general/login/login.component.spec.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
import { ComponentFixture, TestBed } from '@angular/core/testing';
22

3-
import { SigninComponent } from './signin.component';
3+
import { LoginComponent } from './login.component';
44

5-
describe('SigninComponent', () => {
6-
let component: SigninComponent;
7-
let fixture: ComponentFixture<SigninComponent>;
5+
describe('LoginComponent', () => {
6+
let component: LoginComponent;
7+
let fixture: ComponentFixture<LoginComponent>;
88

99
beforeEach(async () => {
1010
await TestBed.configureTestingModule({
11-
declarations: [ SigninComponent ]
11+
declarations: [ LoginComponent ]
1212
})
1313
.compileComponents();
1414
});
1515

1616
beforeEach(() => {
17-
fixture = TestBed.createComponent(SigninComponent);
17+
fixture = TestBed.createComponent(LoginComponent);
1818
component = fixture.componentInstance;
1919
fixture.detectChanges();
2020
});
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import { Component, OnInit } from '@angular/core';
2+
3+
@Component({
4+
selector: 'app-login',
5+
templateUrl: './login.component.html',
6+
styleUrls: ['./login.component.css']
7+
})
8+
export class LoginComponent implements OnInit {
9+
10+
constructor() { }
11+
12+
ngOnInit(): void {
13+
}
14+
15+
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import { NgModule } from '@angular/core';
2+
import { CommonModule } from '@angular/common';
3+
4+
import { LoginComponent } from './login.component';
5+
import { LoginRoutingModule } from './login-routing.module';
6+
7+
@NgModule({
8+
imports: [
9+
CommonModule,
10+
LoginRoutingModule
11+
],
12+
exports: [
13+
LoginComponent
14+
],
15+
declarations: [
16+
LoginComponent
17+
],
18+
providers: [
19+
],
20+
})
21+
export class LoginModule { }

src/app/modules/general/signin/signin.component.html

Lines changed: 0 additions & 1 deletion
This file was deleted.

src/app/modules/general/signin/signin.component.ts

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

src/app/modules/general/signin/signin.module.ts

Lines changed: 0 additions & 21 deletions
This file was deleted.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
import { NgModule } from '@angular/core';
2+
import { Routes, RouterModule } from '@angular/router';
3+
4+
import { SignupComponent } from './signup.component';
5+
6+
const routes: Routes = [
7+
{ path: '', component: SignupComponent },
8+
];
9+
10+
@NgModule({
11+
imports: [RouterModule.forChild(routes)],
12+
exports: [RouterModule]
13+
})
14+
export class SignupRoutingModule { }

src/app/modules/general/signup/signup.component.css

Whitespace-only changes.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<p>signup works!</p>
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
import { ComponentFixture, TestBed } from '@angular/core/testing';
2+
3+
import { SignupComponent } from './signup.component';
4+
5+
describe('SignupComponent', () => {
6+
let component: SignupComponent;
7+
let fixture: ComponentFixture<SignupComponent>;
8+
9+
beforeEach(async () => {
10+
await TestBed.configureTestingModule({
11+
declarations: [ SignupComponent ]
12+
})
13+
.compileComponents();
14+
});
15+
16+
beforeEach(() => {
17+
fixture = TestBed.createComponent(SignupComponent);
18+
component = fixture.componentInstance;
19+
fixture.detectChanges();
20+
});
21+
22+
it('should create', () => {
23+
expect(component).toBeTruthy();
24+
});
25+
});
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import { Component, OnInit } from '@angular/core';
2+
3+
@Component({
4+
selector: 'app-signup',
5+
templateUrl: './signup.component.html',
6+
styleUrls: ['./signup.component.css']
7+
})
8+
export class SignupComponent implements OnInit {
9+
10+
constructor() { }
11+
12+
ngOnInit(): void {
13+
}
14+
15+
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import { NgModule } from '@angular/core';
2+
import { CommonModule } from '@angular/common';
3+
4+
import { SignupComponent } from './signup.component';
5+
import { SignupRoutingModule } from './signup-routing.module';
6+
7+
@NgModule({
8+
imports: [
9+
CommonModule,
10+
SignupRoutingModule
11+
],
12+
exports: [
13+
SignupComponent
14+
],
15+
declarations: [
16+
SignupComponent
17+
],
18+
providers: [
19+
],
20+
})
21+
export class SignupModule { }

0 commit comments

Comments
 (0)