Feature: add possibility to show a scale on the map

This commit is contained in:
Pieter Vander Vennet 2024-09-12 01:53:47 +02:00
parent 0fdbf445be
commit 5a9ae3f104
6 changed files with 52 additions and 10 deletions

View file

@ -69,6 +69,8 @@ export default class UserRelatedState {
"button" | "button_click_right" | "button_click" | "click" | "click_right"
>("button_click_right")
public readonly showScale : UIEventSource<boolean>
/**
* Preferences as tags exposes many preferences and state properties as record.
* This is used to bridge the internal state with the usersettings.json layerconfig file
@ -123,6 +125,7 @@ export default class UserRelatedState {
documentation: "How adding a new feature is done",
}
)
this.showScale = UIEventSource.asBoolean(this.osmConnection.GetPreference("preference-show-scale","false"))
this.imageLicense = this.osmConnection.GetPreference("pictures-license", "CC0", {
documentation: "The license under which new images are uploaded",