diff --git a/src/app/login/login.component.ts b/src/app/login/login.component.ts index d837f5cfe..9add5612d 100644 --- a/src/app/login/login.component.ts +++ b/src/app/login/login.component.ts @@ -8,6 +8,7 @@ import {MatInputModule} from "@angular/material/input"; import {MatProgressSpinnerModule} from "@angular/material/progress-spinner"; import {FormBuilder, FormGroup, ReactiveFormsModule, Validators} from "@angular/forms"; import {IdentityService} from "../identity.service"; +import {PageMetaService} from '../page-meta.service'; import {environment} from "../../environments/environment"; import {EMAIL_REGEXP} from "../validators/patterns"; import {ActivatedRoute, Router} from "@angular/router"; @@ -60,6 +61,7 @@ export class LoginComponent implements OnInit, AfterViewInit, OnDestroy{ constructor( private readonly formBuilder: FormBuilder, private readonly identityService: IdentityService, + private readonly pageMeta: PageMetaService, private readonly activatedRoute: ActivatedRoute, private readonly router: Router, @Inject(PLATFORM_ID) private platformId: Object, @@ -75,6 +77,8 @@ export class LoginComponent implements OnInit, AfterViewInit, OnDestroy{ } ngOnInit() { + this.pageMeta.setCommon('Login', 'Login to your Big Give account', null); + if (isPlatformBrowser(this.platformId)) { document.body.classList.add('primary-colour'); } diff --git a/src/app/my-account/my-account.component.ts b/src/app/my-account/my-account.component.ts index d8d85fc89..72bce8db0 100644 --- a/src/app/my-account/my-account.component.ts +++ b/src/app/my-account/my-account.component.ts @@ -79,8 +79,8 @@ export class MyAccountComponent implements OnInit { ngOnInit() { this.pageMeta.setCommon( - 'Big Give - My account', - 'Big Give – discover campaigns and donate', + 'My account', + 'Manage your Big Give account', 'https://images-production.thebiggive.org.uk/0011r00002IMRknAAH/CCampaign%20Banner/db3faeb1-d20d-4747-bb80-1ae9286336a3.jpg', ); diff --git a/src/app/my-donations/my-donations.component.ts b/src/app/my-donations/my-donations.component.ts index 7bdaabc8e..5202e24d5 100644 --- a/src/app/my-donations/my-donations.component.ts +++ b/src/app/my-donations/my-donations.component.ts @@ -33,7 +33,7 @@ export class MyDonationsComponent implements OnInit{ ngOnInit() { this.pageMeta.setCommon( - 'Big Give - Your Donation History', '', null + 'Your Donation History', 'Your Big Give donations', null ); this.donations = this.route.snapshot.data.donations.map(withComputedProperties); diff --git a/src/app/my-regular-giving/my-regular-giving.component.ts b/src/app/my-regular-giving/my-regular-giving.component.ts index 515923880..a2ccb7155 100644 --- a/src/app/my-regular-giving/my-regular-giving.component.ts +++ b/src/app/my-regular-giving/my-regular-giving.component.ts @@ -41,7 +41,7 @@ export class MyRegularGivingComponent implements OnInit{ ngOnInit() { this.pageMeta.setCommon( - 'Big Give - Your Regular Giving Mandates', '', null + 'Your Regular Giving Mandates', 'Donations you make to support charities each month', null ); this.mandates = this.route.snapshot.data.mandates; diff --git a/src/app/page-meta.service.ts b/src/app/page-meta.service.ts index 0c1c96b37..907999f31 100644 --- a/src/app/page-meta.service.ts +++ b/src/app/page-meta.service.ts @@ -31,6 +31,10 @@ export class PageMetaService { const link = links[0]; link.setAttribute('href', canonicalUri); + if (!title.includes('Big Give')) { + title = `${title} – Big Give`; + } + this.title.setTitle(title); this.meta.updateTag( { property: 'og:title', content: title } ); this.meta.updateTag( { property: 'twitter:title', content: title } ); diff --git a/src/app/register/register.component.ts b/src/app/register/register.component.ts index 1442ff5c3..9096ceb1a 100644 --- a/src/app/register/register.component.ts +++ b/src/app/register/register.component.ts @@ -17,6 +17,7 @@ import {transferFundsPath} from "../app-routing"; import {WidgetInstance} from "friendly-challenge"; import {flags} from "../featureFlags"; import {isAllowableRedirectPath, LoginNavigationState} from "../login/login.component"; +import {PageMetaService} from '../page-meta.service'; @Component({ selector: 'app-register', @@ -46,6 +47,7 @@ export class RegisterComponent implements OnInit, OnDestroy, AfterViewInit { constructor( private readonly formBuilder: FormBuilder, private readonly identityService: IdentityService, + private readonly pageMeta: PageMetaService, private readonly router: Router, private sanitizer: DomSanitizer, private readonly activatedRoute: ActivatedRoute, @@ -60,6 +62,8 @@ export class RegisterComponent implements OnInit, OnDestroy, AfterViewInit { } ngOnInit() { + this.pageMeta.setCommon('Register', 'Register for a Big Give account', null); + if (isPlatformBrowser(this.platformId)) { document.body.classList.add('primary-colour'); }