zh-mapbox 0.1.39 → 0.1.41

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/README.md CHANGED
@@ -222,11 +222,11 @@ layerConfig:{
222
222
 
223
223
  ##### **TileByGeoJson**
224
224
 
225
- | 方法名 | 参数 | 描述 |
226
- | --------------------- | ------------------------------------ | -------- |
227
- | **draw**(json,url,id) | json:边界json<br />url:地址<br />id | 绘制 |
228
- | **destroy**() | | 销毁 |
229
- | **visible**(show) | show:boolean | 显示隐藏 |
225
+ | 方法名 | 参数 | 描述 |
226
+ | ------------------------------ | ------------------------------------------------ | -------- |
227
+ | **draw**(json,url,id,beforeId) | json:边界json<br />url:地址<br />id<br>beforeId | 绘制 |
228
+ | **destroy**() | | 销毁 |
229
+ | **visible**(show) | show:boolean | 显示隐藏 |
230
230
 
231
231
  ##### **MapMenu**
232
232
 
@@ -295,6 +295,7 @@ options:
295
295
  | **draw**( json, sourceName,<br>options) | json:遮罩json sourceName:源 options:{sourceLayer?} | 绘制 |
296
296
  | **visible**(show) | show:boolean | 显示隐藏 |
297
297
  | **visibleOrigin**(show) | | 原始图层显示隐藏 |
298
+ | **update**(json) | | 更新 |
298
299
  | **destroy**() | | 销毁 |
299
300
 
300
301
  ##### MapImageByGeoJson
@@ -310,6 +311,7 @@ const layer = map.MapImageByGeoJson()
310
311
  // url 优先取callback值 没有则取properties.url
311
312
  layer.draw(polygonJson, 'url', (e) => {
312
313
  return {
314
+ beforeId:null,
313
315
  url: e.properties.url,
314
316
  distance: 0,//平移距离
315
317
  direction: 0,//平移方向 正北
package/dist/index.d.ts CHANGED
@@ -685,7 +685,7 @@ declare module 'mapbox-gl' {
685
685
  /**
686
686
  * 创建GeoJSON瓦片
687
687
  * 返回 TileByGeoJson 实例,提供以下方法:
688
- * - draw(json,url,id): 设置数据
688
+ * - draw(json,url,id,beforeId): 设置数据
689
689
  * - visible(visible): 设置可见性
690
690
  * - destroy(): 销毁瓦片
691
691
  * @param options 配置选项