Skip to content

Commit 1331292

Browse files
authored
Merge branch 'develop' into feature/distributionChart
2 parents b28ee8d + bf0606f commit 1331292

File tree

5 files changed

+21
-12
lines changed

5 files changed

+21
-12
lines changed

frontend/src/app/modules/result-selection/components/application/application.component.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<div class="card form-horizontal">
22
<h2>{{ 'frontend.de.iteratec.osm.resultSelection.application.title' | translate }}</h2>
3-
<select (ngModelChange)="onSelectionChange()" [(ngModel)]="selectedApplications" class="form-control" id='applications-selection'
3+
<select [(ngModel)]="selectedApplications" (ngModelChange)="onSelectionChange()" class="form-control" id='applications-selection'
44
multiple>
55
<ng-container *ngIf="filteredApplications?.length > 0; else elseBlock">
66
<option *ngFor="let application of filteredApplications" [ngValue]="application.id">

frontend/src/app/modules/result-selection/components/measurands/measurand-select/measurand-select.component.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<select (ngModelChange)="selectMeasurand()" [(ngModel)]="selectedMeasurand" [compareWith]="compareMeasurands"
1+
<select [(ngModel)]="selectedMeasurand" (ngModelChange)="selectMeasurand()" [compareWith]="compareMeasurands"
22
class="form-control">
33
<optgroup label="{{'frontend.de.iteratec.osm.performance-aspects' | translate}}">
44
<option *ngFor="let type of (perfAspectTypes$ |async)?.data" [ngValue]="type">

frontend/src/app/modules/result-selection/components/page-location-connectivity/selection-data/selection-data.component.html

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
<div class="form-group">
2-
<select (ngModelChange)="filterSelectableItems(parentSelection)" [(ngModel)]="parentSelection" [style.opacity]="determineOpacity(parentSelection.length)" class="form-control"
2+
<select [(ngModel)]="parentSelection" (ngModelChange)="filterSelectableItems(parentSelection)"
3+
[style.opacity]="determineOpacity(parentSelection.length)" class="form-control"
34
id="result-selection-parent-selection"
45
multiple="multiple">
56
<ng-container *ngIf="(uniqueParents$ | async)?.length > 0; else noResults">
@@ -11,7 +12,8 @@
1112
</option>
1213
</ng-template>
1314
</select>
14-
<div (click)="selectAllParentsCheckbox.checked = true; parentSelection = []; filterSelectableItems(parentSelection)" *ngIf="!parentRequired"
15+
<div (click)="selectAllParentsCheckbox.checked = true; parentSelection = []; filterSelectableItems(parentSelection)"
16+
*ngIf="!parentRequired"
1517
class="checkbox-inline">
1618
<input #selectAllParentsCheckbox [checked]="parentSelection.length < 1" id="selectAllParentsCheckbox"
1719
type="checkbox">
@@ -24,9 +26,10 @@
2426
<strong>{{ 'frontend.de.iteratec.osm.resultSelection.pageBrowserConnectivity.label.' + childType | translate }}
2527
:</strong>
2628
</label>
27-
<ng-select (ngModelChange)="updateResultSelectionCommand()"
28-
[(ngModel)]="childSelection" [closeOnSelect]="true" [groupBy]="'parent.id'"
29-
[items]="childData$ | async" [multiple]="true" bindLabel="name" bindValue="id" id="result-selection-child-selection"
29+
<ng-select [(ngModel)]="childSelection" (ngModelChange)="updateResultSelectionCommand()"
30+
[closeOnSelect]="true" [groupBy]="'parent.id'"
31+
[items]="childData$ | async" [multiple]="true" bindLabel="name" bindValue="id"
32+
id="result-selection-child-selection"
3033
placeholder="{{ 'frontend.de.iteratec.osm.resultSelection.pageBrowserConnectivity.selectOption.placeholder' | translate }}">
3134
</ng-select>
3235
<div (click)="selectAllChildrenCheckbox.checked = true; childSelection = []; updateResultSelectionCommand()"

