diff --git a/src/component/helper/MapDraw.ts b/src/component/helper/MapDraw.ts index 22caaebdd6ff73f1c53c1851bd3d48ea37de1da2..22d2caaf75c64e237b661c0301ecf02faaf1684d 100644 --- a/src/component/helper/MapDraw.ts +++ b/src/component/helper/MapDraw.ts @@ -399,6 +399,13 @@ class MapDraw { }, this); + this._enableBlurEntireSVG(focusSelf, viewBuildCtx); + } + + private _enableBlurEntireSVG( + focusSelf: boolean, + viewBuildCtx: ViewBuildContext + ): void { // It's a little complicated to support blurring the entire geoSVG in series-map. // So do not suport it until some requirements come. // At present, in series-map, only regions can be blurred. @@ -417,8 +424,7 @@ class MapDraw { if (style.opacity == null && opacity != null) { style.opacity = opacity; } - // If opacity not set, but `ensureState('blur').style` set, there will - // be default opacity. + // If `ensureState('blur').style = {}`, there will be default opacity. // Enable `stateTransition` (animation). (el as Displayable).ensureState('emphasis'); @@ -638,6 +644,8 @@ function applyOptionStyleForRegion( el.ensureState('emphasis').style = emphasisStyle; el.ensureState('select').style = selectStyle; el.ensureState('blur').style = blurStyle; + // Enable blur + setDefaultStateProxy(el); } function resetLabelForRegion( diff --git a/test/geo-svg.html b/test/geo-svg.html index 45ec6e426caaa558bd97155620dcc3607ffd22cb..38a625109ae71671872678adc2eb318112c60ca1 100644 --- a/test/geo-svg.html +++ b/test/geo-svg.html @@ -39,6 +39,7 @@ under the License.
+
@@ -199,6 +200,86 @@ under the License. + + + + + + + + + +