Allow use of specific default liveatlas by setting a map's icon to "liveatlas_[icon_name]" in the map plugin's configuration
This commit is contained in:
parent
b94c6c66e2
commit
53c2ecab71
@ -93,7 +93,7 @@ export default class LiveAtlasMapDefinition {
|
|||||||
}
|
}
|
||||||
|
|
||||||
hasCustomIcon(): boolean {
|
hasCustomIcon(): boolean {
|
||||||
return !!this.icon;
|
return !!this.icon && !this.icon.startsWith('liveatlas_');
|
||||||
}
|
}
|
||||||
|
|
||||||
getIcon(): string {
|
getIcon(): string {
|
||||||
@ -101,6 +101,10 @@ export default class LiveAtlasMapDefinition {
|
|||||||
mapType: string;
|
mapType: string;
|
||||||
|
|
||||||
if(this.icon) {
|
if(this.icon) {
|
||||||
|
if(this.icon.startsWith('liveatlas_')) {
|
||||||
|
return this.icon.replace('liveatlas_', '');
|
||||||
|
}
|
||||||
|
|
||||||
return this.icon;
|
return this.icon;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user