Skip to content

Interactive interface for browsing global, full-resolution satellite imagery

Move ext scripts to dependencies key

Jo Sprague443b87c0a4c6
diff --git a/Gruntfile.js b/Gruntfile.js
index a8d0139fa..5f182c1c6 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -721,7 +721,7 @@ module.exports = function(grunt) {
grunt.registerTask('test', ['buster:console']);
grunt.registerTask('default', [
- 'update-packages',
+ // 'update-packages',
'fetch',
'update',
'build',
diff --git a/package-lock.json b/package-lock.json
index 24f629f48..da4c4dae5 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -439,7 +439,7 @@
"dev": true,
"requires": {
"browserslist": "2.9.0",
- "caniuse-lite": "1.0.30000764",
+ "caniuse-lite": "1.0.30000766",
"normalize-range": "0.1.2",
"num2fraction": "1.2.2",
"postcss": "6.0.14",
@@ -1263,9 +1263,9 @@
"dev": true
},
"binary-extensions": {
- "version": "1.10.0",
- "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.10.0.tgz",
- "integrity": "sha1-muuabF6IY4qtFx4Wf1kAq+JINdA=",
+ "version": "1.11.0",
+ "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.11.0.tgz",
+ "integrity": "sha1-RqoXUftqL5PuXmibsQh9SxTGwgU=",
"dev": true
},
"bl": {
@@ -1607,7 +1607,7 @@
"integrity": "sha512-vJEBcDTANoDhSHL46NeOEW5hvQw7It9uCqzeFPQhpawXfnOwnpvW5C97vn1eGJ7iCkSg8wWU0nYObE7d/N95Iw==",
"dev": true,
"requires": {
- "caniuse-lite": "1.0.30000764",
+ "caniuse-lite": "1.0.30000766",
"electron-to-chromium": "1.3.27"
}
},
@@ -2036,15 +2036,15 @@
}
},
"caniuse-db": {
- "version": "1.0.30000764",
- "resolved": "https://registry.npmjs.org/caniuse-db/-/caniuse-db-1.0.30000764.tgz",
- "integrity": "sha1-1zqxGuYvap4vaYZ9bZwjrj8uXY0=",
+ "version": "1.0.30000766",
+ "resolved": "https://registry.npmjs.org/caniuse-db/-/caniuse-db-1.0.30000766.tgz",
+ "integrity": "sha1-TJEao3R/ATiEUvpLknt4/PFDBoA=",
"dev": true
},
"caniuse-lite": {
- "version": "1.0.30000764",
- "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30000764.tgz",
- "integrity": "sha1-l+p0cvnT5pHu3jTyGYPPwhmseEI=",
+ "version": "1.0.30000766",
+ "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30000766.tgz",
+ "integrity": "sha1-iglcxeuZI8JwCM5NDbI+ZaPiiEM=",
"dev": true
},
"capture-stack-trace": {
@@ -2090,6 +2090,12 @@
"supports-color": "4.5.0"
}
},
+ "chardet": {
+ "version": "0.4.0",
+ "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.4.0.tgz",
+ "integrity": "sha1-C74TVaxE16PtSpJXB8TvcPgZD2w=",
+ "dev": true
+ },
"chokidar": {
"version": "1.7.0",
"resolved": "https://registry.npmjs.org/chokidar/-/chokidar-1.7.0.tgz",
@@ -3505,7 +3511,7 @@
"dev": true,
"requires": {
"browserslist": "1.7.7",
- "caniuse-db": "1.0.30000764",
+ "caniuse-db": "1.0.30000766",
"css-rule-stream": "1.1.0",
"duplexer2": "0.0.2",
"jsonfilter": "1.1.2",
@@ -3530,7 +3536,7 @@
"integrity": "sha1-C9dnBCWL6CmyOYu1Dkti0aFmsLk=",
"dev": true,
"requires": {
- "caniuse-db": "1.0.30000764",
+ "caniuse-db": "1.0.30000766",
"electron-to-chromium": "1.3.27"
}
},
@@ -4546,13 +4552,13 @@
"dev": true
},
"external-editor": {
- "version": "2.0.5",
- "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-2.0.5.tgz",
- "integrity": "sha512-Msjo64WT5W+NhOpQXh0nOHm+n0RfU1QUwDnKYvJ8dEJ8zlwLrqXNTv5mSUTJpepf41PDJGyhueTw2vNZW+Fr/w==",
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-2.1.0.tgz",
+ "integrity": "sha512-E44iT5QVOUJBKij4IIV3uvxuNlbKS38Tw1HiupxEIHPv9qtC2PrDYohbXV5U+1jnfIXttny8gUhj+oZvflFlzA==",
"dev": true,
"requires": {
+ "chardet": "0.4.0",
"iconv-lite": "0.4.19",
- "jschardet": "1.6.0",
"tmp": "0.0.33"
}
},
@@ -5003,7 +5009,7 @@
"dev": true,
"optional": true,
"requires": {
- "nan": "2.7.0",
+ "nan": "2.8.0",
"node-pre-gyp": "0.6.39"
},
"dependencies": {
@@ -5527,9 +5533,9 @@
"optional": true
},
"nan": {
- "version": "2.7.0",
- "resolved": "https://registry.npmjs.org/nan/-/nan-2.7.0.tgz",
- "integrity": "sha1-2Vv3IeyHfgjbJ27T/G63j5CDrUY=",
+ "version": "2.8.0",
+ "resolved": "https://registry.npmjs.org/nan/-/nan-2.8.0.tgz",
+ "integrity": "sha1-7XFfP+neArV6XmJS2QqWZ14fCFo=",
"dev": true,
"optional": true
},
@@ -6859,7 +6865,7 @@
"dev": true,
"requires": {
"browserslist": "1.7.7",
- "caniuse-db": "1.0.30000764",
+ "caniuse-db": "1.0.30000766",
"normalize-range": "0.1.2",
"num2fraction": "1.2.2",
"postcss": "5.2.18",
@@ -6878,7 +6884,7 @@
"integrity": "sha1-C9dnBCWL6CmyOYu1Dkti0aFmsLk=",
"dev": true,
"requires": {
- "caniuse-db": "1.0.30000764",
+ "caniuse-db": "1.0.30000766",
"electron-to-chromium": "1.3.27"
}
},
@@ -7437,7 +7443,7 @@
"chalk": "2.3.0",
"cli-cursor": "2.1.0",
"cli-width": "2.2.0",
- "external-editor": "2.0.5",
+ "external-editor": "2.1.0",
"figures": "2.0.0",
"lodash": "4.15.0",
"mute-stream": "0.0.7",
@@ -7521,7 +7527,7 @@
"integrity": "sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg=",
"dev": true,
"requires": {
- "binary-extensions": "1.10.0"
+ "binary-extensions": "1.11.0"
}
},
"is-buffer": {
@@ -7823,6 +7829,26 @@
"integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=",
"dev": true
},
+ "jquery": {
+ "version": "2.2.4",
+ "resolved": "https://registry.npmjs.org/jquery/-/jquery-2.2.4.tgz",
+ "integrity": "sha1-LInWiJterFIqfuoywUUhVZxsvwI="
+ },
+ "jquery-jcrop": {
+ "version": "0.9.13",
+ "resolved": "https://registry.npmjs.org/jquery-jcrop/-/jquery-jcrop-0.9.13.tgz",
+ "integrity": "sha1-zajJVX//xWVAAIzHtikaDsQHG/U="
+ },
+ "jquery-ui": {
+ "version": "1.10.4",
+ "resolved": "https://registry.npmjs.org/jquery-ui/-/jquery-ui-1.10.4.tgz",
+ "integrity": "sha1-oJb+X04PKraaBYXPEEVYd/V1Br0="
+ },
+ "jquery.joyride": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/jquery.joyride/-/jquery.joyride-2.2.0.tgz",
+ "integrity": "sha1-iIM1wbseyLMd6Mz9s5QY+3M5rnI="
+ },
"js-base64": {
"version": "2.3.2",
"resolved": "https://registry.npmjs.org/js-base64/-/js-base64-2.3.2.tgz",
@@ -7859,11 +7885,10 @@
"dev": true,
"optional": true
},
- "jschardet": {
- "version": "1.6.0",
- "resolved": "https://registry.npmjs.org/jschardet/-/jschardet-1.6.0.tgz",
- "integrity": "sha512-xYuhvQ7I9PDJIGBWev9xm0+SMSed3ZDBAmvVjbFR1ZRLAF+vlXcQu6cRI9uAlj81rzikElRVteehwV7DuX2ZmQ==",
- "dev": true
+ "jscrollpane": {
+ "version": "2.0.22",
+ "resolved": "https://registry.npmjs.org/jscrollpane/-/jscrollpane-2.0.22.tgz",
+ "integrity": "sha1-WwMSK2A46FvUvYp4kZMvbRv+mAs="
},
"jsesc": {
"version": "1.3.0",
@@ -8915,6 +8940,14 @@
"integrity": "sha1-67Opd+evHGg65v2hK1Raa6bFhT0=",
"dev": true
},
+ "mobiscroll-jquery": {
+ "version": "3.2.6",
+ "resolved": "https://registry.npmjs.org/mobiscroll-jquery/-/mobiscroll-jquery-3.2.6.tgz",
+ "integrity": "sha512-dBszOkH6K5YfKqCVE+Z4GA5ZPfH9ZH97FIrhoXExLkIan7FUXeGIA/fn9DBnzGwr830ozsA313JrrLhFyLNQgw==",
+ "requires": {
+ "jquery": "2.2.4"
+ }
+ },
"mocha-nightwatch": {
"version": "3.2.2",
"resolved": "https://registry.npmjs.org/mocha-nightwatch/-/mocha-nightwatch-3.2.2.tgz",
@@ -9251,6 +9284,11 @@
"integrity": "sha1-0LFF62kRicY6eNIB3E/bEpPvDAM=",
"dev": true
},
+ "nouislider-browser": {
+ "version": "5.0.0-1",
+ "resolved": "https://registry.npmjs.org/nouislider-browser/-/nouislider-browser-5.0.0-1.tgz",
+ "integrity": "sha1-tnnhD8yLNFFI/Q9uCSe0RsWiAlk="
+ },
"npm-run-all": {
"version": "4.1.2",
"resolved": "https://registry.npmjs.org/npm-run-all/-/npm-run-all-4.1.2.tgz",
@@ -12130,7 +12168,7 @@
"dev": true,
"requires": {
"browserslist": "1.7.7",
- "caniuse-db": "1.0.30000764",
+ "caniuse-db": "1.0.30000766",
"normalize-range": "0.1.2",
"num2fraction": "1.2.2",
"postcss": "5.2.18",
@@ -12172,7 +12210,7 @@
"integrity": "sha1-C9dnBCWL6CmyOYu1Dkti0aFmsLk=",
"dev": true,
"requires": {
- "caniuse-db": "1.0.30000764",
+ "caniuse-db": "1.0.30000766",
"electron-to-chromium": "1.3.27"
}
},
@@ -12416,7 +12454,7 @@
"integrity": "sha1-C9dnBCWL6CmyOYu1Dkti0aFmsLk=",
"dev": true,
"requires": {
- "caniuse-db": "1.0.30000764",
+ "caniuse-db": "1.0.30000766",
"electron-to-chromium": "1.3.27"
}
},
@@ -12561,7 +12599,7 @@
"dev": true,
"requires": {
"browserslist": "2.9.0",
- "caniuse-lite": "1.0.30000764",
+ "caniuse-lite": "1.0.30000766",
"normalize-range": "0.1.2",
"num2fraction": "1.2.2",
"postcss": "6.0.14",
@@ -12780,7 +12818,7 @@
"dev": true,
"requires": {
"browserslist": "1.7.7",
- "caniuse-db": "1.0.30000764",
+ "caniuse-db": "1.0.30000766",
"normalize-range": "0.1.2",
"num2fraction": "1.2.2",
"postcss": "5.2.18",
@@ -12799,7 +12837,7 @@
"integrity": "sha1-C9dnBCWL6CmyOYu1Dkti0aFmsLk=",
"dev": true,
"requires": {
- "caniuse-db": "1.0.30000764",
+ "caniuse-db": "1.0.30000766",
"electron-to-chromium": "1.3.27"
}
},
diff --git a/package.json b/package.json
index 4190c7661..f470a22f7 100644
--- a/package.json
+++ b/package.json
@@ -80,9 +80,17 @@
"clipboard": "^1.7.1",
"font-awesome": "4.7.0",
"gifshot": "https://github.com/nasa-gibs/gifshot/archive/4.2.0.tar.gz",
+ "icheck": "^1.0.2",
"isotope-layout": "3.0.x",
"isotope-packery": "2.x.x",
+ "jquery": "^2.1.4",
+ "jquery-jcrop": "^0.9.13",
+ "jquery-ui": "1.10.4",
+ "jquery.joyride": "^2.2.0",
+ "jscrollpane": "^2.0.22",
"lodash": "4.15.0",
+ "mobiscroll-jquery": "^3.2.6",
+ "nouislider-browser": "^5.0.0-1",
"ol": "^4.4.2",
"perfect-scrollbar": "^0.8.1",
"proj4": "2.3.3",
@@ -94,74 +102,11 @@
},
"browser": {
"d3": "./web/ext/ui/d3/d3.js",
- "jquery": "./web/ext/main/jquery-2.1.4/jquery.js",
- "jquery-ui": "./web/ext/ui/jquery-ui-1.11.4/jquery-ui.js",
- "jquery-migrate": "./web/ext/main/jquery.migrate-1.2.1/jquery-migrate.min.js",
- "icheck": "./web/ext/ui/iCheck-1.0.2-patch/icheck.js",
- "jscrollpane": "./web/ext/ui/jquery.jscrollpane-2.0.22/jquery.jscrollpane.js",
- "mobiscroll": "./web/ext/date/mobiscroll-2.6.0/mobiscroll.js",
- "jcrop": "./web/ext/image/jcrop-0.9.12/jquery.Jcrop.js",
- "nouislider": "./web/ext/ui/noUiSlider-6.1.10/jquery.nouislider.min.js",
- "jcarousel": "./web/ext/layers/jcarousel/jcarousel.js",
- "perfect-scrollbar-jquery": "./web/ext/node_modules/perfect-scrollbar/dist/js/perfect-scrollbar.jquery.min.js",
- "isotope-jquery": "./web/ext/node_modules/isotope-layout/dist/isotope.pkgd.js"
+ "isotope-layout": "./node_modules/isotope-layout/dist/isotope.pkgd.js",
+ "jquery": "./node_modules/jquery/dist/jquery.js"
},
"browserify-shim": {
- "jquery": "global:$",
- "d3": "global:d3",
- "jquery-ui": {
- "exports": null,
- "depends": [
- "jquery:jQuery"
- ]
- },
- "jquery-migrate": {
- "exports": null,
- "depends": [
- "jquery:$"
- ]
- },
- "icheck": {
- "exports": null,
- "depends": [
- "jquery:jQuery"
- ]
- },
- "mobiscroll": {
- "exports": null,
- "depends": [
- "jquery:$"
- ]
- },
- "jscrollpane": {
- "exports": null,
- "depends": [
- "jquery:jQuery"
- ]
- },
- "nouislider": {
- "exports": null,
- "depends": [
- "jquery:$"
- ]
- },
- "jcarousel": {
- "exports": null,
- "depends": [
- "jquery:$"
- ]
- },
- "perfect-scrollbar-jquery": {
- "exports": "null",
- "depends": [
- "jquery:jQuery"
- ]
- },
- "isotope-jquery": {
- "exports": "null",
- "depends": [
- "jquery:jQuery"
- ]
- }
+ "isotope-layout": "isotope",
+ "jquery": "$"
}
}
diff --git a/web/ext/ui/d3/d3.js b/web/ext/ui/d3/d3.js
index 1a36e1246..2948b1237 100644
--- a/web/ext/ui/d3/d3.js
+++ b/web/ext/ui/d3/d3.js
@@ -1,3 +1,4 @@
+// This is a fork of [email protected] with the changes in this commit: https://github.com/d3/d3/pull/2019/files
!function() {
var d3 = {
version: "3.4.11"
@@ -1108,7 +1109,7 @@
d3_mouse_bug44083 = !(ctm.f || ctm.e);
svg.remove();
}
- if (d3_mouse_bug44083) point.x = e.pageX, point.y = e.pageY; else point.x = e.clientX,
+ if (d3_mouse_bug44083) point.x = e.pageX, point.y = e.pageY; else point.x = e.clientX,
point.y = e.clientY;
point = point.matrixTransform(container.getScreenCTM().inverse());
return [ point.x, point.y ];
@@ -1477,7 +1478,7 @@
}
function mousewheeled() {
var dispatch = event.of(this, arguments);
- if (mousewheelTimer) clearTimeout(mousewheelTimer); else translate0 = location(center0 = center || d3.mouse(this)),
+ if (mousewheelTimer) clearTimeout(mousewheelTimer); else translate0 = location(center0 = center || d3.mouse(this)),
d3_selection_interrupt.call(this), zoomstarted(dispatch);
mousewheelTimer = setTimeout(function() {
mousewheelTimer = null;
@@ -1857,7 +1858,7 @@
d3.xhr = d3_xhrType(d3_identity);
function d3_xhrType(response) {
return function(url, mimeType, callback) {
- if (arguments.length === 2 && typeof mimeType === "function") callback = mimeType,
+ if (arguments.length === 2 && typeof mimeType === "function") callback = mimeType,
mimeType = null;
return d3_xhr(url, mimeType, response, callback);
};
@@ -2689,7 +2690,7 @@
return n ? (date.y = d3_time_expandYear(+n[0]), i + n[0].length) : -1;
}
function d3_time_parseZone(date, string, i) {
- return /^[+-]\d{4}$/.test(string = string.substring(i, i + 5)) ? (date.Z = -string,
+ return /^[+-]\d{4}$/.test(string = string.substring(i, i + 5)) ? (date.Z = -string,
i + 5) : -1;
}
function d3_time_expandYear(d) {
@@ -2882,7 +2883,7 @@
var λ00, φ00, λ0, cosφ0, sinφ0;
d3_geo_area.point = function(λ, φ) {
d3_geo_area.point = nextPoint;
- λ0 = (λ00 = λ) * d3_radians, cosφ0 = Math.cos(φ = (φ00 = φ) * d3_radians / 2 + π / 4),
+ λ0 = (λ00 = λ) * d3_radians, cosφ0 = Math.cos(φ = (φ00 = φ) * d3_radians / 2 + π / 4),
sinφ0 = Math.sin(φ);
};
function nextPoint(λ, φ) {
@@ -4711,7 +4712,7 @@
return _ ? center([ -_[1], _[0] ]) : (_ = center(), [ _[1], -_[0] ]);
};
projection.rotate = function(_) {
- return _ ? rotate([ _[0], _[1], _.length > 2 ? _[2] + 90 : 90 ]) : (_ = rotate(),
+ return _ ? rotate([ _[0], _[1], _.length > 2 ? _[2] + 90 : 90 ]) : (_ = rotate(),
[ _[0], _[1], _[2] - 90 ]);
};
return rotate([ 0, 0, 90 ]);
@@ -5562,7 +5563,7 @@
};
quadtree.extent = function(_) {
if (!arguments.length) return x1 == null ? null : [ [ x1, y1 ], [ x2, y2 ] ];
- if (_ == null) x1 = y1 = x2 = y2 = null; else x1 = +_[0][0], y1 = +_[0][1], x2 = +_[1][0],
+ if (_ == null) x1 = y1 = x2 = y2 = null; else x1 = +_[0][0], y1 = +_[0][1], x2 = +_[1][0],
y2 = +_[1][1];
return quadtree;
};
@@ -7228,7 +7229,7 @@
return d3_layout_treemapPad(node, x);
}
var type;
- pad = (padding = x) == null ? d3_layout_treemapPadNull : (type = typeof x) === "function" ? padFunction : type === "number" ? (x = [ x, x, x, x ],
+ pad = (padding = x) == null ? d3_layout_treemapPadNull : (type = typeof x) === "function" ? padFunction : type === "number" ? (x = [ x, x, x, x ],
padConstant) : padConstant;
return treemap;
};
@@ -7528,7 +7529,7 @@
scale.tickFormat = function(n, format) {
if (!arguments.length) return d3_scale_logFormat;
if (arguments.length < 2) format = d3_scale_logFormat; else if (typeof format !== "function") format = d3.format(format);
- var k = Math.max(.1, n / scale.ticks().length), f = positive ? (e = 1e-12, Math.ceil) : (e = -1e-12,
+ var k = Math.max(.1, n / scale.ticks().length), f = positive ? (e = 1e-12, Math.ceil) : (e = -1e-12,
Math.floor), e;
return function(d) {
return d / pow(f(log(d) + e)) <= k ? format(d) : "";
@@ -7814,7 +7815,7 @@
d3.svg.arc = function() {
var innerRadius = d3_svg_arcInnerRadius, outerRadius = d3_svg_arcOuterRadius, startAngle = d3_svg_arcStartAngle, endAngle = d3_svg_arcEndAngle;
function arc() {
- var r0 = innerRadius.apply(this, arguments), r1 = outerRadius.apply(this, arguments), a0 = startAngle.apply(this, arguments) + d3_svg_arcOffset, a1 = endAngle.apply(this, arguments) + d3_svg_arcOffset, da = (a1 < a0 && (da = a0,
+ var r0 = innerRadius.apply(this, arguments), r1 = outerRadius.apply(this, arguments), a0 = startAngle.apply(this, arguments) + d3_svg_arcOffset, a1 = endAngle.apply(this, arguments) + d3_svg_arcOffset, da = (a1 < a0 && (da = a0,
a0 = a1, a1 = da), a1 - a0), df = da < π ? "0" : "1", c0 = Math.cos(a0), s0 = Math.sin(a0), c1 = Math.cos(a1), s1 = Math.sin(a1);
return da >= d3_svg_arcMax ? r0 ? "M0," + r1 + "A" + r1 + "," + r1 + " 0 1,1 0," + -r1 + "A" + r1 + "," + r1 + " 0 1,1 0," + r1 + "M0," + r0 + "A" + r0 + "," + r0 + " 0 1,0 0," + -r0 + "A" + r0 + "," + r0 + " 0 1,0 0," + r0 + "Z" : "M0," + r1 + "A" + r1 + "," + r1 + " 0 1,1 0," + -r1 + "A" + r1 + "," + r1 + " 0 1,1 0," + r1 + "Z" : r0 ? "M" + r1 * c0 + "," + r1 * s0 + "A" + r1 + "," + r1 + " 0 " + df + ",1 " + r1 * c1 + "," + r1 * s1 + "L" + r0 * c1 + "," + r0 * s1 + "A" + r0 + "," + r0 + " 0 " + df + ",0 " + r0 * c0 + "," + r0 * s0 + "Z" : "M" + r1 * c0 + "," + r1 * s0 + "A" + r1 + "," + r1 + " 0 " + df + ",1 " + r1 * c1 + "," + r1 * s1 + "L0,0" + "Z";
}
@@ -7950,7 +7951,7 @@
return points.length < 4 ? d3_svg_lineLinear(points) : points[1] + d3_svg_lineHermite(points.slice(1, points.length - 1), d3_svg_lineCardinalTangents(points, tension));
}
function d3_svg_lineCardinalClosed(points, tension) {
- return points.length < 3 ? d3_svg_lineLinear(points) : points[0] + d3_svg_lineHermite((points.push(points[0]),
+ return points.length < 3 ? d3_svg_lineLinear(points) : points[0] + d3_svg_lineHermite((points.push(points[0]),
points), d3_svg_lineCardinalTangents([ points[points.length - 2] ].concat(points, [ points[1] ]), tension));
}
function d3_svg_lineCardinal(points, tension) {
@@ -8656,7 +8657,7 @@
var g = d3.select(this);
var scale0 = this.__chart__ || scale, scale1 = this.__chart__ = scale.copy();
var ticks = tickValues == null ? scale1.ticks ? scale1.ticks.apply(scale1, tickArguments_) : scale1.domain() : tickValues, tickFormat = tickFormat_ == null ? scale1.tickFormat ? scale1.tickFormat.apply(scale1, tickArguments_) : d3_identity : tickFormat_, tick = g.selectAll(".tick").data(ticks, scale1), tickEnter = tick.enter().insert("g", ".domain").attr("class", "tick").style("opacity", ε), tickExit = d3.transition(tick.exit()).style("opacity", ε).remove(), tickUpdate = d3.transition(tick.order()).style("opacity", 1), tickTransform;
- var range = d3_scaleRange(scale1), path = g.selectAll(".domain").data([ 0 ]), pathUpdate = (path.enter().append("path").attr("class", "domain"),
+ var range = d3_scaleRange(scale1), path = g.selectAll(".domain").data([ 0 ]), pathUpdate = (path.enter().append("path").attr("class", "domain"),
d3.transition(path));
tickEnter.append("line");
tickEnter.append("text");
@@ -9257,5 +9258,4 @@
return request.responseXML;
});
if (typeof define === "function" && define.amd) define(d3); else if (typeof module === "object" && module.exports) module.exports = d3;
- this.d3 = d3;
-}();
\ No newline at end of file
+}();
diff --git a/web/index.html b/web/index.html
index 42540da19..d8aaf28cc 100644
--- a/web/index.html
+++ b/web/index.html
@@ -103,16 +103,9 @@ Licensed under the NASA Open Source Agreement, Version 1.3 (http://opensource.gs
<!-- link.dev --> <link type="text/css" rel="Stylesheet" href="css/wv.mobile.css">
<link type="text/css" rel="Stylesheet" href="pages/css/wv.document.css">
- <!-- link.dev --> <script type="text/javascript" src="ext/main/jquery-2.1.4/jquery.js"></script>
- <!-- link.prod --> <!-- <script type="text/javascript" src="ext/main/jquery-2.1.4/jquery.min.js"></script> -->
- <!-- link.dev --> <script type="text/javascript" src="ext/tour/joyride-2.0.3-3/joyride.js"></script>
- <!-- link.prod --> <!-- <script type="text/javascript" src="ext/tour/joyride-2.0.3-3/joyride.min.js"></script> -->
<!-- link.dev --> <script type="text/javascript" src="ext/main/jscache-gitba01cdc/cache.js"></script>
<!-- link.prod --> <!-- <script type="text/javascript" src="ext/main/jscache-gitba01cdc/cache.min.js"></script> -->
- <!-- link.dev --> <script type="text/javascript" src="ext/ui/d3/d3.js"></script>
- <!-- link.prod --> <!-- <script type="text/javascript" src="ext/ui/d3/d3.min.js"></script> -->
-
<!-- link.dev --> <script type="text/javascript" src="build/wv.js"></script>
<!-- link.prod --> <!-- <script type="text/javascript" src="js/wv.min.js?v=@BUILD_NONCE@&mobile"></script> -->
diff --git a/web/js/date/wheels.js b/web/js/date/wheels.js
index 4010647b4..14bb8c084 100644
--- a/web/js/date/wheels.js
+++ b/web/js/date/wheels.js
@@ -1,4 +1,5 @@
import $ from 'jquery';
+import 'mobiscroll-jquery';
import util from '../util/util';
export function dateWheels(models, config) {
diff --git a/web/js/image/panel.js b/web/js/image/panel.js
index 794c1c754..e88bd1051 100644
--- a/web/js/image/panel.js
+++ b/web/js/image/panel.js
@@ -1,4 +1,6 @@
import $ from 'jquery';
+import 'jquery-ui/button';
+import 'jquery-ui/dialog';
import loEach from 'lodash/each';
import loIsUndefined from 'lodash/isUndefined';
import olProj from 'ol/proj';
diff --git a/web/js/image/rubberband.js b/web/js/image/rubberband.js
index 128b97c9e..ba8ff11e1 100644
--- a/web/js/image/rubberband.js
+++ b/web/js/image/rubberband.js
@@ -1,4 +1,5 @@
import $ from 'jquery';
+import 'jquery-ui/button';
import loFind from 'lodash/find';
import util from '../util/util';
import wvui from '../ui/ui';
diff --git a/web/js/layers/active.js b/web/js/layers/active.js
index 1dc22c7db..2e083e0a2 100644
--- a/web/js/layers/active.js
+++ b/web/js/layers/active.js
@@ -1,11 +1,16 @@
import $ from 'jquery';
+import 'jquery-ui/sortable';
+import 'jquery-ui/button';
+import 'jquery-ui/dialog';
+import 'perfect-scrollbar/jquery';
+import d3 from 'd3';
import loEach from 'lodash/each';
import loEachRight from 'lodash/eachRight';
import util from '../util/util';
import wvui from '../ui/ui';
import layersInfo from './info';
import layersOptions from './options';
-import palettesLegend from '../palettes/legend';
+import {palettesLegend} from '../palettes/legend';
export function layersActive(models, ui, config) {
var model = models.layers;
diff --git a/web/js/layers/add.js b/web/js/layers/add.js
index 7b31af206..0df4b496d 100644
--- a/web/js/layers/add.js
+++ b/web/js/layers/add.js
@@ -1,4 +1,6 @@
import $ from 'jquery';
+import 'icheck';
+import 'jscrollpane';
import loEach from 'lodash/each';
import loFind from 'lodash/find';
import loThrottle from 'lodash/throttle';
diff --git a/web/js/layers/info.js b/web/js/layers/info.js
index 77787483c..9818a92b1 100644
--- a/web/js/layers/info.js
+++ b/web/js/layers/info.js
@@ -1,4 +1,6 @@
import $ from 'jquery';
+import 'jquery-ui/dialog';
+import 'perfect-scrollbar/jquery';
import wvui from '../ui/ui';
export function layersInfo(config, models, layer) {
diff --git a/web/js/layers/modal.js b/web/js/layers/modal.js
index 469e126c8..fa12bf689 100644
--- a/web/js/layers/modal.js
+++ b/web/js/layers/modal.js
@@ -1,4 +1,11 @@
import $ from 'jquery';
+import 'jquery-ui/dialog';
+import 'jquery-ui/accordion';
+import 'jquery-ui/button';
+import 'jquery-ui/tabs';
+import 'icheck';
+import 'isotope-layout';
+import 'perfect-scrollbar/jquery';
import React from 'react';
import ReactDOM from 'react-dom';
import {LayerList} from 'worldview-components';
diff --git a/web/js/layers/options.js b/web/js/layers/options.js
index f98853de1..80fd53421 100644
--- a/web/js/layers/options.js
+++ b/web/js/layers/options.js
@@ -1,4 +1,9 @@
import $ from 'jquery';
+import 'jquery-ui/button';
+import 'jquery-ui/dialog';
+import 'icheck';
+import 'nouislider-browser/jquery.nouislider';
+import 'perfect-scrollbar/jquery';
import loEach from 'lodash/each';
import loIndexOf from 'lodash/indexOf';
import loIsEqual from 'lodash/isEqual';
diff --git a/web/js/layers/sidebar.js b/web/js/layers/sidebar.js
index 2ba62855b..56315406e 100644
--- a/web/js/layers/sidebar.js
+++ b/web/js/layers/sidebar.js
@@ -1,4 +1,7 @@
import $ from 'jquery';
+import 'jquery-ui/tabs';
+import 'jquery-ui/dialog';
+import 'perfect-scrollbar/jquery';
import util from '../util/util';
export function layersSidebar(models, config) {
diff --git a/web/js/link/ui.js b/web/js/link/ui.js
index a7a6568bf..3b109d7d6 100644
--- a/web/js/link/ui.js
+++ b/web/js/link/ui.js
@@ -1,4 +1,7 @@
import $ from 'jquery';
+import 'jquery-ui/button';
+import 'jquery-ui/dialog';
+import 'icheck';
import loThrottle from 'lodash/throttle';
import React from 'react';
import ReactDOM from 'react-dom';
diff --git a/web/js/main.js b/web/js/main.js
index fc5683715..f45b19f82 100644
--- a/web/js/main.js
+++ b/web/js/main.js
@@ -1,15 +1,5 @@
// External Dependencies
import $ from 'jquery';
-import 'jquery-ui';
-import 'jquery-migrate';
-import 'icheck';
-import 'jscrollpane';
-import 'mobiscroll';
-import 'jcrop';
-import 'nouislider';
-import 'jcarousel';
-import 'perfect-scrollbar-jquery';
-import 'isotope-jquery';
import loEach from 'lodash/each';
// import {GA as googleAnalytics} from 'worldview-components';
@@ -81,7 +71,7 @@ import {projectionChange} from './projection/change';
// Other
// import {debugConfig, debug} from './debug';
import Brand from './brand';
-// import tour from './tour';
+import tour from './tour';
import {uiInfo} from './ui/info';
import {polyfill} from './polyfill';
diff --git a/web/js/map/rotation.js b/web/js/map/rotation.js
index f9c0a0154..f06eabc01 100644
--- a/web/js/map/rotation.js
+++ b/web/js/map/rotation.js
@@ -1,4 +1,5 @@
import $ from 'jquery';
+import 'jquery-ui/button';
import util from '../util/util';
export function MapRotate(ui, models, map) {
diff --git a/web/js/map/ui.js b/web/js/map/ui.js
index 6f7aacc62..639295f87 100644
--- a/web/js/map/ui.js
+++ b/web/js/map/ui.js
@@ -1,4 +1,5 @@
import $ from 'jquery';
+import 'jquery-ui/button';
import loFindIndex from 'lodash/findIndex';
import loEach from 'lodash/each';
import loForOwn from 'lodash/forOwn';
diff --git a/web/js/projection/ui.js b/web/js/projection/ui.js
index 120b5e113..b1e91e984 100644
--- a/web/js/projection/ui.js
+++ b/web/js/projection/ui.js
@@ -1,4 +1,6 @@
import $ from 'jquery';
+import 'jquery-ui/button';
+import 'jquery-ui/menu';
import loEach from 'lodash/each';
import wvui from '../ui/ui';
diff --git a/web/js/wv.tour.js b/web/js/tour.js
similarity index 83%
rename from web/js/wv.tour.js
rename to web/js/tour.js
index 7224bc231..87621fb60 100644
--- a/web/js/wv.tour.js
+++ b/web/js/tour.js
@@ -1,11 +1,13 @@
-var wv = wv || {};
-
-wv.tour = wv.tour || function (models, ui, config) {
+import $ from 'jquery';
+import 'jquery.joyride';
+import util from './util/util';
+import wvui from './ui/ui';
+import {GA} from 'worldview-components';
+import feedbackModal from './feedback';
+
+export default function (models, ui, config) {
var self = {};
- var conclusionPanel = null;
- var splashOverlay = null;
-
var init = function () {
$('#wv-tour')
.click(function () {
@@ -25,12 +27,12 @@ wv.tour = wv.tour || function (models, ui, config) {
}
// Tour does not work on IE 9 or below
- if (wv.util.browser.ie && wv.util.browser.version <= 9) {
+ if (util.browser.ie && util.browser.version <= 9) {
return;
}
// Don't annoy with the tour if they cannot opt out in the future
- if (!wv.util.browser.localStorage) {
+ if (!util.browser.localStorage) {
return;
}
@@ -51,17 +53,17 @@ wv.tour = wv.tour || function (models, ui, config) {
* Create the splash screen and tour panels and control iteration over them.
*/
self.start = function (introduction) {
- if (wv.util.browser.ie && wv.util.browser.version <= 9) {
- wv.ui.unsupported('tour');
+ if (util.browser.ie && util.browser.version <= 9) {
+ wvui.unsupported('tour');
return;
}
if (!validScreenSize()) {
- wv.ui.notify('Unfortunately the @NAME@ tour can only be viewed in larger web browser windows.');
+ wvui.notify('Unfortunately the @NAME@ tour can only be viewed in larger web browser windows.');
return;
}
- $content = $('#wv-tour-content');
+ var $content = $('#wv-tour-content');
if ($content.children()
.length === 0) {
$content.load('pages/tour.html', function () {
@@ -73,10 +75,7 @@ wv.tour = wv.tour || function (models, ui, config) {
};
var onLoad = function (introduction) {
- var padding = 15; // padding - used for all of the tour windows
- var pos, width, height, xval, yval; // helpful calculation vars
-
- wv.ui.close();
+ wvui.close();
var $startDialog = $('#wv-tour-intro');
$startDialog
.dialog({
@@ -108,8 +107,8 @@ wv.tour = wv.tour || function (models, ui, config) {
}
var endTour = function () {
- wv.ui.close();
- $dialog = $('#wv-tour-end');
+ wvui.close();
+ var $dialog = $('#wv-tour-end');
$dialog
.dialog({
title: 'Finished!',
@@ -120,7 +119,7 @@ wv.tour = wv.tour || function (models, ui, config) {
draggable: false,
resizable: false
});
- wv.feedback.decorate($dialog.find('.feedback'));
+ feedbackModal.decorate($dialog.find('.feedback'));
$('#repeat')
.click(repeatTour);
$('#done')
@@ -143,7 +142,7 @@ wv.tour = wv.tour || function (models, ui, config) {
'link': '<a href="#" class="joyride-close-tip">X</a>'
},
postStepCallback: function (index, tip) {
- if (index == 5) {
+ if (index === 5) {
endTour();
}
}
@@ -170,8 +169,8 @@ wv.tour = wv.tour || function (models, ui, config) {
var onStop = function (index, tip, button) {
// console.log(index, tip, button);
setTourState();
- WVC.GA.event('Tour', 'Click', 'Post Tour View', index + 1);
- if (index == 5 && button !== 'previous') {
+ GA.event('Tour', 'Click', 'Post Tour View', index + 1);
+ if (index === 5 && button !== 'previous') {
endTour();
}
};
@@ -184,7 +183,7 @@ wv.tour = wv.tour || function (models, ui, config) {
$('.ui-dialog-content')
.dialog('close');
initTourState();
- WVC.GA.event('Tour', 'Click', 'Take Tour');
+ GA.event('Tour', 'Click', 'Take Tour');
$('#joyRideTipContent')
.joyride({
adjustForPhone: false,
@@ -201,7 +200,7 @@ wv.tour = wv.tour || function (models, ui, config) {
* Toggle the value of the "hideSplash" flag.
*/
var setDoNotShow = function () {
- if (!wv.util.browser.localStorage) return;
+ if (!util.browser.localStorage) return;
var hideSplash = localStorage.getItem('hideSplash');
localStorage.setItem('hideSplash', !hideSplash);
};
@@ -218,7 +217,7 @@ wv.tour = wv.tour || function (models, ui, config) {
var initTourState = function () {
var map = ui.map.selected;
models.proj.selectDefault();
- models.date.select(wv.util.today());
+ models.date.select(util.today());
models.layers.reset();
var leading = models.map.getLeadingExtent();
map.getView()
diff --git a/web/js/ui/info.js b/web/js/ui/info.js
index 0a49cdbcf..875298d7b 100644
--- a/web/js/ui/info.js
+++ b/web/js/ui/info.js
@@ -1,4 +1,7 @@
import $ from 'jquery';
+import 'jquery-ui/button';
+import 'jquery-ui/dialog';
+import 'jquery-ui/menu';
import wvui from './ui';
import util from '../util/util';
import feedbackModal from '../feedback';
diff --git a/web/js/ui/ui.js b/web/js/ui/ui.js
index c052e7e52..4de869ade 100644
--- a/web/js/ui/ui.js
+++ b/web/js/ui/ui.js
@@ -1,4 +1,6 @@
import $ from 'jquery';
+import 'jquery-ui/dialog';
+import 'jquery-ui/menu';
import loadingIndicator from './indicator';
import info from './info';
import mouse from './mouse';