mirror of https://gitee.com/antv-l7/antv-l7
fix: conflicts
This commit is contained in:
commit
ec5c9a99a2
|
@ -3,6 +3,13 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
- 3d 热力图抖动问题 fixes [#138](https://github.com/antvis/L7/issues/138) [#263](https://github.com/antvis/L7/issues/263) ([d56e8d6](https://github.com/antvis/L7/commit/d56e8d6205942ca12fa7ac3dfd226aecbb850ed2))
|
||||||
|
- 拾取 invalid x offset ([8282007](https://github.com/antvis/L7/commit/82820077f40998e156337b266623309eff6b2d60))
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
### Bug Fixes
|
### Bug Fixes
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
"message": "chore: publish"
|
"message": "chore: publish"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"npmClient": "yarn",
|
"npmClient": "yarn",
|
||||||
"useWorkspaces": true,
|
"useWorkspaces": true,
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
|
|
|
@ -3,6 +3,14 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @antv/l7-component
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
**Note:** Version bump only for package @antv/l7-component
|
**Note:** Version bump only for package @antv/l7-component
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7-component",
|
"name": "@antv/l7-component",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"module": "es/index.js",
|
"module": "es/index.js",
|
||||||
|
@ -24,8 +24,8 @@
|
||||||
"author": "lzxue",
|
"author": "lzxue",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@antv/l7-core": "^2.1.7",
|
"@antv/l7-core": "^2.1.8",
|
||||||
"@antv/l7-utils": "^2.1.7",
|
"@antv/l7-utils": "^2.1.8",
|
||||||
"@babel/runtime": "^7.7.7",
|
"@babel/runtime": "^7.7.7",
|
||||||
"eventemitter3": "^4.0.0",
|
"eventemitter3": "^4.0.0",
|
||||||
"inversify": "^5.0.1",
|
"inversify": "^5.0.1",
|
||||||
|
|
|
@ -3,6 +3,17 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 拾取 invalid x offset ([8282007](https://github.com/antvis/L7/commit/82820077f40998e156337b266623309eff6b2d60))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
**Note:** Version bump only for package @antv/l7-core
|
**Note:** Version bump only for package @antv/l7-core
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7-core",
|
"name": "@antv/l7-core",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"module": "es/index.js",
|
"module": "es/index.js",
|
||||||
|
@ -23,7 +23,7 @@
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@antv/async-hook": "^2.1.0",
|
"@antv/async-hook": "^2.1.0",
|
||||||
"@antv/l7-utils": "^2.1.7",
|
"@antv/l7-utils": "^2.1.8",
|
||||||
"@babel/runtime": "^7.7.7",
|
"@babel/runtime": "^7.7.7",
|
||||||
"@mapbox/tiny-sdf": "^1.1.1",
|
"@mapbox/tiny-sdf": "^1.1.1",
|
||||||
"ajv": "^6.10.2",
|
"ajv": "^6.10.2",
|
||||||
|
|
|
@ -4,8 +4,6 @@ import { merge } from 'lodash';
|
||||||
import { ILayerConfig } from '../layer/ILayerService';
|
import { ILayerConfig } from '../layer/ILayerService';
|
||||||
import { IRenderConfig } from '../renderer/IRendererService';
|
import { IRenderConfig } from '../renderer/IRendererService';
|
||||||
import { IGlobalConfigService, ISceneConfig } from './IConfigService';
|
import { IGlobalConfigService, ISceneConfig } from './IConfigService';
|
||||||
import mapConfigSchema from './mapConfigSchema';
|
|
||||||
import sceneConfigSchema from './sceneConfigSchema';
|
|
||||||
import WarnInfo, { IWarnInfo } from './warnInfo';
|
import WarnInfo, { IWarnInfo } from './warnInfo';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -17,6 +15,9 @@ const defaultSceneConfig: Partial<ISceneConfig & IRenderConfig> = {
|
||||||
logoVisible: true,
|
logoVisible: true,
|
||||||
antialias: true,
|
antialias: true,
|
||||||
preserveDrawingBuffer: false,
|
preserveDrawingBuffer: false,
|
||||||
|
fitBoundsOptions: {
|
||||||
|
animate: false,
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -8,6 +8,8 @@ export interface ISceneConfig extends IRenderConfig {
|
||||||
map: IMapWrapper;
|
map: IMapWrapper;
|
||||||
logoPosition?: PositionName;
|
logoPosition?: PositionName;
|
||||||
logoVisible?: boolean;
|
logoVisible?: boolean;
|
||||||
|
animate?: boolean;
|
||||||
|
fitBoundsOptions?: unknown;
|
||||||
}
|
}
|
||||||
|
|
||||||
// interface IValidateResult {
|
// interface IValidateResult {
|
||||||
|
|
|
@ -155,7 +155,7 @@ export interface ILayer {
|
||||||
destroy(): void;
|
destroy(): void;
|
||||||
source(data: any, option?: ISourceCFG): ILayer;
|
source(data: any, option?: ISourceCFG): ILayer;
|
||||||
setData(data: any, option?: ISourceCFG): ILayer;
|
setData(data: any, option?: ISourceCFG): ILayer;
|
||||||
fitBounds(): ILayer;
|
fitBounds(fitBoundsOptions?: unknown): ILayer;
|
||||||
/**
|
/**
|
||||||
* 向当前图层注册插件
|
* 向当前图层注册插件
|
||||||
* @param plugin 插件实例
|
* @param plugin 插件实例
|
||||||
|
@ -224,6 +224,7 @@ export interface ILayerConfig {
|
||||||
pickingBuffer: number;
|
pickingBuffer: number;
|
||||||
enablePropagation: boolean;
|
enablePropagation: boolean;
|
||||||
autoFit: boolean;
|
autoFit: boolean;
|
||||||
|
fitBoundsOptions?: unknown;
|
||||||
name: string; //
|
name: string; //
|
||||||
blend: keyof typeof BlendType;
|
blend: keyof typeof BlendType;
|
||||||
pickedFeatureID: number;
|
pickedFeatureID: number;
|
||||||
|
|
|
@ -11,6 +11,15 @@ export interface IPoint {
|
||||||
y: number;
|
y: number;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export interface IStatusOptions {
|
||||||
|
showIndoorMap: boolean;
|
||||||
|
resizeEnable: boolean;
|
||||||
|
dragEnable: boolean;
|
||||||
|
keyboardEnable: boolean;
|
||||||
|
doubleClickZoom: boolean;
|
||||||
|
zoomEnable: boolean;
|
||||||
|
rotateEnable: boolean;
|
||||||
|
}
|
||||||
export type MapStyle = string | { [key: string]: any };
|
export type MapStyle = string | { [key: string]: any };
|
||||||
export interface IMapWrapper {
|
export interface IMapWrapper {
|
||||||
setContainer(container: Container, id: string | HTMLDivElement): void;
|
setContainer(container: Container, id: string | HTMLDivElement): void;
|
||||||
|
@ -50,12 +59,13 @@ export interface IMapService<RawMap = {}> {
|
||||||
zoomOut(option?: any, eventData?: any): void;
|
zoomOut(option?: any, eventData?: any): void;
|
||||||
panTo(p: Point): void;
|
panTo(p: Point): void;
|
||||||
panBy(pixel: Point): void;
|
panBy(pixel: Point): void;
|
||||||
fitBounds(bound: Bounds): void;
|
fitBounds(bound: Bounds, fitBoundsOptions?: unknown): void;
|
||||||
setZoomAndCenter(zoom: number, center: Point): void;
|
setZoomAndCenter(zoom: number, center: Point): void;
|
||||||
setCenter(center: [number, number]): void;
|
setCenter(center: [number, number]): void;
|
||||||
setPitch(pitch: number): void;
|
setPitch(pitch: number): void;
|
||||||
setZoom(zoom: number): void;
|
setZoom(zoom: number): void;
|
||||||
setMapStyle(style: any): void;
|
setMapStyle(style: any): void;
|
||||||
|
setStatus(option: Partial<IStatusOptions>): void;
|
||||||
|
|
||||||
// coordinates methods
|
// coordinates methods
|
||||||
pixelToLngLat(pixel: Point): ILngLat;
|
pixelToLngLat(pixel: Point): ILngLat;
|
||||||
|
|
|
@ -3,6 +3,14 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @antv/l7-draw
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
**Note:** Version bump only for package @antv/l7-draw
|
**Note:** Version bump only for package @antv/l7-draw
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7-draw",
|
"name": "@antv/l7-draw",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "L7 Draw moudules",
|
"description": "L7 Draw moudules",
|
||||||
"keywords": [],
|
"keywords": [],
|
||||||
"author": "thinkinggis <lzx199065@gmail.com>",
|
"author": "thinkinggis <lzx199065@gmail.com>",
|
||||||
|
@ -33,8 +33,8 @@
|
||||||
"test": "jest"
|
"test": "jest"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@antv/l7": "^2.1.7",
|
|
||||||
"@turf/midpoint": "^5.1.5",
|
"@turf/midpoint": "^5.1.5",
|
||||||
|
"@antv/l7": "^2.1.8",
|
||||||
"@babel/runtime": "^7.7.7",
|
"@babel/runtime": "^7.7.7",
|
||||||
"@turf/circle": "^6.0.1",
|
"@turf/circle": "^6.0.1",
|
||||||
"@turf/distance": "^6.0.1",
|
"@turf/distance": "^6.0.1",
|
||||||
|
|
|
@ -3,6 +3,14 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @antv/l7
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
**Note:** Version bump only for package @antv/l7
|
**Note:** Version bump only for package @antv/l7
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7",
|
"name": "@antv/l7",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "A Large-scale WebGL-powered Geospatial Data Visualization",
|
"description": "A Large-scale WebGL-powered Geospatial Data Visualization",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"module": "es/index.js",
|
"module": "es/index.js",
|
||||||
|
@ -24,11 +24,11 @@
|
||||||
"author": "antv",
|
"author": "antv",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@antv/l7-component": "^2.1.7",
|
"@antv/l7-component": "^2.1.8",
|
||||||
"@antv/l7-core": "^2.1.7",
|
"@antv/l7-core": "^2.1.8",
|
||||||
"@antv/l7-layers": "^2.1.7",
|
"@antv/l7-layers": "^2.1.8",
|
||||||
"@antv/l7-maps": "^2.1.7",
|
"@antv/l7-maps": "^2.1.8",
|
||||||
"@antv/l7-scene": "^2.1.7",
|
"@antv/l7-scene": "^2.1.8",
|
||||||
"@babel/runtime": "^7.7.7"
|
"@babel/runtime": "^7.7.7"
|
||||||
},
|
},
|
||||||
"gitHead": "a5d354b66873f700730248d015c5e539c54b34b7",
|
"gitHead": "a5d354b66873f700730248d015c5e539c54b34b7",
|
||||||
|
|
|
@ -3,4 +3,4 @@ export * from '@antv/l7-scene';
|
||||||
export * from '@antv/l7-maps';
|
export * from '@antv/l7-maps';
|
||||||
export * from '@antv/l7-layers';
|
export * from '@antv/l7-layers';
|
||||||
export * from '@antv/l7-component';
|
export * from '@antv/l7-component';
|
||||||
export const version = '2.1.6';
|
export const version = '2.1.8';
|
||||||
|
|
|
@ -3,6 +3,17 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* 3d 热力图抖动问题 fixes [#138](https://github.com/antvis/L7/issues/138) [#263](https://github.com/antvis/L7/issues/263) ([d56e8d6](https://github.com/antvis/L7/commit/d56e8d6205942ca12fa7ac3dfd226aecbb850ed2))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7-layers",
|
"name": "@antv/l7-layers",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "L7's collection of built-in layers",
|
"description": "L7's collection of built-in layers",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"module": "es/index.js",
|
"module": "es/index.js",
|
||||||
|
@ -23,9 +23,9 @@
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@antv/async-hook": "^2.1.0",
|
"@antv/async-hook": "^2.1.0",
|
||||||
"@antv/l7-core": "^2.1.7",
|
"@antv/l7-core": "^2.1.8",
|
||||||
"@antv/l7-source": "^2.1.7",
|
"@antv/l7-source": "^2.1.8",
|
||||||
"@antv/l7-utils": "^2.1.7",
|
"@antv/l7-utils": "^2.1.8",
|
||||||
"@babel/runtime": "^7.7.7",
|
"@babel/runtime": "^7.7.7",
|
||||||
"@mapbox/martini": "^0.1.0",
|
"@mapbox/martini": "^0.1.0",
|
||||||
"@turf/meta": "^6.0.2",
|
"@turf/meta": "^6.0.2",
|
||||||
|
|
|
@ -654,7 +654,7 @@ export default class BaseLayer<ChildLayerStyleOptions = {}> extends EventEmitter
|
||||||
/**
|
/**
|
||||||
* zoom to layer Bounds
|
* zoom to layer Bounds
|
||||||
*/
|
*/
|
||||||
public fitBounds(): ILayer {
|
public fitBounds(fitBoundsOptions?: unknown): ILayer {
|
||||||
if (!this.inited) {
|
if (!this.inited) {
|
||||||
this.updateLayerConfig({
|
this.updateLayerConfig({
|
||||||
autoFit: true,
|
autoFit: true,
|
||||||
|
@ -663,10 +663,13 @@ export default class BaseLayer<ChildLayerStyleOptions = {}> extends EventEmitter
|
||||||
}
|
}
|
||||||
const source = this.getSource();
|
const source = this.getSource();
|
||||||
const extent = source.extent;
|
const extent = source.extent;
|
||||||
this.mapService.fitBounds([
|
this.mapService.fitBounds(
|
||||||
[extent[0], extent[1]],
|
[
|
||||||
[extent[2], extent[3]],
|
[extent[0], extent[1]],
|
||||||
]);
|
[extent[2], extent[3]],
|
||||||
|
],
|
||||||
|
fitBoundsOptions,
|
||||||
|
);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -879,9 +882,9 @@ export default class BaseLayer<ChildLayerStyleOptions = {}> extends EventEmitter
|
||||||
|
|
||||||
private sourceEvent = () => {
|
private sourceEvent = () => {
|
||||||
this.dataState.dataSourceNeedUpdate = true;
|
this.dataState.dataSourceNeedUpdate = true;
|
||||||
const { autoFit } = this.getLayerConfig();
|
const { autoFit, fitBoundsOptions } = this.getLayerConfig();
|
||||||
if (autoFit) {
|
if (autoFit) {
|
||||||
this.fitBounds();
|
this.fitBounds(fitBoundsOptions);
|
||||||
}
|
}
|
||||||
|
|
||||||
this.emit('dataUpdate');
|
this.emit('dataUpdate');
|
||||||
|
|
|
@ -11,10 +11,10 @@ export default class LayerStylePlugin implements ILayerPlugin {
|
||||||
layer.hooks.afterInit.tap('LayerStylePlugin', () => {
|
layer.hooks.afterInit.tap('LayerStylePlugin', () => {
|
||||||
// 更新图层默认状态
|
// 更新图层默认状态
|
||||||
layer.updateLayerConfig({});
|
layer.updateLayerConfig({});
|
||||||
const { autoFit } = layer.getLayerConfig();
|
const { autoFit, fitBoundsOptions } = layer.getLayerConfig();
|
||||||
if (autoFit) {
|
if (autoFit) {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
layer.fitBounds();
|
layer.fitBounds(fitBoundsOptions);
|
||||||
}, 100);
|
}, 100);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
@ -3,6 +3,14 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @antv/l7-maps
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
**Note:** Version bump only for package @antv/l7-maps
|
**Note:** Version bump only for package @antv/l7-maps
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7-maps",
|
"name": "@antv/l7-maps",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"module": "es/index.js",
|
"module": "es/index.js",
|
||||||
|
@ -25,8 +25,8 @@
|
||||||
"author": "xiaoiver",
|
"author": "xiaoiver",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@antv/l7-core": "^2.1.7",
|
"@antv/l7-core": "^2.1.8",
|
||||||
"@antv/l7-utils": "^2.1.7",
|
"@antv/l7-utils": "^2.1.8",
|
||||||
"@babel/runtime": "^7.7.7",
|
"@babel/runtime": "^7.7.7",
|
||||||
"@types/amap-js-api": "^1.4.6",
|
"@types/amap-js-api": "^1.4.6",
|
||||||
"gl-matrix": "^3.1.0",
|
"gl-matrix": "^3.1.0",
|
||||||
|
|
|
@ -11,6 +11,7 @@ import {
|
||||||
IMapConfig,
|
IMapConfig,
|
||||||
IMapService,
|
IMapService,
|
||||||
IPoint,
|
IPoint,
|
||||||
|
IStatusOptions,
|
||||||
IViewport,
|
IViewport,
|
||||||
MapServiceEvent,
|
MapServiceEvent,
|
||||||
MapStyle,
|
MapStyle,
|
||||||
|
@ -201,6 +202,10 @@ export default class AMapService
|
||||||
public setMapStyle(style: string): void {
|
public setMapStyle(style: string): void {
|
||||||
this.map.setMapStyle(this.getMapStyle(style));
|
this.map.setMapStyle(this.getMapStyle(style));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public setStatus(option: Partial<IStatusOptions>) {
|
||||||
|
this.map.setStatus(option);
|
||||||
|
}
|
||||||
public pixelToLngLat(pixel: [number, number]): ILngLat {
|
public pixelToLngLat(pixel: [number, number]): ILngLat {
|
||||||
const lngLat = this.map.pixelToLngLat(new AMap.Pixel(pixel[0], pixel[1]));
|
const lngLat = this.map.pixelToLngLat(new AMap.Pixel(pixel[0], pixel[1]));
|
||||||
return { lng: lngLat.getLng(), lat: lngLat.getLat() };
|
return { lng: lngLat.getLng(), lat: lngLat.getLat() };
|
||||||
|
|
|
@ -11,6 +11,7 @@ import {
|
||||||
IMapConfig,
|
IMapConfig,
|
||||||
IMapService,
|
IMapService,
|
||||||
IPoint,
|
IPoint,
|
||||||
|
IStatusOptions,
|
||||||
IViewport,
|
IViewport,
|
||||||
MapServiceEvent,
|
MapServiceEvent,
|
||||||
MapStyle,
|
MapStyle,
|
||||||
|
@ -155,8 +156,8 @@ export default class MapboxService
|
||||||
this.panTo(pixel);
|
this.panTo(pixel);
|
||||||
}
|
}
|
||||||
|
|
||||||
public fitBounds(bound: Bounds): void {
|
public fitBounds(bound: Bounds, fitBoundsOptions?: unknown): void {
|
||||||
this.map.fitBounds(bound);
|
this.map.fitBounds(bound, fitBoundsOptions as mapboxgl.FitBoundsOptions);
|
||||||
}
|
}
|
||||||
|
|
||||||
public setMaxZoom(max: number): void {
|
public setMaxZoom(max: number): void {
|
||||||
|
@ -166,6 +167,38 @@ export default class MapboxService
|
||||||
public setMinZoom(min: number): void {
|
public setMinZoom(min: number): void {
|
||||||
this.map.setMinZoom(min);
|
this.map.setMinZoom(min);
|
||||||
}
|
}
|
||||||
|
public setStatus(option: Partial<IStatusOptions>) {
|
||||||
|
if (option.doubleClickZoom === true) {
|
||||||
|
this.map.doubleClickZoom.enable();
|
||||||
|
}
|
||||||
|
if (option.doubleClickZoom === false) {
|
||||||
|
this.map.doubleClickZoom.disable();
|
||||||
|
}
|
||||||
|
if (option.dragEnable === false) {
|
||||||
|
this.map.dragPan.disable();
|
||||||
|
}
|
||||||
|
if (option.dragEnable === true) {
|
||||||
|
this.map.dragPan.enable();
|
||||||
|
}
|
||||||
|
if (option.rotateEnable === false) {
|
||||||
|
this.map.dragRotate.disable();
|
||||||
|
}
|
||||||
|
if (option.dragEnable === true) {
|
||||||
|
this.map.dragRotate.enable();
|
||||||
|
}
|
||||||
|
if (option.keyboardEnable === false) {
|
||||||
|
this.map.keyboard.disable();
|
||||||
|
}
|
||||||
|
if (option.keyboardEnable === true) {
|
||||||
|
this.map.keyboard.enable();
|
||||||
|
}
|
||||||
|
if (option.zoomEnable === false) {
|
||||||
|
this.map.scrollZoom.disable();
|
||||||
|
}
|
||||||
|
if (option.zoomEnable === true) {
|
||||||
|
this.map.scrollZoom.enable();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public setZoomAndCenter(zoom: number, center: [number, number]): void {
|
public setZoomAndCenter(zoom: number, center: [number, number]): void {
|
||||||
this.map.flyTo({
|
this.map.flyTo({
|
||||||
|
|
|
@ -3,6 +3,14 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @antv/l7-react
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
**Note:** Version bump only for package @antv/l7-react
|
**Note:** Version bump only for package @antv/l7-react
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7-react",
|
"name": "@antv/l7-react",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"module": "es/index.js",
|
"module": "es/index.js",
|
||||||
|
@ -24,8 +24,8 @@
|
||||||
"author": "lzxue",
|
"author": "lzxue",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@antv/l7": "^2.1.7",
|
"@antv/l7": "^2.1.8",
|
||||||
"@antv/l7-maps": "^2.1.7",
|
"@antv/l7-maps": "^2.1.8",
|
||||||
"@babel/runtime": "^7.7.7",
|
"@babel/runtime": "^7.7.7",
|
||||||
"load-styles": "^2.0.0"
|
"load-styles": "^2.0.0"
|
||||||
},
|
},
|
||||||
|
|
|
@ -113,12 +113,6 @@ export default function BaseLayer(type: string, props: ILayerProps) {
|
||||||
}
|
}
|
||||||
}, [options?.blend]);
|
}, [options?.blend]);
|
||||||
|
|
||||||
// useEffect(() => {
|
|
||||||
// if (layer && layer.inited && options && options.autoFit === true) {
|
|
||||||
// layer.fitBounds();
|
|
||||||
// }
|
|
||||||
// }, [options?.autoFit]);
|
|
||||||
|
|
||||||
return layer !== null && layer !== undefined ? (
|
return layer !== null && layer !== undefined ? (
|
||||||
<LayerContext.Provider value={layer}>
|
<LayerContext.Provider value={layer}>
|
||||||
<Source layer={layer} source={source} />
|
<Source layer={layer} source={source} />
|
||||||
|
|
|
@ -18,7 +18,7 @@ export default React.memo(function Chart(props: ISourceProps) {
|
||||||
layer.setData(data, sourceOption);
|
layer.setData(data, sourceOption);
|
||||||
}
|
}
|
||||||
if (sourceOption.autoFit) {
|
if (sourceOption.autoFit) {
|
||||||
layer.fitBounds();
|
layer.fitBounds(sourceOption && sourceOption.fitBoundsOptions);
|
||||||
}
|
}
|
||||||
}, [data, JSON.stringify(sourceOption)]);
|
}, [data, JSON.stringify(sourceOption)]);
|
||||||
return null;
|
return null;
|
||||||
|
|
|
@ -60,6 +60,8 @@ export interface ISourceOptions extends ISourceCFG {
|
||||||
data: any;
|
data: any;
|
||||||
// 每次更新数据之后是否自适应缩放
|
// 每次更新数据之后是否自适应缩放
|
||||||
autoFit?: boolean;
|
autoFit?: boolean;
|
||||||
|
// Mapbox 自适应的参数
|
||||||
|
fitBoundsOptions?: any;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface IActiveOptions {
|
export interface IActiveOptions {
|
||||||
|
|
|
@ -3,6 +3,14 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @antv/l7-renderer
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
**Note:** Version bump only for package @antv/l7-renderer
|
**Note:** Version bump only for package @antv/l7-renderer
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7-renderer",
|
"name": "@antv/l7-renderer",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"module": "es/index.js",
|
"module": "es/index.js",
|
||||||
|
@ -25,7 +25,7 @@
|
||||||
"gl": "^4.4.0"
|
"gl": "^4.4.0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@antv/l7-core": "^2.1.7",
|
"@antv/l7-core": "^2.1.8",
|
||||||
"@babel/runtime": "^7.7.7",
|
"@babel/runtime": "^7.7.7",
|
||||||
"inversify": "^5.0.1",
|
"inversify": "^5.0.1",
|
||||||
"lodash": "^4.17.15",
|
"lodash": "^4.17.15",
|
||||||
|
|
|
@ -3,6 +3,14 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @antv/l7-scene
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
**Note:** Version bump only for package @antv/l7-scene
|
**Note:** Version bump only for package @antv/l7-scene
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7-scene",
|
"name": "@antv/l7-scene",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"module": "es/index.js",
|
"module": "es/index.js",
|
||||||
|
@ -22,11 +22,11 @@
|
||||||
"author": "xiaoiver",
|
"author": "xiaoiver",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@antv/l7-component": "^2.1.7",
|
"@antv/l7-component": "^2.1.8",
|
||||||
"@antv/l7-core": "^2.1.7",
|
"@antv/l7-core": "^2.1.8",
|
||||||
"@antv/l7-maps": "^2.1.7",
|
"@antv/l7-maps": "^2.1.8",
|
||||||
"@antv/l7-renderer": "^2.1.7",
|
"@antv/l7-renderer": "^2.1.8",
|
||||||
"@antv/l7-utils": "^2.1.7",
|
"@antv/l7-utils": "^2.1.8",
|
||||||
"@babel/runtime": "^7.7.7",
|
"@babel/runtime": "^7.7.7",
|
||||||
"inversify": "^5.0.1",
|
"inversify": "^5.0.1",
|
||||||
"mapbox-gl": "^1.2.1",
|
"mapbox-gl": "^1.2.1",
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { Bounds, ILngLat, IPoint, Point } from '@antv/l7-core';
|
import { Bounds, ILngLat, IPoint, IStatusOptions, Point } from '@antv/l7-core';
|
||||||
|
|
||||||
export default interface IMapController {
|
export default interface IMapController {
|
||||||
/**
|
/**
|
||||||
|
@ -49,19 +49,30 @@ export default interface IMapController {
|
||||||
/**
|
/**
|
||||||
* 调整地图适合指定区域
|
* 调整地图适合指定区域
|
||||||
*/
|
*/
|
||||||
fitBounds(bound: Bounds): void;
|
fitBounds(bound: Bounds, fitBoundsOptions?: unknown): void;
|
||||||
|
|
||||||
|
getContainer(): HTMLElement | null;
|
||||||
|
getSize(): [number, number];
|
||||||
|
// get map status method
|
||||||
|
getMinZoom(): number;
|
||||||
|
getMaxZoom(): number;
|
||||||
|
// get map params
|
||||||
|
getType(): string;
|
||||||
|
getMapContainer(): HTMLElement | null;
|
||||||
|
|
||||||
|
// control with raw map
|
||||||
setRotation(rotation: number): void;
|
setRotation(rotation: number): void;
|
||||||
|
|
||||||
setZoomAndCenter(zoom: number, center: Point): void;
|
setZoomAndCenter(zoom: number, center: Point): void;
|
||||||
|
setCenter(center: [number, number]): void;
|
||||||
|
setPitch(pitch: number): void;
|
||||||
|
setZoom(zoom: number): void;
|
||||||
|
setMapStyle(style: any): void;
|
||||||
|
setStatus(option: Partial<IStatusOptions>): void;
|
||||||
|
|
||||||
setMapStyle(style: string): void;
|
// coordinates methods
|
||||||
|
|
||||||
pixelToLngLat(pixel: Point): ILngLat;
|
pixelToLngLat(pixel: Point): ILngLat;
|
||||||
|
|
||||||
lngLatToPixel(lnglat: Point): IPoint;
|
lngLatToPixel(lnglat: Point): IPoint;
|
||||||
|
|
||||||
containerToLngLat(pixel: Point): ILngLat;
|
containerToLngLat(pixel: Point): ILngLat;
|
||||||
|
|
||||||
lngLatToContainer(lnglat: Point): IPoint;
|
lngLatToContainer(lnglat: Point): IPoint;
|
||||||
|
exportMap(type: 'jpg' | 'png'): string;
|
||||||
}
|
}
|
||||||
|
|
|
@ -24,6 +24,7 @@ import {
|
||||||
IRendererService,
|
IRendererService,
|
||||||
ISceneConfig,
|
ISceneConfig,
|
||||||
ISceneService,
|
ISceneService,
|
||||||
|
IStatusOptions,
|
||||||
Point,
|
Point,
|
||||||
SceneEventList,
|
SceneEventList,
|
||||||
TYPES,
|
TYPES,
|
||||||
|
@ -58,11 +59,10 @@ class Scene
|
||||||
private popupService: IPopupService;
|
private popupService: IPopupService;
|
||||||
private fontService: IFontService;
|
private fontService: IFontService;
|
||||||
private interactionService: IInteractionService;
|
private interactionService: IInteractionService;
|
||||||
|
|
||||||
private container: Container;
|
private container: Container;
|
||||||
|
|
||||||
public constructor(config: ISceneConfig) {
|
public constructor(config: ISceneConfig) {
|
||||||
const { id, map, logoPosition, logoVisible = true } = config;
|
const { id, map } = config;
|
||||||
// 创建场景容器
|
// 创建场景容器
|
||||||
const sceneContainer = createSceneContainer();
|
const sceneContainer = createSceneContainer();
|
||||||
this.container = sceneContainer;
|
this.container = sceneContainer;
|
||||||
|
@ -103,6 +103,21 @@ class Scene
|
||||||
|
|
||||||
this.initControl();
|
this.initControl();
|
||||||
}
|
}
|
||||||
|
public getSize(): [number, number] {
|
||||||
|
return this.mapService.getSize();
|
||||||
|
}
|
||||||
|
public getMinZoom(): number {
|
||||||
|
return this.mapService.getMinZoom();
|
||||||
|
}
|
||||||
|
public getMaxZoom(): number {
|
||||||
|
return this.mapService.getMaxZoom();
|
||||||
|
}
|
||||||
|
public getType(): string {
|
||||||
|
return this.mapService.getType();
|
||||||
|
}
|
||||||
|
public getMapContainer(): HTMLElement | null {
|
||||||
|
return this.mapService.getMapContainer();
|
||||||
|
}
|
||||||
|
|
||||||
public getMapService(): IMapService<unknown> {
|
public getMapService(): IMapService<unknown> {
|
||||||
return this.mapService;
|
return this.mapService;
|
||||||
|
@ -270,8 +285,16 @@ class Scene
|
||||||
public setZoom(zoom: number): void {
|
public setZoom(zoom: number): void {
|
||||||
this.mapService.setZoom(zoom);
|
this.mapService.setZoom(zoom);
|
||||||
}
|
}
|
||||||
public fitBounds(bound: Bounds): void {
|
public fitBounds(bound: Bounds, options?: unknown): void {
|
||||||
this.mapService.fitBounds(bound);
|
const { fitBoundsOptions, animate } = this.sceneService.getSceneConfig();
|
||||||
|
this.mapService.fitBounds(
|
||||||
|
bound,
|
||||||
|
// 选项优先级:用户传入,覆盖animate直接配置,覆盖Scene配置项传入
|
||||||
|
options || {
|
||||||
|
...(fitBoundsOptions as object),
|
||||||
|
animate,
|
||||||
|
},
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
public setZoomAndCenter(zoom: number, center: Point): void {
|
public setZoomAndCenter(zoom: number, center: Point): void {
|
||||||
|
@ -282,6 +305,10 @@ class Scene
|
||||||
this.mapService.setMapStyle(style);
|
this.mapService.setMapStyle(style);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public setStatus(options: IStatusOptions) {
|
||||||
|
this.mapService.setStatus(options);
|
||||||
|
}
|
||||||
|
|
||||||
// conversion Method
|
// conversion Method
|
||||||
public pixelToLngLat(pixel: Point): ILngLat {
|
public pixelToLngLat(pixel: Point): ILngLat {
|
||||||
return this.mapService.pixelToLngLat(pixel);
|
return this.mapService.pixelToLngLat(pixel);
|
||||||
|
|
|
@ -3,6 +3,14 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @antv/l7-source
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
**Note:** Version bump only for package @antv/l7-source
|
**Note:** Version bump only for package @antv/l7-source
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7-source",
|
"name": "@antv/l7-source",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"module": "es/index.js",
|
"module": "es/index.js",
|
||||||
|
@ -25,8 +25,8 @@
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@antv/async-hook": "^2.1.0",
|
"@antv/async-hook": "^2.1.0",
|
||||||
"@antv/l7-core": "^2.1.7",
|
"@antv/l7-core": "^2.1.8",
|
||||||
"@antv/l7-utils": "^2.1.7",
|
"@antv/l7-utils": "^2.1.8",
|
||||||
"@babel/runtime": "^7.7.7",
|
"@babel/runtime": "^7.7.7",
|
||||||
"@mapbox/geojson-rewind": "^0.4.0",
|
"@mapbox/geojson-rewind": "^0.4.0",
|
||||||
"@turf/helpers": "^6.1.4",
|
"@turf/helpers": "^6.1.4",
|
||||||
|
|
|
@ -3,6 +3,14 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## [2.1.8](https://github.com/antvis/L7/compare/v2.1.7...v2.1.8) (2020-03-26)
|
||||||
|
|
||||||
|
**Note:** Version bump only for package @antv/l7-utils
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
## [2.1.7](https://github.com/antvis/L7/compare/v2.1.6...v2.1.7) (2020-03-26)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@antv/l7-utils",
|
"name": "@antv/l7-utils",
|
||||||
"version": "2.1.7",
|
"version": "2.1.8",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"module": "es/index.js",
|
"module": "es/index.js",
|
||||||
|
|
|
@ -85,7 +85,7 @@ export default React.memo(function Map() {
|
||||||
center: [110.19382669582967, 50.258134],
|
center: [110.19382669582967, 50.258134],
|
||||||
pitch: 0,
|
pitch: 0,
|
||||||
style: 'blank',
|
style: 'blank',
|
||||||
zoom: 1,
|
zoom: 10,
|
||||||
}}
|
}}
|
||||||
style={{
|
style={{
|
||||||
position: 'absolute',
|
position: 'absolute',
|
||||||
|
@ -100,6 +100,10 @@ export default React.memo(function Map() {
|
||||||
key={'1'}
|
key={'1'}
|
||||||
options={{
|
options={{
|
||||||
autoFit: true,
|
autoFit: true,
|
||||||
|
fitBoundsOptions: {
|
||||||
|
duration: 0,
|
||||||
|
animate: false,
|
||||||
|
},
|
||||||
}}
|
}}
|
||||||
source={{
|
source={{
|
||||||
data,
|
data,
|
||||||
|
|
Loading…
Reference in New Issue