mirror of https://gitee.com/antv-l7/antv-l7
fix(doc): add Scale example
This commit is contained in:
parent
68a1af7607
commit
9ddf70296a
|
@ -25,13 +25,13 @@ position: `string` 控件位置支持是个方位
|
||||||
### 组件介绍
|
### 组件介绍
|
||||||
|
|
||||||
```
|
```
|
||||||
import { Scale Layers, Zoom } from '@antv/l7';
|
import { Scale, Layers, Zoom } from '@antv/l7';
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Zoom
|
#### Zoom
|
||||||
|
|
||||||
放大缩小组件 默认 左上角
|
放大缩小组件 默认左上角
|
||||||
|
|
||||||
```javascript
|
```javascript
|
||||||
const zoomControl = new Zoom({
|
const zoomControl = new Zoom({
|
||||||
|
@ -43,14 +43,14 @@ scene.addControl(zoomControl);
|
||||||
|
|
||||||
#### Scale
|
#### Scale
|
||||||
|
|
||||||
比例尺组件默认左下角
|
比例尺组件 默认左下角
|
||||||
|
|
||||||
```javascript
|
```javascript
|
||||||
const zoomControl = new Zoom({
|
const scaleControl = new Scale({
|
||||||
position: 'topleft',
|
position: 'bottomleft',
|
||||||
});
|
});
|
||||||
|
|
||||||
scene.addControl(zoomControl);
|
scene.addControl(scaleControl);
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Layers
|
#### Layers
|
||||||
|
|
Loading…
Reference in New Issue