Skip to content

Commit df6940a

Browse files
fix[frontend](tooltips): moved tooltip position to body so they can be showed above any other copmonent
1 parent 9b94cd1 commit df6940a

File tree

3 files changed

+9
-16
lines changed

3 files changed

+9
-16
lines changed

frontend/src/app/app.module.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import {FormsModule, ReactiveFormsModule} from '@angular/forms';
44
import {BrowserModule} from '@angular/platform-browser';
55
import {BrowserAnimationsModule} from '@angular/platform-browser/animations';
66
import {RouterModule} from '@angular/router';
7-
import {NgbDatepickerConfig, NgbModalConfig} from '@ng-bootstrap/ng-bootstrap';
7+
import {NgbDatepickerConfig, NgbModalConfig, NgbTooltipConfig} from '@ng-bootstrap/ng-bootstrap';
88
import {TranslateLoader, TranslateModule} from '@ngx-translate/core';
99
import {TranslateHttpLoader} from '@ngx-translate/http-loader';
1010
import * as moment from 'moment';
@@ -151,8 +151,9 @@ export function initTimezoneFormat(apiChecker: ApiServiceCheckerService,
151151
schemas: [CUSTOM_ELEMENTS_SCHEMA],
152152
})
153153
export class AppModule {
154-
constructor(private dpConfig: NgbDatepickerConfig, private config: NgbModalConfig) {
154+
constructor(private dpConfig: NgbDatepickerConfig, private config: NgbModalConfig, private tooltipConfig: NgbTooltipConfig) {
155155
this.dpConfig.minDate = {year: moment().year() - 100, month: 1, day: 1};
156156
config.backdrop = 'static';
157+
this.tooltipConfig.container = 'body';
157158
}
158159
}

frontend/src/environments/environment.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44

55
export const environment = {
66
production: false,
7-
// SERVER_API_URL: 'https://192.168.1.18/',
8-
SERVER_API_URL: 'http://localhost:8080/',
7+
SERVER_API_URL: 'https://192.168.1.18/',
8+
// SERVER_API_URL: 'http://localhost:8080/',
99
SERVER_API_CONTEXT: '',
1010
SESSION_AUTH_TOKEN: window.location.host.split(':')[0].toLocaleUpperCase(),
1111
WEBSOCKET_URL: '//localhost:8080',

frontend/src/styles.scss

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -392,18 +392,18 @@ p {
392392

393393
//tooltip
394394
.utm-tooltip, .utm-tooltip-top, .utm-tooltip-bottom, .utm-tooltip-left {
395-
z-index: 999 !important;
396395
opacity: 10 !important;
396+
position: absolute !important;
397397
}
398398

399399
.tooltip {
400-
z-index: 1240 !important;
400+
z-index: 100000 !important;
401401
}
402402

403403
.utm-tooltip .tooltip-inner {
404404
//background-color: $grey-color;
405405
font-size: 100%;
406-
z-index: 999 !important;
406+
z-index: 99999 !important;
407407
}
408408

409409
.utm-tooltip-bottom .tooltip-inner {
@@ -415,19 +415,16 @@ p {
415415
.utm-tooltip-top .tooltip-inner {
416416
//background-color: $grey-color !important;
417417
font-size: 100%;
418-
z-index: 999 !important;
419418
}
420419

421420
.utm-tooltip-left .tooltip-inner {
422421
//background-color: $grey-color !important;
423422
font-size: 100%;
424-
z-index: 999 !important;
425423
}
426424

427425
.utm-tooltip-right .tooltip-inner {
428426
//background-color: $grey-color !important;
429427
font-size: 100%;
430-
z-index: 999 !important;
431428
}
432429

433430
.utm-tooltip-top .arrow::before {
@@ -676,7 +673,7 @@ app-header {
676673
}
677674

678675
.popover {
679-
z-index: 2065 !important;
676+
z-index: 99999 !important;
680677
}
681678

682679
.utm-popover-right {
@@ -726,7 +723,6 @@ app-header {
726723
.utm-popover-xs {
727724
//top: 37px !important;
728725
max-width: 300px !important;
729-
z-index: 2062 !important;
730726
}
731727

732728
.popover-header {
@@ -756,7 +752,6 @@ app-header {
756752
.utm-popover-xs {
757753
//top: 37px !important;
758754
max-width: 300px !important;
759-
z-index: 2062 !important;
760755
}
761756

762757
.popover-header {
@@ -1205,9 +1200,6 @@ $topnav-background-color: #FFFFFF;
12051200
z-index: 2061 !important;
12061201
}
12071202

1208-
.tooltip {
1209-
z-index: 2062 !important;
1210-
}
12111203

12121204
.alert-warning {
12131205
color: #232f3e !important;

0 commit comments

Comments
 (0)