remove d3-selection and extra example map (#189)

* remove d3-selection

* remove extra example map
This commit is contained in:
Anh Mai 2017-02-08 23:19:08 -08:00 committed by Ib Green
parent d28d5cb432
commit da55fffe07
5 changed files with 4319 additions and 7 deletions

View File

@ -51,7 +51,6 @@ export default class App extends Component {
<NotInteractiveExample {...common}/>
<StyleDiffingExample {...common}/>
<ClickExample {...common }/>
<StyleDiffingExample {...common}/>
</div>
);
}

View File

@ -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",

View File

@ -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);

View File

@ -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);

4309
yarn.lock Normal file

File diff suppressed because it is too large Load Diff