fix: devDependencies

This commit is contained in:
thinkinggis 2020-11-09 00:35:32 +08:00
parent 54a69cefd2
commit c551308470
5 changed files with 12 additions and 27 deletions

View File

@ -10,12 +10,7 @@ L7 Layer 接口设计遵循图形语法,所有图层都继承于该基类。
语法示例 语法示例
```javascript ```javascript
const layer = new Layer(option) const layer = new Layer(option).source().color().size().shape().style();
.source()
.color()
.size()
.shape()
.style();
scene.addLayer(layer); scene.addLayer(layer);
``` ```
@ -83,7 +78,7 @@ layer.source(data, {
transforms: [ transforms: [
{ {
type: 'map', type: 'map',
callback: function(item) { callback: function (item) {
const [x, y] = item.coordinates; const [x, y] = item.coordinates;
item.lat = item.lat * 1; item.lat = item.lat * 1;
item.lng = item.lng * 1; item.lng = item.lng * 1;

View File

@ -10,12 +10,7 @@ L7 Layer 接口设计遵循图形语法,所有图层都继承于该基类。
语法示例 语法示例
```javascript ```javascript
const layer = new Layer(option) const layer = new Layer(option).source().color().size().shape().style();
.source()
.color()
.size()
.shape()
.style();
scene.addLayer(layer); scene.addLayer(layer);
``` ```
@ -87,7 +82,7 @@ layer.source(data, {
transforms: [ transforms: [
{ {
type: 'map', type: 'map',
callback: function(item) { callback: function (item) {
const [x, y] = item.coordinates; const [x, y] = item.coordinates;
item.lat = item.lat * 1; item.lat = item.lat * 1;
item.lng = item.lng * 1; item.lng = item.lng * 1;

View File

@ -7,8 +7,8 @@
}, },
"devDependencies": { "devDependencies": {
"@antv/g2": "^3.5.9", "@antv/g2": "^3.5.9",
"@antv/l7-district": "2.2.42", "@antv/l7-district": "^2.2.42",
"@antv/l7-draw": "2.3.40", "@antv/l7-draw": "^2.3.40",
"@antv/l7-react": "^2.2.37", "@antv/l7-react": "^2.2.37",
"@antv/l7-district": "^2.2.37", "@antv/l7-district": "^2.2.37",
"@antv/gatsby-theme-antv": "^1.0.0-beta.11", "@antv/gatsby-theme-antv": "^1.0.0-beta.11",

View File

@ -30,12 +30,7 @@ export default class ZoomComponent extends React.Component {
this.scene = scene; this.scene = scene;
const layer = new PolygonLayer({}); const layer = new PolygonLayer({});
layer layer.source(data).color('#fff').shape('name', 'text').size(16).style({
.source(data)
.color('#fff')
.shape('name', 'text')
.size(16)
.style({
opacity: 1.0, opacity: 1.0,
}); });
scene.addLayer(layer); scene.addLayer(layer);

View File

@ -52,9 +52,9 @@ export default class Country extends React.Component {
enable: true, enable: true,
openTriggerEvent: 'click', openTriggerEvent: 'click',
Html: (props: any) => { Html: (props: any) => {
return `<span><button onclick='alert(11111)'>点击</button>${props.NAME_CHN + return `<span><button onclick='alert(11111)'>点击</button>${
':' + props.NAME_CHN + ':' + props.value
props.value}</span>`; }</span>`;
}, },
}, },
}); });