Przeglądaj źródła

'图标相关功能修改'

zhangyu 4 lat temu
rodzic
commit
6059272236
2 zmienionych plików z 10 dodań i 2 usunięć
  1. 2 2
      package.json
  2. 8 0
      src/lib/items/SImageLegendItem.ts

+ 2 - 2
package.json

@@ -10,10 +10,10 @@
     "dependencies": {
         "@mapbox/geojson-merge": "^1.1.1",
         "@saga-web/base": "2.1.22",
-        "@saga-web/big": "1.0.71",
+        "@saga-web/big": "1.0.72",
         "@saga-web/draw": "2.1.100",
         "@saga-web/feng-map": "1.0.20",
-        "@saga-web/graph": "2.1.104",
+        "@saga-web/graph": "2.1.105",
         "ant-design-vue": "^1.4.10",
         "axios": "^0.19.2",
         "core-js": "^3.4.4",

+ 8 - 0
src/lib/items/SImageLegendItem.ts

@@ -75,6 +75,12 @@ export class SImageLegendItem extends SIconTextItem {
         if (data.Properties && data.Properties.color) {
             this.color = new SColor(data.Properties.color);
         }
+        if (data.Properties && data.Properties.IsActive) {
+            this.isActive = data.Properties.IsActive;
+        }
+        if (data.Properties && data.Properties.FrameColor) {
+            this.activeColor = new SColor(data.Properties.FrameColor);
+        }
     }
 
     toData(): Legend {
@@ -88,6 +94,8 @@ export class SImageLegendItem extends SIconTextItem {
         this.data.Properties.sHeight = this.sHeight;
         this.data.Properties.font = this.font.size;
         this.data.Properties.color = this.color.value;
+        this.data.Properties.FrameColor = this.activeColor.value;
+        this.data.Properties.IsActive = this.isActive;
         this.data.AnchorList = this.anchorList.map(t => {
             return {
                 ID: t.id,