Skip to content

Commit 0c23c58

Browse files
committed
【update/API】 leaflet css 增加导出 webmapfont.css ,leaflet heatmaplayer 增加 blur 参数 review by songym
1 parent b5f1a4b commit 0c23c58

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/leaflet/css/index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/* Copyright© 2000 - 2019 SuperMap Software Co.Ltd. All rights reserved.
22
* This program are made available under the terms of the Apache License, Version 2.0
33
* which accompanies this distribution and is available at http://www.apache.org/licenses/LICENSE-2.0.html.*/
4+
import '@supermap/iclient-common/css/webmapfont/iconfont.css'
45
import '@supermap/iclient-common/css';
5-
import './ChangeTileVersion.css';
6+
import './ChangeTileVersion.css';

src/leaflet/overlay/HeatMapLayer.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ import Attributions from '../core/Attributions'
2929
* @param {number} [options.radius=50] - 热点渲染的最大半径(热点像素半径),单位为 px,当 useGeoUnit 参数 为 true 时,单位使用当前图层地理坐标单位。热点显示的时候以精确点为中心点开始往四周辐射衰减,其衰减半径和权重值成比列。
3030
* @param {number} [options.opacity=1] - 图层透明度。
3131
* @param {boolean} [options.useGeoUnit=false] - 使用地理单位,即默认热点半径默认使用像素单位。 当设置为 true 时,热点半径和图层地理坐标保持一致。
32+
* @param {boolean} [options.blur] - 模糊量,默认值为半径的二分之一。
3233
* @param {string} [options.attribution='Map Data <span>© <a href='http://support.supermap.com.cn/product/iServer.aspx' title='SuperMap iServer' target='_blank'>SuperMap iServer</a></span>'] - 版权信息。
3334
*
3435
* @extends {L.Layer}
@@ -78,6 +79,7 @@ export var HeatMapLayer = L.Layer.extend({
7879
this.useGeoUnit = this.options.useGeoUnit;
7980
this.opacity = this.options.opacity;
8081
this.radius = this.options.radius;
82+
this.blur = this.options.blur;
8183
this.movingOffset = [0, 0];
8284
},
8385

@@ -295,7 +297,7 @@ export var HeatMapLayer = L.Layer.extend({
295297
* @private
296298
*/
297299
drawCircle: function (r) {
298-
var blur = r / 2;
300+
var blur = this.blur || r / 2;
299301

300302
var circle = this.circle = document.createElement('canvas'),
301303
ctx = circle.getContext("2d");

0 commit comments

Comments
 (0)