summaryrefslogtreecommitdiffstats
path: root/portal-FE-os/src
diff options
context:
space:
mode:
Diffstat (limited to 'portal-FE-os/src')
-rw-r--r--portal-FE-os/src/app/app.component.html4
-rw-r--r--portal-FE-os/src/app/app.component.scss12
-rw-r--r--portal-FE-os/src/app/app.component.ts44
-rw-r--r--portal-FE-os/src/environments/environment.prod.ts3
-rw-r--r--portal-FE-os/src/environments/environment.ts3
-rw-r--r--portal-FE-os/src/favicon.icobin1150 -> 2102 bytes
6 files changed, 58 insertions, 8 deletions
diff --git a/portal-FE-os/src/app/app.component.html b/portal-FE-os/src/app/app.component.html
index dea5177c..2c914c52 100644
--- a/portal-FE-os/src/app/app.component.html
+++ b/portal-FE-os/src/app/app.component.html
@@ -35,5 +35,7 @@
-->
-
+<div class="diaplay-banner" *ngIf="diaplayBanner">
+ <span>{{browserCompatibilityMsg}}</span>
+</div>
<router-outlet></router-outlet>
diff --git a/portal-FE-os/src/app/app.component.scss b/portal-FE-os/src/app/app.component.scss
index 7a773398..e739496d 100644
--- a/portal-FE-os/src/app/app.component.scss
+++ b/portal-FE-os/src/app/app.component.scss
@@ -34,4 +34,14 @@
* ============LICENSE_END============================================
*
*
- */ \ No newline at end of file
+ */
+
+ .diaplay-banner{
+ margin-top: 14px;
+ background-color: yellow;
+ font-weight: bold;
+ position: fixed;
+ z-index: 9999;
+ margin-left: 34em;
+ height: 24px;
+} \ No newline at end of file
diff --git a/portal-FE-os/src/app/app.component.ts b/portal-FE-os/src/app/app.component.ts
index dbfb568f..389153bd 100644
--- a/portal-FE-os/src/app/app.component.ts
+++ b/portal-FE-os/src/app/app.component.ts
@@ -35,13 +35,49 @@
*
*
*/
-import { Component } from '@angular/core';
+import { Component, OnInit } from '@angular/core';
+import { environment } from 'src/environments/environment';
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.scss']
})
-export class AppComponent {
-
-}
+export class AppComponent implements OnInit {
+ diaplayBanner : boolean = false;
+ api = environment.api;
+ browserCompatibilityMsg: string;
+
+ ngOnInit() {
+ this.diaplayBanner = false;
+ this.browserCompatibilityMsg = this.api.browserCompatibilityMsg;
+ this.getBrowserName();
+ }
+
+ /**
+ * Identify Browser
+ */
+ getBrowserName() {
+ const agent = window.navigator.userAgent.toLowerCase();
+ switch (true) {
+ case agent.indexOf('edge') > -1:
+ return 'edge';
+ case agent.indexOf('opr') > -1 && !!(<any>window).opr:
+ this.diaplayBanner = true;
+ return 'opera';
+ case agent.indexOf('chrome') > -1 && !!(<any>window).chrome:
+ return 'chrome';
+ case agent.indexOf('trident') > -1:
+ this.diaplayBanner = true;
+ return 'ie';
+ case agent.indexOf('firefox') > -1:
+ return 'firefox';
+ case agent.indexOf('safari') > -1:
+ this.diaplayBanner = true;
+ return 'safari';
+ default:
+ this.diaplayBanner = true;
+ return 'other';
+ }
+ }
+} \ No newline at end of file
diff --git a/portal-FE-os/src/environments/environment.prod.ts b/portal-FE-os/src/environments/environment.prod.ts
index db6b5bf5..7cc34da5 100644
--- a/portal-FE-os/src/environments/environment.prod.ts
+++ b/portal-FE-os/src/environments/environment.prod.ts
@@ -125,7 +125,8 @@ export const environment = {
"footerLogoImagePath": "",
"footerLogoText": "",
"intraSearcLink": "",
- "extraSearcLink": "https://wiki.onap.org/dosearchsite.action?cql=siteSearch+~+searchStringPlaceHolder&queryString=searchStringPlaceHolder"
+ "extraSearcLink": "https://wiki.onap.org/dosearchsite.action?cql=siteSearch+~+searchStringPlaceHolder&queryString=searchStringPlaceHolder",
+ "browserCompatibilityMsg": "This Application is best viewed on Firefox, Chrome and Edge."
},
"getAccessUrl": "",
"getAccessName":"",
diff --git a/portal-FE-os/src/environments/environment.ts b/portal-FE-os/src/environments/environment.ts
index 0482c20c..d412522f 100644
--- a/portal-FE-os/src/environments/environment.ts
+++ b/portal-FE-os/src/environments/environment.ts
@@ -129,7 +129,8 @@ export const environment = {
"footerLogoImagePath": "",
"footerLogoText": "",
"intraSearcLink": "",
- "extraSearcLink": "https://wiki.onap.org/dosearchsite.action?cql=siteSearch+~+searchStringPlaceHolder&queryString=searchStringPlaceHolder"
+ "extraSearcLink": "https://wiki.onap.org/dosearchsite.action?cql=siteSearch+~+searchStringPlaceHolder&queryString=searchStringPlaceHolder",
+ "browserCompatibilityMsg": "This Application is best viewed on Firefox, Chrome and Edge."
},
"getAccessUrl": "",
"getAccessName": "",
diff --git a/portal-FE-os/src/favicon.ico b/portal-FE-os/src/favicon.ico
index d2c5e0fc..cb712ebd 100644
--- a/portal-FE-os/src/favicon.ico
+++ b/portal-FE-os/src/favicon.ico
Binary files differ