-
-
-
-
-
-
+
+
+
+ User Interface
+
-
-
-
+
+
+
+
+
-
-
-
-
+
+
+
+
+
+
+
+
+ Places
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
Save
save
-
-
+
+
@@ -62,7 +90,8 @@
labels: {
language: this.$gettext("Language"),
theme: this.$gettext("Theme"),
- mapsAnimate: this.$gettext("Maps Animation"),
+ mapsAnimate: this.$gettext("Animation"),
+ mapsStyle: this.$gettext("Style"),
},
};
},
@@ -76,7 +105,7 @@
this.settings.save().then((s) => {
this.$config.updateSettings(s.getValues(), this.$vuetify);
- if(reload) {
+ if (reload) {
this.$notify.info(this.$gettext("Reloading..."));
this.$notify.blockUI();
setTimeout(() => window.location.reload(), 100);
diff --git a/frontend/src/resources/options.json b/frontend/src/resources/options.json
index 439359ef5..6b26e2f58 100644
--- a/frontend/src/resources/options.json
+++ b/frontend/src/resources/options.json
@@ -54,15 +54,33 @@
},
{
"text": "Fast",
- "value": 5000
+ "value": 2500
},
{
"text": "Medium",
- "value": 10000
+ "value": 6250
},
{
"text": "Slow",
- "value": 15000
+ "value": 10000
+ }
+ ],
+ "mapsStyle": [
+ {
+ "text": "Streets",
+ "value": "streets"
+ },
+ {
+ "text": "Hybrid",
+ "value": "hybrid"
+ },
+ {
+ "text": "Topographic",
+ "value": "topo"
+ },
+ {
+ "text": "Moonlight",
+ "value": "darkmatter"
}
]
}
diff --git a/internal/config/settings.go b/internal/config/settings.go
index 88df5d763..961797a30 100644
--- a/internal/config/settings.go
+++ b/internal/config/settings.go
@@ -10,14 +10,15 @@ import (
)
type MapsSettings struct {
- Animate int `json:"animate" yaml:"animate"`
+ Animate int `json:"animate" yaml:"animate"`
+ Style string `json:"style" yaml:"style"`
}
// Settings contains Web UI settings
type Settings struct {
- Theme string `json:"theme" yaml:"theme"`
- Language string `json:"language" yaml:"language"`
- Maps MapsSettings `json:"maps" yaml:"maps"`
+ Theme string `json:"theme" yaml:"theme"`
+ Language string `json:"language" yaml:"language"`
+ Maps MapsSettings `json:"maps" yaml:"maps"`
}
// NewSettings returns a empty Settings
@@ -27,6 +28,7 @@ func NewSettings() *Settings {
Language: "en",
Maps: MapsSettings{
Animate: 0,
+ Style: "streets",
},
}
}
diff --git a/internal/config/testdata/configEmpty.yml b/internal/config/testdata/configEmpty.yml
index a85153896..f01b3679b 100644
--- a/internal/config/testdata/configEmpty.yml
+++ b/internal/config/testdata/configEmpty.yml
@@ -2,3 +2,4 @@ theme: lavendel
language: german
maps:
animate: 0
+ style: streets