frontend/src/app/modules/result-selection/components/time-frame/time-frame.component.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ <h2>
1212
{{ 'frontend.de.iteratec.osm.resultSelection.timeFrame.aggregation.heading' | translate }}:
1313
</label>
1414
<div class="col-md-8">
15-
<select (ngModelChange)="selectInterval()" [(ngModel)]="aggregationIntervalInSeconds" class="form-control">
15+
<select [(ngModel)]="aggregationIntervalInSeconds" (ngModelChange)="selectInterval()" class="form-control">
1616
<option *ngFor="let intervals of selectableAggregationIntervalsInSeconds" [value]="intervals">
1717
{{ 'frontend.de.iteratec.osm.resultSelection.timeFrame.aggregation.intervals.' + intervals | translate }}
1818
</option>
@@ -25,7 +25,7 @@ <h2>
2525
{{ 'frontend.de.iteratec.osm.resultSelection.timeFrame.heading' | translate }}:
2626
</label>
2727
<div class="col-md-8">
28-
<select (ngModelChange)="selectTimeFrame()" [(ngModel)]="timeFrameInSeconds" class="form-control">
28+
<select [(ngModel)]="timeFrameInSeconds" (ngModelChange)="selectTimeFrame()" class="form-control">
2929
<option *ngFor="let seconds of selectableTimeFramesInSeconds" [value]="seconds">
3030
{{ 'frontend.de.iteratec.osm.resultSelection.timeFrame.seconds.' + seconds | translate }}
3131
</option>

frontend/src/app/modules/time-series/services/line-chart.service.ts

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -358,6 +358,9 @@ export class LineChartService {
358358
.attr('class', 'legend-text')
359359
.attr('x', 15)
360360
.attr('y', ChartCommons.COLOR_PREVIEW_SIZE)
361+
.style('opacity', (datum) => {
362+
return (this.legendDataMap[datum].show) ? 1 : 0.2;
363+
})
361364
.text(datum => this.legendDataMap[datum].text);
362365
return legendElement;
363366
},
@@ -538,9 +541,9 @@ export class LineChartService {
538541
// Remove after resize
539542
chart.selectAll('.lines').remove();
540543
// Remove old dots
541-
this._chartContentContainer.select('.single-dots').remove();
544+
chart.selectAll('.single-dots').remove();
542545
// Remove old dots
543-
this._chartContentContainer.select('.dots').remove();
546+
chart.selectAll('.dots').remove();
544547
}
545548
// Create one group per line / data entry
546549
this._chartContentContainer
@@ -824,6 +827,9 @@ export class LineChartService {
824827

825828
this._legendGroupColumnWidth = maximumLabelWidth + ChartCommons.COLOR_PREVIEW_SIZE + 30;
826829
this._legendGroupColumns = Math.floor(this._width / this._legendGroupColumnWidth);
830+
if (this._legendGroupColumns < 1) {
831+
this._legendGroupColumns = 1;
832+
}
827833
this._legendGroupHeight = Math.ceil(labels.length / this._legendGroupColumns) * ChartCommons.LABEL_HEIGHT + 30;
828834
};
829835

@@ -1086,7 +1092,7 @@ export class LineChartService {
10861092
this.translationService.get(`frontend.de.iteratec.isr.measurand.group.${axisLabelKey}`).pipe(take(1)).subscribe(title => {
10871093
d3Select(`.axis-unit${index}`).append('text')
10881094
.attr('class', 'description unit')
1089-
.attr('transform', `translate(${xPosition}, ${(this._height / 2 - this._margin.bottom)}) rotate(-90)`)
1095+
.attr('transform', `translate(${xPosition}, ${this._height / 2}) rotate(-90)`)
10901096
.text(`${title} [${measurandGroups[axisLabelKey]}]`);
10911097
});
10921098
});

0 commit comments

Comments
 (0)