Commit 8f95d9e1 authored by ccottier's avatar ccottier

navigate to contact-us page working

parent 137e86fe
...@@ -3,15 +3,19 @@ import { GreeceComponent } from './greece/greece.component'; ...@@ -3,15 +3,19 @@ import { GreeceComponent } from './greece/greece.component';
import { AccountComponent } from './account/account.component'; import { AccountComponent } from './account/account.component';
import { FranceComponent } from './france/france.component'; import { FranceComponent } from './france/france.component';
import { EnglandComponent } from './england/england.component'; import { EnglandComponent } from './england/england.component';
import {ContactUsComponent} from './contact-us/contact-us.component';
import { NgModule } from '@angular/core'; import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router'; import { RouterModule, Routes } from '@angular/router';
const routes: Routes = [ const routes: Routes = [
{path:'england', component: EnglandComponent}, {path:'england', component: EnglandComponent},
{path:'france', component: FranceComponent}, {path:'france', component: FranceComponent},
{path:'account', component: AccountComponent}, {path:'account', component: AccountComponent},
{path:'greece', component: GreeceComponent}, {path:'greece', component: GreeceComponent},
{path:'spain', component: SpainComponent} {path:'spain', component: SpainComponent},
{path: 'contact-us', component: ContactUsComponent}
]; ];
@NgModule({ @NgModule({
......
...@@ -16,4 +16,8 @@ ...@@ -16,4 +16,8 @@
display: flex; display: flex;
justify-content: space-evenly; justify-content: space-evenly;
width: 100%; width: 100%;
}
.link{
cursor: pointer;
} }
\ No newline at end of file
...@@ -13,6 +13,7 @@ import { SpainComponent } from './spain/spain.component'; ...@@ -13,6 +13,7 @@ import { SpainComponent } from './spain/spain.component';
import { AccountComponent } from './account/account.component'; import { AccountComponent } from './account/account.component';
import {FormsModule} from '@angular/forms'; import {FormsModule} from '@angular/forms';
import {ReactiveFormsModule} from '@angular/forms'; import {ReactiveFormsModule} from '@angular/forms';
import { ContactUsComponent } from './contact-us/contact-us.component';
@NgModule({ @NgModule({
declarations: [ declarations: [
...@@ -23,7 +24,8 @@ import {ReactiveFormsModule} from '@angular/forms'; ...@@ -23,7 +24,8 @@ import {ReactiveFormsModule} from '@angular/forms';
FranceComponent, FranceComponent,
GreeceComponent, GreeceComponent,
SpainComponent, SpainComponent,
AccountComponent AccountComponent,
ContactUsComponent
], ],
imports: [ imports: [
BrowserModule, BrowserModule,
......
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { ContactUsComponent } from './contact-us.component';
describe('ContactUsComponent', () => {
let component: ContactUsComponent;
let fixture: ComponentFixture<ContactUsComponent>;
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ ContactUsComponent ]
})
.compileComponents();
});
beforeEach(() => {
fixture = TestBed.createComponent(ContactUsComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-contact-us',
templateUrl: './contact-us.component.html',
styleUrls: ['./contact-us.component.css']
})
export class ContactUsComponent implements OnInit {
constructor() { }
ngOnInit(): void {
}
}
...@@ -21,4 +21,8 @@ ul { ...@@ -21,4 +21,8 @@ ul {
position: relative; position: relative;
float: left; float: left;
padding-left: 20px;; padding-left: 20px;;
}
.link{
cursor: pointer;
} }
\ No newline at end of file
...@@ -2,6 +2,6 @@ ...@@ -2,6 +2,6 @@
<ul> <ul>
<li>About Us</li> <li>About Us</li>
<li>Careers</li> <li>Careers</li>
<li>Contact Us</li> <li class="link" [routerLink]="['/contact-us']" >Contact Us</li>
</ul> </ul>
</div> </div>
\ No newline at end of file
...@@ -20,4 +20,8 @@ ...@@ -20,4 +20,8 @@
position:absolute; position:absolute;
right:10px; right:10px;
margin-top: 30px; margin-top: 30px;
}
.link{
cursor: pointer;
} }
\ No newline at end of file
...@@ -6,6 +6,6 @@ ...@@ -6,6 +6,6 @@
<button [routerLink]= "['/spain']">Spain</button> <button [routerLink]= "['/spain']">Spain</button>
</div> </div>
<span class='account'> <span class='account'>
<i class="fa fa-user" [routerLink]="['/account']" ></i> <i class="fa fa-user link" [routerLink]="['/account']" ></i>
</span> </span>
</div> </div>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment