From 3d71d65fa170a14b2d69217a397691d049804a9f Mon Sep 17 00:00:00 2001 From: 2912401452 <2912401452@qq.com> Date: Thu, 7 Apr 2022 18:42:45 +0800 Subject: [PATCH] style: lint style --- examples/amapPlugin/bus/demo/satellite.js | 6 +++--- examples/amapPlugin/bus/demo/xyzTile.js | 14 +++++++------- packages/layers/src/utils/updateShape.ts | 2 +- stories/Map/components/mapCenter.tsx | 4 ++-- 4 files changed, 13 insertions(+), 13 deletions(-) diff --git a/examples/amapPlugin/bus/demo/satellite.js b/examples/amapPlugin/bus/demo/satellite.js index ef27b74905..d6311a40e0 100644 --- a/examples/amapPlugin/bus/demo/satellite.js +++ b/examples/amapPlugin/bus/demo/satellite.js @@ -4,13 +4,13 @@ import { GaodeMap } from '@antv/l7-maps'; const scene = new Scene({ id: 'map', map: new GaodeMap({ - center: [105, 30], + center: [ 105, 30 ], pitch: 0, - zoom: 2, + zoom: 2 }) }); scene.on('loaded', () => { - scene.getMapService().map.add(new window.AMap.TileLayer.Satellite()); + scene.getMapService().map.add(new window.AMap.TileLayer.Satellite()); }); diff --git a/examples/amapPlugin/bus/demo/xyzTile.js b/examples/amapPlugin/bus/demo/xyzTile.js index 16e474db62..743da200f1 100644 --- a/examples/amapPlugin/bus/demo/xyzTile.js +++ b/examples/amapPlugin/bus/demo/xyzTile.js @@ -4,17 +4,17 @@ import { GaodeMap } from '@antv/l7-maps'; const scene = new Scene({ id: 'map', map: new GaodeMap({ - center: [105, 30], + center: [ 105, 30 ], pitch: 0, - zoom: 2, + zoom: 2 }) }); scene.on('loaded', () => { - var xyzTileLayer = new window.AMap.TileLayer({ - getTileUrl: + const xyzTileLayer = new window.AMap.TileLayer({ + getTileUrl: 'https://wprd0{1,2,3,4}.is.autonavi.com/appmaptile?x=[x]&y=[y]&z=[z]&size=1&scl=1&style=8<ype=11', - zIndex: 100, - }); - scene.getMapService().map.add(xyzTileLayer); + zIndex: 100 + }); + scene.getMapService().map.add(xyzTileLayer); }); diff --git a/packages/layers/src/utils/updateShape.ts b/packages/layers/src/utils/updateShape.ts index b29f37a6ce..15dda8c13c 100644 --- a/packages/layers/src/utils/updateShape.ts +++ b/packages/layers/src/utils/updateShape.ts @@ -23,7 +23,7 @@ export function updateShape( typeof currentShape === 'string' && lastShape !== currentShape ) { - if(layer.type === 'PointLayer') { + if (layer.type === 'PointLayer') { layer.dataState.dataSourceNeedUpdate = true; return; } diff --git a/stories/Map/components/mapCenter.tsx b/stories/Map/components/mapCenter.tsx index fb6dc16eaf..57c543c954 100644 --- a/stories/Map/components/mapCenter.tsx +++ b/stories/Map/components/mapCenter.tsx @@ -113,9 +113,9 @@ export default class GaodeMapComponent extends React.Component { // .active({ color: '#00f' }); setTimeout(() => { - layer.shape('triangleColumn') + layer.shape('triangleColumn'); scene.render(); - }, 2000) + }, 2000); this.scene = scene;