mirror of
https://github.com/visgl/react-map-gl.git
synced 2026-01-18 15:54:22 +00:00
remove d3-selection and extra example map (#189)
* remove d3-selection * remove extra example map
This commit is contained in:
parent
d28d5cb432
commit
da55fffe07
@ -51,7 +51,6 @@ export default class App extends Component {
|
||||
<NotInteractiveExample {...common}/>
|
||||
<StyleDiffingExample {...common}/>
|
||||
<ClickExample {...common }/>
|
||||
<StyleDiffingExample {...common}/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@ -33,7 +33,6 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"bowser": "^1.2.0",
|
||||
"d3-selection": "^1.0.2",
|
||||
"flow-remove-types": "^1.1.2",
|
||||
"glob": "^7.1.1",
|
||||
"global": "^4.3.0",
|
||||
|
||||
@ -22,7 +22,6 @@ import shallowCompare from 'react-addons-shallow-compare';
|
||||
import autobind from '../utils/autobind';
|
||||
|
||||
import mapboxgl, {Point} from 'mapbox-gl';
|
||||
import {select} from 'd3-selection';
|
||||
import Immutable from 'immutable';
|
||||
import assert from 'assert';
|
||||
import window from 'global/window';
|
||||
@ -279,8 +278,11 @@ export default class MapGL extends Component {
|
||||
// attributionControl: this.props.attributionControl
|
||||
});
|
||||
|
||||
// TODO - can we drop d3-select dependency?
|
||||
select(map.getCanvas()).style('outline', 'none');
|
||||
// Disable outline style
|
||||
const canvas = map.getCanvas();
|
||||
if (canvas) {
|
||||
canvas.style.outline = 'none';
|
||||
}
|
||||
|
||||
this._map = map;
|
||||
this._updateMapViewport({}, this.props);
|
||||
|
||||
@ -26,7 +26,6 @@ import diffStyles from '../utils/diff-styles';
|
||||
import config from '../config';
|
||||
|
||||
import mapboxgl, {Point} from 'mapbox-gl';
|
||||
import {select} from 'd3-selection';
|
||||
import Immutable from 'immutable';
|
||||
|
||||
function noop() {}
|
||||
@ -171,7 +170,11 @@ export default class StaticMap extends Component {
|
||||
// attributionControl: this.props.attributionControl
|
||||
});
|
||||
|
||||
select(map.getCanvas()).style('outline', 'none');
|
||||
// Disable outline style
|
||||
const canvas = map.getCanvas();
|
||||
if (canvas) {
|
||||
canvas.style.outline = 'none';
|
||||
}
|
||||
|
||||
this._map = map;
|
||||
this._updateMapViewport({}, this.props);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user