Merge pull request #92 in TEA/mina-sidor-fa-web from feature/version-number to develop
Squashed commit of the following: commit 2b0f98a4151d3afddd6e717cf3495dd4f78fb79e Author: Erik Tiekstra <erik.tiekstra@arbetsformedlingen.se> Date: Tue Sep 14 15:56:22 2021 +0200 Removed unused files commit 0c308eea737b181bb56628c964d6a15f8f142712 Author: Erik Tiekstra <erik.tiekstra@arbetsformedlingen.se> Date: Tue Sep 14 15:52:34 2021 +0200 Implemented version number so it is saved in environments file upon build
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
<digi-logo af-color="secondary"></digi-logo>
|
||||
<dl class="footer__version" *ngIf="versionInfoVisible">
|
||||
<dt>Aktuell version</dt>
|
||||
<dd><markdown src="assets/VERSION.md"></markdown></dd>
|
||||
<dd>{{version}}</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<nav class="footer__nav">
|
||||
|
||||
@@ -10,9 +10,10 @@ import { environment } from '@msfa-environment';
|
||||
})
|
||||
export class FooterComponent {
|
||||
activeFeatures: Feature[] = environment.activeFeatures;
|
||||
version: string = environment.version;
|
||||
|
||||
get versionInfoVisible(): boolean {
|
||||
return this.activeFeatures.includes(Feature.VERSION_INFO);
|
||||
return this.version && this.activeFeatures.includes(Feature.VERSION_INFO);
|
||||
}
|
||||
get releasesVisible(): boolean {
|
||||
return this.activeFeatures.includes(Feature.RELEASES);
|
||||
|
||||
@@ -1,13 +1,12 @@
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { CUSTOM_ELEMENTS_SCHEMA, NgModule } from '@angular/core';
|
||||
import { RouterModule } from '@angular/router';
|
||||
import { MarkdownModule } from 'ngx-markdown';
|
||||
import { FooterComponent } from './footer.component';
|
||||
|
||||
@NgModule({
|
||||
schemas: [CUSTOM_ELEMENTS_SCHEMA],
|
||||
declarations: [FooterComponent],
|
||||
imports: [CommonModule, MarkdownModule.forChild(), RouterModule],
|
||||
imports: [CommonModule, RouterModule],
|
||||
exports: [FooterComponent],
|
||||
})
|
||||
export class FooterModule {}
|
||||
|
||||
@@ -2,6 +2,7 @@ import { Feature } from '@msfa-enums/feature.enum';
|
||||
|
||||
export interface Environment {
|
||||
environment: 'api' | 'local' | 'acc' | 'prod';
|
||||
version?: string;
|
||||
clientId: string;
|
||||
loginUrl: string;
|
||||
logoutUrl: string;
|
||||
|
||||
Reference in New Issue
Block a user