Backport: fix interface labels are not persistant
Some checks failed
Build / build (push) Has been cancelled

This commit is contained in:
grossmj 2024-12-23 15:07:09 +07:00
parent 608fcfd04e
commit ee5b88e19a
No known key found for this signature in database
GPG Key ID: 1E7DD6DBB53FF3D7

View File

@ -31,6 +31,11 @@ export class MapSettingsService {
} else {
localStorage.setItem('symbolScaling', 'true');
}
if (localStorage.getItem('showInterfaceLabels')) {
this.showInterfaceLabels = localStorage.getItem('showInterfaceLabels') === 'true' ? true : false;
} else {
localStorage.setItem('showInterfaceLabels', 'true');
}
}
public getSymbolScaling(): boolean {
@ -72,6 +77,12 @@ export class MapSettingsService {
toggleShowInterfaceLabels(value: boolean) {
this.showInterfaceLabels = value;
localStorage.removeItem('showInterfaceLabels');
if (value) {
localStorage.setItem('showInterfaceLabels', 'true');
} else {
localStorage.setItem('showInterfaceLabels', 'false');
}
}
toggleIntegrateInterfaceLabels(value: boolean) {