diff --git a/CHANGELOG.md b/CHANGELOG.md index 731686405..d46c01b16 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +- Improved the content of the landing page +- Improved the content of the Frequently Asked Questions (FAQ) page - Set the exposed port as an environment variable (`PORT`) in `Dockerfile` - Upgraded `chart.js` from version `4.0.1` to `4.2.0` - Upgraded `ionicons` from version `6.0.4` to `6.1.2` diff --git a/apps/client/src/app/pages/faq/faq-page.component.ts b/apps/client/src/app/pages/faq/faq-page.component.ts index c7e2b436d..b93004337 100644 --- a/apps/client/src/app/pages/faq/faq-page.component.ts +++ b/apps/client/src/app/pages/faq/faq-page.component.ts @@ -1,5 +1,7 @@ -import { Component, OnDestroy } from '@angular/core'; -import { Subject } from 'rxjs'; +import { ChangeDetectorRef, Component, OnDestroy } from '@angular/core'; +import { UserService } from '@ghostfolio/client/services/user/user.service'; +import { User } from '@ghostfolio/common/interfaces'; +import { Subject, takeUntil } from 'rxjs'; @Component({ host: { class: 'page' }, @@ -8,9 +10,26 @@ import { Subject } from 'rxjs'; templateUrl: './faq-page.html' }) export class FaqPageComponent implements OnDestroy { + public user: User; + private unsubscribeSubject = new Subject(); - public constructor() {} + public constructor( + private changeDetectorRef: ChangeDetectorRef, + private userService: UserService + ) {} + + public ngOnInit() { + this.userService.stateChanged + .pipe(takeUntil(this.unsubscribeSubject)) + .subscribe((state) => { + if (state?.user) { + this.user = state.user; + + this.changeDetectorRef.markForCheck(); + } + }); + } public ngOnDestroy() { this.unsubscribeSubject.next(); diff --git a/apps/client/src/app/pages/faq/faq-page.html b/apps/client/src/app/pages/faq/faq-page.html index 7e18aa57e..2ffd78d08 100644 --- a/apps/client/src/app/pages/faq/faq-page.html +++ b/apps/client/src/app/pages/faq/faq-page.html @@ -115,7 +115,7 @@ >. - + I cannot find my broker in the list of platforms. What can I do?
@@ -68,6 +69,24 @@ >
+
-
+

How does Ghostfolio work?