changeset 4240:a4f76e170290

styles-config: adjust names of layers in ColorSetting component
author Fadi Abbud <fadi.abbud@intevation.de>
date Thu, 22 Aug 2019 09:20:38 +0200
parents 81153eae048c
children 27434b0d4d96 1458c9b0fdaa
files client/src/components/systemconfiguration/ColorSettings.vue client/src/components/systemconfiguration/defaults.js
diffstat 2 files changed, 17 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/client/src/components/systemconfiguration/ColorSettings.vue	Thu Aug 22 08:56:22 2019 +0200
+++ b/client/src/components/systemconfiguration/ColorSettings.vue	Thu Aug 22 09:20:38 2019 +0200
@@ -134,12 +134,12 @@
           strokeColor: initSColor
         },
         {
-          name: "Distance Marks",
+          name: "Distance Marks, Axis",
           strokeColor: initSColor,
           fillColor: initSColor
         },
         {
-          name: "Distance Marks, Axis",
+          name: "Distance Marks",
           strokeColor: initSColor,
           fillColor: initSColor
         },
@@ -227,15 +227,16 @@
           feature.strokeColor = defaults.feature_colours_waterway_area_stroke;
           break;
         }
-        case "Distance Marks": {
+        case "Distance Marks, Axis": {
           feature.strokeColor = defaults.feature_colours_distancemarks_stroke;
           feature.fillColor = defaults.feature_colours_distancemarks_fill;
           break;
         }
-        case "Distance Marks, Axis": {
+        case "Distance Marks": {
           feature.strokeColor =
-            defaults.feature_colours_distancemarks_axis_stroke;
-          feature.fillColor = defaults.feature_colours_distancemarks_axis_fill;
+            defaults.feature_colours_distancemarks_ashore_stroke;
+          feature.fillColor =
+            defaults.feature_colours_distancemarks_ashore_fill;
           break;
         }
       }
@@ -393,7 +394,7 @@
           }
           break;
         }
-        case "Distance Marks": {
+        case "Distance Marks, Axis": {
           if (
             strokeC !== this.config.distance_marks_stroke ||
             fillC !== this.config.distance_marks_fill
@@ -410,16 +411,16 @@
           }
           break;
         }
-        case "Distance Marks, Axis": {
+        case "Distance Marks": {
           if (
-            strokeC !== this.config.distance_marks_axis_stroke ||
-            fillC !== this.config.distance_marks_axis_fill
+            strokeC !== this.config.distance_marks_ashore_stroke ||
+            fillC !== this.config.distance_marks_ashore_fill
           ) {
             this.$store
               .dispatch("application/saveConfig", {
-                distance_marks_axis_stroke:
+                distance_marks_ashore_stroke:
                   feature.strokeColor.hex || feature.strokeColor,
-                distance_marks_axis_fill:
+                distance_marks_ashore_fill:
                   feature.fillColor.hex || feature.fillColor
               })
               .finally(() => this.$store.dispatch("application/loadConfig"));
@@ -453,9 +454,9 @@
       this.config.distance_marks_stroke || initSColor;
     this.features[6].fillColor = this.config.distance_marks_fill || initFColor;
     this.features[7].strokeColor =
-      this.config.distance_marks_axis_stroke || initSColor;
+      this.config.distance_marks_ashore_stroke || initSColor;
     this.features[7].fillColor =
-      this.config.distance_marks_axis_fill || initFColor;
+      this.config.distance_marks_ashore_fill || initFColor;
     this.features[8].strokeColor = this.config.waterwayprofiles_stroke;
     this.features[9].strokeColor =
       this.config.waterway_axis_stroke || initSColor;
--- a/client/src/components/systemconfiguration/defaults.js	Thu Aug 22 08:56:22 2019 +0200
+++ b/client/src/components/systemconfiguration/defaults.js	Thu Aug 22 09:20:38 2019 +0200
@@ -27,8 +27,8 @@
   feature_colours_waterwayprofiles_stroke: "#0000ff80",
   feature_colours_distancemarks_stroke: "#6666ff",
   feature_colours_distancemarks_fill: "#ff9999",
-  feature_colours_distancemarks_axis_stroke: "#3333FF",
-  feature_colours_distancemarks_axis_fill: "#8888FF",
+  feature_colours_distancemarks_ashore_stroke: "#3333FF",
+  feature_colours_distancemarks_ashore_fill: "#8888FF",
   feature_colours_waterway_axis_stroke: "#0000FF",
   feature_colours_waterway_area_stroke: "#006600"
 };