Use label instead of value if it is available

This commit is contained in:
Willem Dantuma 2019-11-11 11:08:23 +01:00
parent b620cedb6d
commit 67e0e5ed5d

View File

@ -15,7 +15,7 @@
</tr>
<tr *ngFor="let entry of layer.renderer.colorMap.entries; let i = index ">
<td class="legend-items"><div [style.background-color]="getHex(entry.color)"></div></td>
<td class="legend-items-text">{{entry.value | number:'1.0-2'}} {{legendunit}}</td>
<td class="legend-items-text"><span *ngIf="!entry.label">{{entry.value | number:'1.0-2'}} {{legendunit}}</span><span *ngIf="entry.label">{{entry.label}}</span></td>
<!--<td class="histogram-items-text"><span *ngIf="histogramenabled">{{entry.value}} {{histogramunit}}</span></td>
<td class="histogram-items">
<div *ngIf="histogramenabled" [style.background-color]="getHex(selectedColorMap.noValue)" [style.width]="getPart(selectedColorMap, entry)">