Disable adding new elements-popup if the userbadge is disabled; add small cosmetic changes

This commit is contained in:
Pieter Vander Vennet 2021-07-18 21:48:11 +02:00
parent 186405784e
commit 219895191d
3 changed files with 15 additions and 2 deletions

View file

@ -193,6 +193,12 @@ export default class State {
"Disables/Enables the layer control");
this.featureSwitchAddNew = featSw("fs-add-new", (layoutToUse) => layoutToUse?.enableAddNewPoints ?? true,
"Disables/Enables the 'add new feature'-popup. (A theme without presets might not have it in the first place)");
this.featureSwitchUserbadge.addCallbackAndRun(userbadge => {
if (!userbadge) {
this.featureSwitchAddNew.setData(false)
}
})
this.featureSwitchWelcomeMessage = featSw("fs-welcome-message", () => true,
"Disables/enables the help menu or welcome message");
this.featureSwitchIframe = featSw("fs-iframe", () => false,