mirage2d 1.1.18 → 1.1.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/mirage2d.es.js
CHANGED
|
@@ -80300,24 +80300,24 @@ class baseGraphicLayer extends baseLayer {
|
|
|
80300
80300
|
element.maxnum = average2 * index2;
|
|
80301
80301
|
});
|
|
80302
80302
|
}
|
|
80303
|
+
mLevelColor.sort(function up(x2, y2) {
|
|
80304
|
+
return y2.maxnum - x2.maxnum;
|
|
80305
|
+
});
|
|
80303
80306
|
this._source.getFeatures().forEach((feature2) => {
|
|
80304
80307
|
if (feature2.get("classname") == levelOption.classname) {
|
|
80305
80308
|
let data2 = feature2.get(levelOption.attributeName);
|
|
80306
80309
|
if (data2) {
|
|
80307
|
-
if (
|
|
80310
|
+
if (parseInt(data2) == 0) {
|
|
80308
80311
|
let mStyle = MirageDefaultStyle.getStyle(feature2.getGeometry().getType(), { fillcolor: "rgba(255,255,255,0)", strokecolor: "rgba(255,255,255,0.1)", strokewidth: 1 });
|
|
80309
80312
|
feature2.setStyle(mStyle);
|
|
80310
80313
|
} else {
|
|
80311
|
-
mLevelColor.
|
|
80312
|
-
|
|
80313
|
-
|
|
80314
|
-
mLevelColor.forEach((element) => {
|
|
80315
|
-
if (parseFloat(data2) > element.maxnum) {
|
|
80316
|
-
let mStyle = MirageDefaultStyle.getStyle(feature2.getGeometry().getType(), { fillcolor: element.fillcolor, strokecolor: element.strokecolor, strokewidth: element.strokewidth });
|
|
80314
|
+
for (let x2 = 0; x2 < mLevelColor.length; x2++) {
|
|
80315
|
+
if (parseFloat(data2) > mLevelColor[x2].maxnum) {
|
|
80316
|
+
let mStyle = MirageDefaultStyle.getStyle(feature2.getGeometry().getType(), { fillcolor: mLevelColor[x2].fillcolor, strokecolor: mLevelColor[x2].strokecolor, strokewidth: mLevelColor[x2].strokewidth });
|
|
80317
80317
|
feature2.setStyle(mStyle);
|
|
80318
|
-
|
|
80318
|
+
break;
|
|
80319
80319
|
}
|
|
80320
|
-
}
|
|
80320
|
+
}
|
|
80321
80321
|
}
|
|
80322
80322
|
}
|
|
80323
80323
|
}
|