Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
area = d3Geo.geoArea(sampleExtendedGeometryCollection);
area = d3Geo.geoArea(sampleFeature);
area = d3Geo.geoArea(sampleExtendedFeature1);
area = d3Geo.geoArea(sampleExtendedFeature2);
area = d3Geo.geoArea(sampleFeatureCollection);
area = d3Geo.geoArea(sampleExtendedFeatureCollection);
// geoBounds(...) =========================================================
let bounds: [[number, number], [number, number]] = d3Geo.geoBounds(samplePolygon);
bounds = d3Geo.geoBounds(sampleSphere);
bounds = d3Geo.geoBounds(sampleGeometryCollection);
bounds = d3Geo.geoBounds(sampleExtendedGeometryCollection);
bounds = d3Geo.geoBounds(sampleFeature);
bounds = d3Geo.geoBounds(sampleExtendedFeature1);
bounds = d3Geo.geoBounds(sampleExtendedFeature2);
bounds = d3Geo.geoBounds(sampleFeatureCollection);
bounds = d3Geo.geoBounds(sampleExtendedFeatureCollection);
// geoCentroid(...) =======================================================
let centroid: [number, number] = d3Geo.geoCentroid(samplePolygon);
centroid = d3Geo.geoCentroid(sampleSphere);
centroid = d3Geo.geoCentroid(sampleGeometryCollection);
centroid = d3Geo.geoCentroid(sampleExtendedGeometryCollection);
centroid = d3Geo.geoCentroid(sampleFeature);
centroid = d3Geo.geoCentroid(sampleExtendedFeature1);
centroid = d3Geo.geoCentroid(sampleExtendedFeature2);
centroid = d3Geo.geoCentroid(sampleFeatureCollection);
centroid = d3Geo.geoCentroid(sampleExtendedFeatureCollection);
// geoContains(...) =======================================================
// geoArea(...) =========================================================
let area: number = d3Geo.geoArea(samplePolygon);
area = d3Geo.geoArea(sampleSphere);
area = d3Geo.geoArea(sampleGeometryCollection);
area = d3Geo.geoArea(sampleExtendedGeometryCollection);
area = d3Geo.geoArea(sampleFeature);
area = d3Geo.geoArea(sampleExtendedFeature1);
area = d3Geo.geoArea(sampleExtendedFeature2);
area = d3Geo.geoArea(sampleFeatureCollection);
area = d3Geo.geoArea(sampleExtendedFeatureCollection);
// geoBounds(...) =========================================================
let bounds: [[number, number], [number, number]] = d3Geo.geoBounds(samplePolygon);
bounds = d3Geo.geoBounds(sampleSphere);
bounds = d3Geo.geoBounds(sampleGeometryCollection);
bounds = d3Geo.geoBounds(sampleExtendedGeometryCollection);
bounds = d3Geo.geoBounds(sampleFeature);
bounds = d3Geo.geoBounds(sampleExtendedFeature1);
bounds = d3Geo.geoBounds(sampleExtendedFeature2);
bounds = d3Geo.geoBounds(sampleFeatureCollection);
bounds = d3Geo.geoBounds(sampleExtendedFeatureCollection);
// geoCentroid(...) =======================================================
let centroid: [number, number] = d3Geo.geoCentroid(samplePolygon);
centroid = d3Geo.geoCentroid(sampleSphere);
centroid = d3Geo.geoCentroid(sampleGeometryCollection);
centroid = d3Geo.geoCentroid(sampleExtendedGeometryCollection);
centroid = d3Geo.geoCentroid(sampleFeature);
area = d3Geo.geoArea(sampleSphere);
area = d3Geo.geoArea(sampleGeometryCollection);
area = d3Geo.geoArea(sampleExtendedGeometryCollection);
area = d3Geo.geoArea(sampleFeature);
area = d3Geo.geoArea(sampleExtendedFeature1);
area = d3Geo.geoArea(sampleExtendedFeature2);
area = d3Geo.geoArea(sampleFeatureCollection);
area = d3Geo.geoArea(sampleExtendedFeatureCollection);
// geoBounds(...) =========================================================
let bounds: [[number, number], [number, number]] = d3Geo.geoBounds(samplePolygon);
bounds = d3Geo.geoBounds(sampleSphere);
bounds = d3Geo.geoBounds(sampleGeometryCollection);
bounds = d3Geo.geoBounds(sampleExtendedGeometryCollection);
bounds = d3Geo.geoBounds(sampleFeature);
bounds = d3Geo.geoBounds(sampleExtendedFeature1);
bounds = d3Geo.geoBounds(sampleExtendedFeature2);
bounds = d3Geo.geoBounds(sampleFeatureCollection);
bounds = d3Geo.geoBounds(sampleExtendedFeatureCollection);
// geoCentroid(...) =======================================================
let centroid: [number, number] = d3Geo.geoCentroid(samplePolygon);
centroid = d3Geo.geoCentroid(sampleSphere);
centroid = d3Geo.geoCentroid(sampleGeometryCollection);
centroid = d3Geo.geoCentroid(sampleExtendedGeometryCollection);
centroid = d3Geo.geoCentroid(sampleFeature);
centroid = d3Geo.geoCentroid(sampleExtendedFeature1);
centroid = d3Geo.geoCentroid(sampleExtendedFeature2);
centroid = d3Geo.geoCentroid(sampleFeatureCollection);
centroid = d3Geo.geoCentroid(sampleExtendedFeatureCollection);
area = d3Geo.geoArea(sampleSphere);
area = d3Geo.geoArea(sampleGeometryCollection);
area = d3Geo.geoArea(sampleExtendedGeometryCollection);
area = d3Geo.geoArea(sampleFeature);
area = d3Geo.geoArea(sampleExtendedFeature1);
area = d3Geo.geoArea(sampleExtendedFeature2);
area = d3Geo.geoArea(sampleFeatureCollection);
area = d3Geo.geoArea(sampleExtendedFeatureCollection);
// geoBounds(...) =========================================================
let bounds: [[number, number], [number, number]] = d3Geo.geoBounds(samplePolygon);
bounds = d3Geo.geoBounds(sampleSphere);
bounds = d3Geo.geoBounds(sampleGeometryCollection);
bounds = d3Geo.geoBounds(sampleExtendedGeometryCollection);
bounds = d3Geo.geoBounds(sampleFeature);
bounds = d3Geo.geoBounds(sampleExtendedFeature1);
bounds = d3Geo.geoBounds(sampleExtendedFeature2);
bounds = d3Geo.geoBounds(sampleFeatureCollection);
bounds = d3Geo.geoBounds(sampleExtendedFeatureCollection);
// geoCentroid(...) =======================================================
let centroid: [number, number] = d3Geo.geoCentroid(samplePolygon);
centroid = d3Geo.geoCentroid(sampleSphere);
centroid = d3Geo.geoCentroid(sampleGeometryCollection);
centroid = d3Geo.geoCentroid(sampleExtendedGeometryCollection);
centroid = d3Geo.geoCentroid(sampleFeature);
centroid = d3Geo.geoCentroid(sampleExtendedFeature1);
centroid = d3Geo.geoCentroid(sampleExtendedFeature2);
centroid = d3Geo.geoCentroid(sampleFeatureCollection);
centroid = d3Geo.geoCentroid(sampleExtendedFeatureCollection);
// geoArea(...) =========================================================
let area: number = d3Geo.geoArea(samplePolygon);
area = d3Geo.geoArea(sampleSphere);
area = d3Geo.geoArea(sampleGeometryCollection);
area = d3Geo.geoArea(sampleExtendedGeometryCollection);
area = d3Geo.geoArea(sampleFeature);
area = d3Geo.geoArea(sampleExtendedFeature1);
area = d3Geo.geoArea(sampleExtendedFeature2);
area = d3Geo.geoArea(sampleFeatureCollection);
area = d3Geo.geoArea(sampleExtendedFeatureCollection);
// geoBounds(...) =========================================================
let bounds: [[number, number], [number, number]] = d3Geo.geoBounds(samplePolygon);
bounds = d3Geo.geoBounds(sampleSphere);
bounds = d3Geo.geoBounds(sampleGeometryCollection);
bounds = d3Geo.geoBounds(sampleExtendedGeometryCollection);
bounds = d3Geo.geoBounds(sampleFeature);
bounds = d3Geo.geoBounds(sampleExtendedFeature1);
bounds = d3Geo.geoBounds(sampleExtendedFeature2);
bounds = d3Geo.geoBounds(sampleFeatureCollection);
bounds = d3Geo.geoBounds(sampleExtendedFeatureCollection);
// geoCentroid(...) =======================================================
let centroid: [number, number] = d3Geo.geoCentroid(samplePolygon);
centroid = d3Geo.geoCentroid(sampleSphere);
centroid = d3Geo.geoCentroid(sampleGeometryCollection);
centroid = d3Geo.geoCentroid(sampleExtendedGeometryCollection);
centroid = d3Geo.geoCentroid(sampleFeature);
centroid = d3Geo.geoCentroid(sampleExtendedFeature1);
let area: number = d3Geo.geoArea(samplePolygon);
area = d3Geo.geoArea(sampleSphere);
area = d3Geo.geoArea(sampleGeometryCollection);
area = d3Geo.geoArea(sampleExtendedGeometryCollection);
area = d3Geo.geoArea(sampleFeature);
area = d3Geo.geoArea(sampleExtendedFeature1);
area = d3Geo.geoArea(sampleExtendedFeature2);
area = d3Geo.geoArea(sampleFeatureCollection);
area = d3Geo.geoArea(sampleExtendedFeatureCollection);
// geoBounds(...) =========================================================
let bounds: [[number, number], [number, number]] = d3Geo.geoBounds(samplePolygon);
bounds = d3Geo.geoBounds(sampleSphere);
bounds = d3Geo.geoBounds(sampleGeometryCollection);
bounds = d3Geo.geoBounds(sampleExtendedGeometryCollection);
bounds = d3Geo.geoBounds(sampleFeature);
bounds = d3Geo.geoBounds(sampleExtendedFeature1);
bounds = d3Geo.geoBounds(sampleExtendedFeature2);
bounds = d3Geo.geoBounds(sampleFeatureCollection);
bounds = d3Geo.geoBounds(sampleExtendedFeatureCollection);
// geoCentroid(...) =======================================================
let centroid: [number, number] = d3Geo.geoCentroid(samplePolygon);
centroid = d3Geo.geoCentroid(sampleSphere);
centroid = d3Geo.geoCentroid(sampleGeometryCollection);
centroid = d3Geo.geoCentroid(sampleExtendedGeometryCollection);
centroid = d3Geo.geoCentroid(sampleFeature);
centroid = d3Geo.geoCentroid(sampleExtendedFeature1);
centroid = d3Geo.geoCentroid(sampleExtendedFeature2);
// geoArea(...) =========================================================
let area: number = d3Geo.geoArea(samplePolygon);
area = d3Geo.geoArea(sampleSphere);
area = d3Geo.geoArea(sampleGeometryCollection);
area = d3Geo.geoArea(sampleExtendedGeometryCollection);
area = d3Geo.geoArea(sampleFeature);
area = d3Geo.geoArea(sampleExtendedFeature1);
area = d3Geo.geoArea(sampleExtendedFeature2);
area = d3Geo.geoArea(sampleFeatureCollection);
area = d3Geo.geoArea(sampleExtendedFeatureCollection);
// geoBounds(...) =========================================================
let bounds: [[number, number], [number, number]] = d3Geo.geoBounds(samplePolygon);
bounds = d3Geo.geoBounds(sampleSphere);
bounds = d3Geo.geoBounds(sampleGeometryCollection);
bounds = d3Geo.geoBounds(sampleExtendedGeometryCollection);
bounds = d3Geo.geoBounds(sampleFeature);
bounds = d3Geo.geoBounds(sampleExtendedFeature1);
bounds = d3Geo.geoBounds(sampleExtendedFeature2);
bounds = d3Geo.geoBounds(sampleFeatureCollection);
bounds = d3Geo.geoBounds(sampleExtendedFeatureCollection);
// geoCentroid(...) =======================================================
let centroid: [number, number] = d3Geo.geoCentroid(samplePolygon);
centroid = d3Geo.geoCentroid(sampleSphere);
centroid = d3Geo.geoCentroid(sampleGeometryCollection);
centroid = d3Geo.geoCentroid(sampleExtendedGeometryCollection);
centroid = d3Geo.geoCentroid(sampleFeature);
centroid = d3Geo.geoCentroid(sampleExtendedFeature1);
break;
case 'MultiPolygon':
c = _flatten(c);
case 'Polygon':
case 'MultiLineString':
c = _flatten(c);
break;
}
/* eslint-enable no-fallthrough */
return _union(coords, c);
}, []);
if (!geoPolygonIntersectsPolygon(viewport, coords, true)) {
var extent = geoExtent(d3_geoBounds({ type: 'LineString', coordinates: coords }));
map.centerZoom(extent.center(), map.trimmedExtentZoom(extent));
}
return this;
};
function outline(stream, node, parent) {
var point,
edges = node.edges,
n = edges.length,
edge,
multiPoint = {type: "MultiPoint", coordinates: node.face},
notPoles = node.face.filter(function(d) { return abs(d[1]) !== 90; }),
b = bounds({type: "MultiPoint", coordinates: notPoles}),
inside = false,
j = -1,
dx = b[1][0] - b[0][0];
// TODO
var c = dx === 180 || dx === 360
? [(b[0][0] + b[1][0]) / 2, (b[0][1] + b[1][1]) / 2]
: centroid(multiPoint);
// First find the shared edge…
if (parent) while (++j < n) {
if (edges[j] === parent) break;
}
++j;
for (var i = 0; i < n; ++i) {
edge = edges[(i + j) % n];
if (Array.isArray(edge)) {
if (!inside) {
MapObject.prototype.updateExtremes = function () {
var feature = this.getFeature();
if (feature) {
var geometry = feature.geometry;
if (geometry) {
var bounds = d3geo.geoBounds(geometry);
var west = bounds[0][0];
var south = bounds[0][1];
var north = bounds[1][1];
var east = bounds[1][0];
var changed = false;
if (north != this.north) {
this._north = $math.round(north, 8);
changed = true;
}
if (south != this.south) {
this._south = $math.round(south);
changed = true;
}
if (east != this.east) {
this._east = $math.round(east);
changed = true;