mirror of https://gitee.com/antv-l7/antv-l7
Merge pull request #104 from antvis/docs_fix
docs(docs): fix docs error
This commit is contained in:
commit
8351aaec28
|
@ -18,7 +18,7 @@ order: 0
|
|||
2.0版本在L7内部动态引入了高德地图JS API,因此不再需要单独引入高德JS API,只需设置 type 为 ```amap``` 并且传入token
|
||||
|
||||
```html
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.9/dist/l7.js"></script>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.13/dist/l7.js"></script>
|
||||
```
|
||||
|
||||
### 添加div 标签指定地图容器
|
||||
|
@ -106,7 +106,7 @@ fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')
|
|||
</head>
|
||||
<body>
|
||||
<div id="map"></div>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.9/dist/l7.js"></script>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.13/dist/l7.js"></script>
|
||||
<script>
|
||||
|
||||
const scene = new L7.Scene({
|
||||
|
|
|
@ -18,7 +18,7 @@ order: 0
|
|||
2.0版本在L7内部动态引入了高德地图JS API,因此不再需要单独引入高德JS API,只需设置 type 为 ```amap``` 并且传入token
|
||||
|
||||
```html
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.9/dist/l7.js"></script>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.13/dist/l7.js"></script>
|
||||
```
|
||||
|
||||
### 添加div 标签指定地图容器
|
||||
|
@ -106,7 +106,7 @@ fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')
|
|||
</head>
|
||||
<body>
|
||||
<div id="map"></div>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.9/dist/l7.js"></script>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.13/dist/l7.js"></script>
|
||||
<script>
|
||||
|
||||
const scene = new L7.Scene({
|
||||
|
|
|
@ -24,7 +24,7 @@ order: 0
|
|||
|
||||
|
||||
```html
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.9/dist/l7.js"></script>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.13/dist/l7.js"></script>
|
||||
```
|
||||
|
||||
|
||||
|
@ -114,7 +114,7 @@ fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')
|
|||
</head>
|
||||
<body>
|
||||
<div id="map"></div>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.9/dist/l7.js"></script>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.13/dist/l7.js"></script>
|
||||
<script>
|
||||
const scene = new L7.Scene({
|
||||
id: 'map',
|
||||
|
|
|
@ -24,7 +24,7 @@ order: 0
|
|||
|
||||
|
||||
```html
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.9/dist/l7.js"></script>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.13/dist/l7.js"></script>
|
||||
```
|
||||
|
||||
|
||||
|
@ -115,7 +115,7 @@ fetch('https://gw.alipayobjects.com/os/rmsportal/oVTMqfzuuRFKiDwhPSFL.json')
|
|||
</head>
|
||||
<body>
|
||||
<div id="map"></div>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.9/dist/l7.js"></script>
|
||||
<script src="https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.13/dist/l7.js"></script>
|
||||
<script>
|
||||
const scene = new L7.Scene({
|
||||
id: 'map',
|
||||
|
|
|
@ -18,7 +18,7 @@ Include the L7 JS JavaScript <head> of your HTML file.
|
|||
|
||||
```html
|
||||
<head>
|
||||
<script src='https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.5/dist/l7.js'>
|
||||
<script src='https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.13/dist/l7.js'>
|
||||
</script>
|
||||
</head>
|
||||
```
|
||||
|
@ -44,7 +44,7 @@ npm install --save @antv/l7-maps;
|
|||
|
||||
### 初始化地图
|
||||
|
||||
#### 使用 Mapbox 底图
|
||||
#### 使用 高德 底图
|
||||
|
||||
```javascript
|
||||
|
||||
|
|
|
@ -17,14 +17,14 @@ Include the L7 JS JavaScript <head> of your HTML file.
|
|||
|
||||
```html
|
||||
<head>
|
||||
<script src='https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.5/dist/l7.js'>
|
||||
<script src='https://gw.alipayobjects.com/os/antv/pkg/_antv.l7-2.0.0-beta.13/dist/l7.js'>
|
||||
</script>
|
||||
</head>
|
||||
```
|
||||
|
||||
- [use Gaode Map](../map/amap.en.md)
|
||||
- [use Gaode Map](./map/amap)
|
||||
|
||||
- [use Mapbox Map ](../map/mapbox.en.md)
|
||||
- [use Mapbox Map ](./map/mapbox)
|
||||
|
||||
|
||||
## 通过 Module bundle 使用
|
||||
|
@ -43,7 +43,7 @@ npm install --save @antv/l7-maps;
|
|||
|
||||
### 初始化地图
|
||||
|
||||
#### 使用 Mapbox 底图
|
||||
#### 使用 高德 底图
|
||||
|
||||
```javascript
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ void main() {
|
|||
vec2 offset = project_pixel(size.xy);
|
||||
|
||||
vec4 project_pos = project_position(vec4(a_Pos.xy, 0, 1.0));
|
||||
vec4 pos = vec4(project_pos.xy + offset, size.z, 1.0);
|
||||
vec4 pos = vec4(project_pos.xy + offset, project_pixel(size.z), 1.0);
|
||||
|
||||
float lightWeight = calc_lighting(pos);
|
||||
v_color =vec4(a_Color.rgb * lightWeight, a_Color.w);
|
||||
|
|
Loading…
Reference in New Issue