From 192eeaa7587bf0867eefda6817cf3714c9abc6af Mon Sep 17 00:00:00 2001 From: joewdavies Date: Thu, 23 Jan 2025 09:17:17 +0100 Subject: [PATCH] update examples --- examples/CCM/index.html | 1648 ++++------------- examples/basic.html | 2 +- examples/population-change.html | 2 +- examples/population-density.html | 2 +- examples/population-dot-density.html | 2 +- examples/small_multiple.html | 2 +- examples/world.html | 2 +- test/IMAGE/dot_density.html | 4 +- test/jest/choropleth.test.js | 2 +- test/jest/export.test.js | 2 +- test/jest/legend.test.js | 2 +- test/jest/progstat.test.js | 2 +- .../patterned-choropleth/test_dd.html | 4 +- test/test_deprecated.html | 2 +- test/test_insets.html | 10 +- test/test_legend_out.html | 4 +- test/test_mix_NUTS.html | 4 +- test/test_progstat.html | 4 +- test/test_scalebar.html | 2 +- test/test_tooltip.html | 4 +- 20 files changed, 393 insertions(+), 1313 deletions(-) diff --git a/examples/CCM/index.html b/examples/CCM/index.html index f50f37da..1649f490 100644 --- a/examples/CCM/index.html +++ b/examples/CCM/index.html @@ -325,54 +325,12 @@ % change - - - - - - + + + + + + ≥ -20 -25 – < -20 @@ -390,9 +348,7 @@ fill="#b2b2b2" style="stroke: rgb(0, 0, 0); stroke-width: 0.4px; display: none" > - + @@ -432,36 +388,15 @@ style="display: inherit" > - + - + - + @@ -515,8 +450,7 @@ 'use strict' var t = { d: function (e, n) { - for (var r in n) - t.o(n, r) && !t.o(e, r) && Object.defineProperty(e, r, { enumerable: !0, get: n[r] }) + for (var r in n) t.o(n, r) && !t.o(e, r) && Object.defineProperty(e, r, { enumerable: !0, get: n[r] }) }, o: function (t, e) { return Object.prototype.hasOwnProperty.call(t, e) @@ -540,8 +474,7 @@ if (Array.isArray(t)) return n(t) })(t) || (function (t) { - if (('undefined' != typeof Symbol && null != t[Symbol.iterator]) || null != t['@@iterator']) - return Array.from(t) + if (('undefined' != typeof Symbol && null != t[Symbol.iterator]) || null != t['@@iterator']) return Array.from(t) })(t) || (function (t, e) { if (t) { @@ -635,8 +568,7 @@ f = e.length, p = a.length, h = new Array(f) - for (s = 0; s < f; ++s) - (l = e[s]) && ((h[s] = u = o.call(l, l.__data__, s, e) + ''), c.has(u) ? (i[s] = l) : c.set(u, l)) + for (s = 0; s < f; ++s) (l = e[s]) && ((h[s] = u = o.call(l, l.__data__, s, e) + ''), c.has(u) ? (i[s] = l) : c.set(u, l)) for (s = 0; s < p; ++s) (u = o.call(t, a[s], s, a) + ''), (l = c.get(u)) ? ((r[s] = l), (l.__data__ = a[s]), c.delete(u)) : (n[s] = new _(t, a[s])) @@ -677,10 +609,7 @@ function T(t) { var e = (t += ''), n = e.indexOf(':') - return ( - n >= 0 && 'xmlns' !== (e = t.slice(0, n)) && (t = t.slice(n + 1)), - w.hasOwnProperty(e) ? { space: w[e], local: t } : t - ) + return n >= 0 && 'xmlns' !== (e = t.slice(0, n)) && (t = t.slice(n + 1)), w.hasOwnProperty(e) ? { space: w[e], local: t } : t } function z(t) { return function () { @@ -905,8 +834,7 @@ } H.prototype = { add: function (t) { - this._names.indexOf(t) < 0 && - (this._names.push(t), this._node.setAttribute('class', this._names.join(' '))) + this._names.indexOf(t) < 0 && (this._names.push(t), this._node.setAttribute('class', this._names.join(' '))) }, remove: function (t) { var e = this._names.indexOf(t) @@ -929,9 +857,7 @@ 'function' != typeof t && (t = a(t)) for (var e = this._groups, n = e.length, r = new Array(n), i = 0; i < n; ++i) for (var o, s, l = e[i], u = l.length, c = (r[i] = new Array(u)), f = 0; f < u; ++f) - (o = l[f]) && - (s = t.call(o, o.__data__, f, l)) && - ('__data__' in o && (s.__data__ = o.__data__), (c[f] = s)) + (o = l[f]) && (s = t.call(o, o.__data__, f, l)) && ('__data__' in o && (s.__data__ = o.__data__), (c[f] = s)) return new dt(r, this._parents) }, selectAll: function (t) { @@ -944,8 +870,7 @@ })(t) : l(t) for (var e = this._groups, n = e.length, r = [], i = [], a = 0; a < n; ++a) - for (var s, u = e[a], c = u.length, f = 0; f < c; ++f) - (s = u[f]) && (r.push(t.call(s, s.__data__, f, u)), i.push(s)) + for (var s, u = e[a], c = u.length, f = 0; f < c; ++f) (s = u[f]) && (r.push(t.call(s, s.__data__, f, u)), i.push(s)) return new dt(r, i) }, selectChild: function (t) { @@ -1046,8 +971,7 @@ order: function () { for (var t = this._groups, e = -1, n = t.length; ++e < n; ) for (var r, i = t[e], a = i.length - 1, o = i[a]; --a >= 0; ) - (r = i[a]) && - (o && 4 ^ r.compareDocumentPosition(o) && o.parentNode.insertBefore(r, o), (o = r)) + (r = i[a]) && (o && 4 ^ r.compareDocumentPosition(o) && o.parentNode.insertBefore(r, o), (o = r)) return this }, sort: function (t) { @@ -1056,8 +980,7 @@ } t || (t = b) for (var n = this._groups, r = n.length, i = new Array(r), a = 0; a < r; ++a) { - for (var o, s = n[a], l = s.length, u = (i[a] = new Array(l)), c = 0; c < l; ++c) - (o = s[c]) && (u[c] = o) + for (var o, s = n[a], l = s.length, u = (i[a] = new Array(l)), c = 0; c < l; ++c) (o = s[c]) && (u[c] = o) u.sort(e) } return new dt(i, this._parents).order() @@ -1096,12 +1019,7 @@ var r = this.node() return n.local ? r.getAttributeNS(n.space, n.local) : r.getAttribute(n) } - return this.each( - (null == e ? (n.local ? k : z) : 'function' == typeof e ? (n.local ? M : L) : n.local ? A : F)( - n, - e - ) - ) + return this.each((null == e ? (n.local ? k : z) : 'function' == typeof e ? (n.local ? M : L) : n.local ? A : F)(n, e)) }, style: function (t, e, n) { return arguments.length > 1 @@ -1109,9 +1027,7 @@ : N(this.node(), t) }, property: function (t, e) { - return arguments.length > 1 - ? this.each((null == e ? I : 'function' == typeof e ? P : R)(t, e)) - : this.node()[t] + return arguments.length > 1 ? this.each((null == e ? I : 'function' == typeof e ? P : R)(t, e)) : this.node()[t] }, classed: function (t, e) { var n = W(t + '') @@ -1122,14 +1038,10 @@ return this.each(('function' == typeof e ? V : e ? $ : G)(n, e)) }, text: function (t) { - return arguments.length - ? this.each(null == t ? q : ('function' == typeof t ? X : Y)(t)) - : this.node().textContent + return arguments.length ? this.each(null == t ? q : ('function' == typeof t ? X : Y)(t)) : this.node().textContent }, html: function (t) { - return arguments.length - ? this.each(null == t ? K : ('function' == typeof t ? Z : J)(t)) - : this.node().innerHTML + return arguments.length ? this.each(null == t ? K : ('function' == typeof t ? Z : J)(t)) : this.node().innerHTML }, raise: function () { return this.each(Q) @@ -1180,8 +1092,7 @@ var s = this.node().__on if (s) for (var l, u = 0, c = s.length; u < c; ++u) - for (r = 0, l = s[u]; r < o; ++r) - if ((i = a[r]).type === l.type && i.name === l.name) return l.value + for (r = 0, l = s[u]; r < o; ++r) if ((i = a[r]).type === l.type && i.name === l.name) return l.value }, dispatch: function (t, e) { return this.each(('function' == typeof e ? pt : ft)(t, e)) @@ -1193,9 +1104,7 @@ } var _t = gt function yt(t) { - return 'string' == typeof t - ? new dt([[document.querySelector(t)]], [document.documentElement]) - : new dt([[t]], ht) + return 'string' == typeof t ? new dt([[document.querySelector(t)]], [document.documentElement]) : new dt([[t]], ht) } function vt(t, e) { return t < e ? -1 : t > e ? 1 : t >= e ? 0 : NaN @@ -1214,12 +1123,10 @@ i = t.length, a = -1 if (null == e) { - for (; ++a < i; ) - if (null != (n = t[a]) && n >= n) for (r = n; ++a < i; ) null != (n = t[a]) && n > r && (r = n) + for (; ++a < i; ) if (null != (n = t[a]) && n >= n) for (r = n; ++a < i; ) null != (n = t[a]) && n > r && (r = n) } else for (; ++a < i; ) - if (null != (n = e(t[a], a, t)) && n >= n) - for (r = n; ++a < i; ) null != (n = e(t[a], a, t)) && n > r && (r = n) + if (null != (n = e(t[a], a, t)) && n >= n) for (r = n; ++a < i; ) null != (n = e(t[a], a, t)) && n > r && (r = n) return r } function wt(t) { @@ -1233,18 +1140,15 @@ i = t.length, a = -1 if (null == e) { - for (; ++a < i; ) - if (null != (n = t[a]) && n >= n) for (r = n; ++a < i; ) null != (n = t[a]) && r > n && (r = n) + for (; ++a < i; ) if (null != (n = t[a]) && n >= n) for (r = n; ++a < i; ) null != (n = t[a]) && r > n && (r = n) } else for (; ++a < i; ) - if (null != (n = e(t[a], a, t)) && n >= n) - for (r = n; ++a < i; ) null != (n = e(t[a], a, t)) && r > n && (r = n) + if (null != (n = e(t[a], a, t)) && n >= n) for (r = n; ++a < i; ) null != (n = e(t[a], a, t)) && r > n && (r = n) return r } function zt(t, e, n) { ;(t = +t), (e = +e), (n = (i = arguments.length) < 2 ? ((e = t), (t = 0), 1) : i < 3 ? 1 : +n) - for (var r = -1, i = 0 | Math.max(0, Math.ceil((e - t) / n)), a = new Array(i); ++r < i; ) - a[r] = t + r * n + for (var r = -1, i = 0 | Math.max(0, Math.ceil((e - t) / n)), a = new Array(i); ++r < i; ) a[r] = t + r * n return a } function kt(t) { @@ -1379,11 +1283,7 @@ s / u < t && ++s, l / u > e && --l, (u = -u)) - : ((u = Math.pow(10, i) * o), - (s = Math.round(t / u)), - (l = Math.round(e / u)), - s * u < t && ++s, - l * u > e && --l), + : ((u = Math.pow(10, i) * o), (s = Math.round(t / u)), (l = Math.round(e / u)), s * u < t && ++s, l * u > e && --l), l < s && 0.5 <= n && n < 2 ? jt(t, e, 2 * n) : [s, l, u] ) } @@ -1577,12 +1477,7 @@ 6 === n ? se(e) : 3 === n - ? new ce( - ((e >> 8) & 15) | ((e >> 4) & 240), - ((e >> 4) & 15) | (240 & e), - ((15 & e) << 4) | (15 & e), - 1 - ) + ? new ce(((e >> 8) & 15) | ((e >> 4) & 240), ((e >> 4) & 15) | (240 & e), ((15 & e) << 4) | (15 & e), 1) : 8 === n ? le((e >> 24) & 255, (e >> 16) & 255, (e >> 8) & 255, (255 & e) / 255) : 4 === n @@ -1632,9 +1527,7 @@ } function pe() { const t = he(this.opacity) - return `${ - 1 === t ? 'rgb(' : 'rgba(' - }${de(this.r)}, ${de(this.g)}, ${de(this.b)}${1 === t ? ')' : `, ${t})`}` + return `${1 === t ? 'rgb(' : 'rgba('}${de(this.r)}, ${de(this.g)}, ${de(this.b)}${1 === t ? ')' : `, ${t})`}` } function he(t) { return isNaN(t) ? 1 : Math.max(0, Math.min(1, t)) @@ -1646,10 +1539,7 @@ return ((t = de(t)) < 16 ? '0' : '') + t.toString(16) } function _e(t, e, n, r) { - return ( - r <= 0 ? (t = e = n = NaN) : n <= 0 || n >= 1 ? (t = e = NaN) : e <= 0 && (t = NaN), - new ve(t, e, n, r) - ) + return r <= 0 ? (t = e = n = NaN) : n <= 0 || n >= 1 ? (t = e = NaN) : e <= 0 && (t = NaN), new ve(t, e, n, r) } function ye(t) { if (t instanceof ve) return new ve(t.h, t.s, t.l, t.opacity) @@ -1682,16 +1572,12 @@ return Math.max(0, Math.min(1, t || 0)) } function be(t, e, n) { - return ( - 255 * (t < 60 ? e + ((n - e) * t) / 60 : t < 180 ? n : t < 240 ? e + ((n - e) * (240 - t)) / 60 : e) - ) + return 255 * (t < 60 ? e + ((n - e) * t) / 60 : t < 180 ? n : t < 240 ? e + ((n - e) * (240 - t)) / 60 : e) } function Se(t, e, n, r, i) { var a = t * t, o = a * t - return ( - ((1 - 3 * t + 3 * a - o) * e + (4 - 6 * a + 3 * o) * n + (1 + 3 * t + 3 * a - 3 * o) * r + o * i) / 6 - ) + return ((1 - 3 * t + 3 * a - o) * e + (4 - 6 * a + 3 * o) * n + (1 + 3 * t + 3 * a - 3 * o) * r + o * i) / 6 } Bt($t, oe, { copy(t) { @@ -1716,16 +1602,10 @@ ue, Ut($t, { brighter(t) { - return ( - (t = null == t ? Vt : Math.pow(Vt, t)), - new ce(this.r * t, this.g * t, this.b * t, this.opacity) - ) + return (t = null == t ? Vt : Math.pow(Vt, t)), new ce(this.r * t, this.g * t, this.b * t, this.opacity) }, darker(t) { - return ( - (t = null == t ? Gt : Math.pow(Gt, t)), - new ce(this.r * t, this.g * t, this.b * t, this.opacity) - ) + return (t = null == t ? Gt : Math.pow(Gt, t)), new ce(this.r * t, this.g * t, this.b * t, this.opacity) }, rgb() { return this @@ -1748,9 +1628,7 @@ hex: fe, formatHex: fe, formatHex8: function () { - return `#${ge(this.r)}${ge(this.g)}${ge(this.b)}${ge( - 255 * (isNaN(this.opacity) ? 1 : this.opacity) - )}` + return `#${ge(this.r)}${ge(this.g)}${ge(this.b)}${ge(255 * (isNaN(this.opacity) ? 1 : this.opacity))}` }, formatRgb: pe, toString: pe, @@ -1763,14 +1641,10 @@ }, Ut($t, { brighter(t) { - return ( - (t = null == t ? Vt : Math.pow(Vt, t)), new ve(this.h, this.s, this.l * t, this.opacity) - ) + return (t = null == t ? Vt : Math.pow(Vt, t)), new ve(this.h, this.s, this.l * t, this.opacity) }, darker(t) { - return ( - (t = null == t ? Gt : Math.pow(Gt, t)), new ve(this.h, this.s, this.l * t, this.opacity) - ) + return (t = null == t ? Gt : Math.pow(Gt, t)), new ve(this.h, this.s, this.l * t, this.opacity) }, rgb() { var t = (this.h % 360) + 360 * (this.h < 0), @@ -1913,9 +1787,7 @@ var n, r = {}, i = {} - for (n in ((null !== t && 'object' == typeof t) || (t = {}), - (null !== e && 'object' == typeof e) || (e = {}), - e)) + for (n in ((null !== t && 'object' == typeof t) || (t = {}), (null !== e && 'object' == typeof e) || (e = {}), e)) n in t ? (r[n] = Ie(t[n], e[n])) : (i[n] = e[n]) return function (t) { for (n in r) i[n] = r[n](t) @@ -1945,11 +1817,7 @@ l = [] for (t += '', e += ''; (n = Ee.exec(t)) && (r = De.exec(e)); ) (i = r.index) > a && ((i = e.slice(a, i)), s[o] ? (s[o] += i) : (s[++o] = i)), - (n = n[0]) === (r = r[0]) - ? s[o] - ? (s[o] += r) - : (s[++o] = r) - : ((s[++o] = null), l.push({ i: o, x: Me(n, r) })), + (n = n[0]) === (r = r[0]) ? (s[o] ? (s[o] += r) : (s[++o] = r)) : ((s[++o] = null), l.push({ i: o, x: Me(n, r) })), (a = De.lastIndex) return ( a < e.length && ((i = e.slice(a)), s[o] ? (s[o] += i) : (s[++o] = i)), @@ -2002,8 +1870,7 @@ !ArrayBuffer.isView(r) || r instanceof DataView ? Array.isArray(e) ? Ae - : ('function' != typeof e.valueOf && 'function' != typeof e.toString) || - isNaN(e) + : ('function' != typeof e.valueOf && 'function' != typeof e.toString) || isNaN(e) ? Ce : Me : Ne))(t, e) @@ -2060,12 +1927,7 @@ } } function $e(t, e) { - return e - .domain(t.domain()) - .range(t.range()) - .interpolate(t.interpolate()) - .clamp(t.clamp()) - .unknown(t.unknown()) + return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown()) } function Ge() { var t, @@ -2196,9 +2058,7 @@ b: (t) => Math.round(t).toString(2), c: (t) => t + '', d: function (t) { - return Math.abs((t = Math.round(t))) >= 1e21 - ? t.toLocaleString('en').replace(/,/g, '') - : t.toString(10) + return Math.abs((t = Math.round(t))) >= 1e21 ? t.toLocaleString('en').replace(/,/g, '') : t.toString(10) }, e: (t, e) => t.toExponential(e), f: (t, e) => t.toFixed(e), @@ -2322,8 +2182,7 @@ ) for (i = -1, a = t.length; ++i < a; ) if (48 > (l = t.charCodeAt(i)) || l > 57) { - ;(w = (46 === l ? o + t.slice(i + 1) : t.slice(i)) + w), - (t = t.slice(0, i)) + ;(w = (46 === l ? o + t.slice(i + 1) : t.slice(i)) + w), (t = t.slice(0, i)) break } } @@ -2346,12 +2205,7 @@ return s(t) } return ( - (_ = - void 0 === _ - ? 6 - : /[gprs]/.test(v) - ? Math.max(1, Math.min(21, _)) - : Math.max(0, Math.min(20, _))), + (_ = void 0 === _ ? 6 : /[gprs]/.test(v) ? Math.max(1, Math.min(21, _)) : Math.max(0, Math.min(20, _))), (w.toString = function () { return t + '' }), @@ -2414,11 +2268,7 @@ null != r.precision || isNaN( (i = (function (t, e) { - return Math.max( - 0, - 3 * Math.max(-8, Math.min(8, Math.floor(Je(e) / 3))) - - Je(Math.abs(t)) - ) + return Math.max(0, 3 * Math.max(-8, Math.min(8, Math.floor(Je(e) / 3))) - Je(Math.abs(t))) })(a, o)) ) || (r.precision = i), @@ -2432,11 +2282,7 @@ null != r.precision || isNaN( (i = (function (t, e) { - return ( - (t = Math.abs(t)), - (e = Math.abs(e) - t), - Math.max(0, Je(e) - Je(t)) + 1 - ) + return (t = Math.abs(t)), (e = Math.abs(e) - t), Math.max(0, Je(e) - Je(t)) + 1 })(a, Math.max(Math.abs(t), Math.abs(e)))) ) || (r.precision = i - ('e' === r.type)) @@ -2536,14 +2382,10 @@ } return ( (i.domain = function (t) { - return arguments.length - ? ((e = Array.from(t)), (r = Math.min(e.length, n.length - 1)), i) - : e.slice() + return arguments.length ? ((e = Array.from(t)), (r = Math.min(e.length, n.length - 1)), i) : e.slice() }), (i.range = function (t) { - return arguments.length - ? ((n = Array.from(t)), (r = Math.min(e.length, n.length - 1)), i) - : n.slice() + return arguments.length ? ((n = Array.from(t)), (r = Math.min(e.length, n.length - 1)), i) : n.slice() }), (i.invertExtent = function (t) { var r = n.indexOf(t) @@ -2591,12 +2433,7 @@ z: 'not applicable', } function _n(t, e, n) { - return ( - e in t - ? Object.defineProperty(t, e, { value: n, enumerable: !0, configurable: !0, writable: !0 }) - : (t[e] = n), - t - ) + return e in t ? Object.defineProperty(t, e, { value: n, enumerable: !0, configurable: !0, writable: !0 }) : (t[e] = n), t } function yn(t) { return ( @@ -2606,10 +2443,7 @@ return typeof t } : function (t) { - return t && - 'function' == typeof Symbol && - t.constructor === Symbol && - t !== Symbol.prototype + return t && 'function' == typeof Symbol && t.constructor === Symbol && t !== Symbol.prototype ? 'symbol' : typeof t }), @@ -2659,9 +2493,7 @@ .map(function (t) { var e = '', n = t.indexOf('.') - if ( - (n >= 0 && ((e = t.slice(n + 1)), (t = t.slice(0, n))), t && !r.hasOwnProperty(t)) - ) + if ((n >= 0 && ((e = t.slice(n + 1)), (t = t.slice(0, n))), t && !r.hasOwnProperty(t))) throw new Error('unknown type: ' + t) return { type: t, name: e } })), @@ -2683,8 +2515,7 @@ return new Sn(t) }, call: function (t, e) { - if ((n = arguments.length - 2) > 0) - for (var n, r, i = new Array(n), a = 0; a < n; ++a) i[a] = arguments[a + 2] + if ((n = arguments.length - 2) > 0) for (var n, r, i = new Array(n), a = 0; a < n; ++a) i[a] = arguments[a + 2] if (!this._.hasOwnProperty(t)) throw new Error('unknown type: ' + t) for (a = 0, n = (r = this._[t]).length; a < n; ++a) r[a].value.apply(e, i) }, @@ -2763,11 +2594,7 @@ var n = e.ownerSVGElement || e if (n.createSVGPoint) { var r = n.createSVGPoint() - return ( - (r.x = t.clientX), - (r.y = t.clientY), - [(r = r.matrixTransform(e.getScreenCTM().inverse())).x, r.y] - ) + return (r.x = t.clientX), (r.y = t.clientY), [(r = r.matrixTransform(e.getScreenCTM().inverse())).x, r.y] } if (e.getBoundingClientRect) { var i = e.getBoundingClientRect() @@ -2881,15 +2708,9 @@ if ((p = i[u]).name === n.name) { if (3 === p.state) return Yn(a) 4 === p.state - ? ((p.state = 6), - p.timer.stop(), - p.on.call('interrupt', t, t.__data__, p.index, p.group), - delete i[u]) + ? ((p.state = 6), p.timer.stop(), p.on.call('interrupt', t, t.__data__, p.index, p.group), delete i[u]) : +u < e && - ((p.state = 6), - p.timer.stop(), - p.on.call('cancel', t, t.__data__, p.index, p.group), - delete i[u]) + ((p.state = 6), p.timer.stop(), p.on.call('cancel', t, t.__data__, p.index, p.group), delete i[u]) } if ( (Yn(function () { @@ -2906,10 +2727,7 @@ } function o(e) { for ( - var i = - e < n.duration - ? n.ease.call(null, e / n.duration) - : (n.timer.restart(s), (n.state = 5), 1), + var i = e < n.duration ? n.ease.call(null, e / n.duration) : (n.timer.restart(s), (n.state = 5), 1), a = -1, o = r.length; ++a < o; @@ -3020,9 +2838,7 @@ : e && n.push(i(n) + 'rotate(' + e + r) })(a.rotate, o.rotate, s, l), (function (t, e, n, a) { - t !== e - ? a.push({ i: n.push(i(n) + 'skewX(', null, r) - 2, x: Me(t, e) }) - : e && n.push(i(n) + 'skewX(' + e + r) + t !== e ? a.push({ i: n.push(i(n) + 'skewX(', null, r) - 2, x: Me(t, e) }) : e && n.push(i(n) + 'skewX(' + e + r) })(a.skewX, o.skewX, s, l), (function (t, e, n, r, a, o) { if (t !== n || e !== r) { @@ -3053,9 +2869,7 @@ ? ir : (nr || (nr = document.createElementNS('http://www.w3.org/2000/svg', 'g')), nr.setAttribute('transform', t), - (t = nr.transform.baseVal.consolidate()) - ? ar((t = t.matrix).a, t.b, t.c, t.d, t.e, t.f) - : ir) + (t = nr.transform.baseVal.consolidate()) ? ar((t = t.matrix).a, t.b, t.c, t.d, t.e, t.f) : ir) }, ', ', ')', @@ -3144,11 +2958,7 @@ s, l = n(this) if (null != l) - return (o = this.getAttribute(t)) === (s = l + '') - ? null - : o === r && s === i - ? a - : ((i = s), (a = e((r = o), l))) + return (o = this.getAttribute(t)) === (s = l + '') ? null : o === r && s === i ? a : ((i = s), (a = e((r = o), l))) this.removeAttribute(t) } } @@ -3265,11 +3075,7 @@ for (var r = this._groups, i = r.length, a = [], o = [], s = 0; s < i; ++s) for (var u, c = r[s], f = c.length, p = 0; p < f; ++p) if ((u = c[p])) { - for ( - var h, d = t.call(u, u.__data__, p, c), g = tr(u, n), _ = 0, y = d.length; - _ < y; - ++_ - ) + for (var h, d = t.call(u, u.__data__, p, c), g = tr(u, n), _ = 0, y = d.length; _ < y; ++_) (h = d[_]) && Jn(h, e, n, _, d, g) a.push(d), o.push(u) } @@ -3287,13 +3093,7 @@ merge: function (t) { if (t._id !== this._id) throw new Error() for ( - var e = this._groups, - n = t._groups, - r = e.length, - i = n.length, - a = Math.min(r, i), - o = new Array(r), - s = 0; + var e = this._groups, n = t._groups, r = e.length, i = n.length, a = Math.min(r, i), o = new Array(r), s = 0; s < a; ++s ) @@ -3517,23 +3317,18 @@ tween: function (t, e) { var n = this._id if (((t += ''), arguments.length < 2)) { - for (var r, i = tr(this.node(), n).tween, a = 0, o = i.length; a < o; ++a) - if ((r = i[a]).name === t) return r.value + for (var r, i = tr(this.node(), n).tween, a = 0, o = i.length; a < o; ++a) if ((r = i[a]).name === t) return r.value return null } return this.each((null == e ? ur : cr)(n, t, e)) }, delay: function (t) { var e = this._id - return arguments.length - ? this.each(('function' == typeof t ? br : Sr)(e, t)) - : tr(this.node(), e).delay + return arguments.length ? this.each(('function' == typeof t ? br : Sr)(e, t)) : tr(this.node(), e).delay }, duration: function (t) { var e = this._id - return arguments.length - ? this.each(('function' == typeof t ? wr : Tr)(e, t)) - : tr(this.node(), e).duration + return arguments.length ? this.each(('function' == typeof t ? wr : Tr)(e, t)) : tr(this.node(), e).duration }, ease: function (t) { var e = this._id @@ -3576,8 +3371,7 @@ n.each(function () { var n = Qn(this, r), i = n.on - i !== t && ((e = (t = i).copy())._.cancel.push(s), e._.interrupt.push(s), e._.end.push(l)), - (n.on = e) + i !== t && ((e = (t = i).copy())._.cancel.push(s), e._.interrupt.push(s), e._.end.push(l)), (n.on = e) }), 0 === i && a() }) @@ -3593,8 +3387,7 @@ }, } function Er(t, e) { - for (var n; !(n = t.__transition) || !(n = n[e]); ) - if (!(t = t.parentNode)) throw new Error(`transition ${e} not found`) + for (var n; !(n = t.__transition) || !(n = n[e]); ) if (!(t = t.parentNode)) throw new Error(`transition ${e} not found`) return n } ;(_t.prototype.interrupt = function (t) { @@ -3604,12 +3397,9 @@ }), (_t.prototype.transition = function (t) { var e, n - t instanceof Ar - ? ((e = t._id), (t = t._name)) - : ((e = Lr()), ((n = Cr).time = Hn()), (t = null == t ? null : t + '')) + t instanceof Ar ? ((e = t._id), (t = t._name)) : ((e = Lr()), ((n = Cr).time = Hn()), (t = null == t ? null : t + '')) for (var r = this._groups, i = r.length, a = 0; a < i; ++a) - for (var o, s = r[a], l = s.length, u = 0; u < l; ++u) - (o = s[u]) && Jn(o, t, e, u, s, n || Er(o, e)) + for (var o, s = r[a], l = s.length, u = 0; u < l; ++u) (o = s[u]) && Jn(o, t, e, u, s, n || Er(o, e)) return new Ar(r, this._parents, t, e) }) var Dr = (t) => () => t @@ -3708,9 +3498,7 @@ ) } function Gr(t) { - return 'string' == typeof t - ? new dt([document.querySelectorAll(t)], [document.documentElement]) - : new dt([o(t)], ht) + return 'string' == typeof t ? new dt([document.querySelectorAll(t)], [document.documentElement]) : new dt([o(t)], ht) } Nr.prototype var Vr = 1e-6, @@ -3854,15 +3642,7 @@ function l(t, e) { var n = o(t, 1), r = o(e, 1) - return n !== r - ? n - r - : 0 === n - ? e[1] - t[1] - : 1 === n - ? t[0] - e[0] - : 2 === n - ? t[1] - e[1] - : e[0] - t[0] + return n !== r ? n - r : 0 === n ? e[1] - t[1] : 1 === n ? t[0] - e[0] : 2 === n ? t[1] - e[1] : e[0] - t[0] } return function (o) { var l, @@ -3892,11 +3672,7 @@ polygonEnd: function () { var e = (function () { for (var e = 0, n = 0, i = u.length; n < i; ++n) - for ( - var a, o, s = u[n], l = 1, c = s.length, f = s[0], p = f[0], h = f[1]; - l < c; - ++l - ) + for (var a, o, s = u[n], l = 1, c = s.length, f = s[0], p = f[0], h = f[1]; l < c; ++l) (a = p), (o = h), (p = (f = s[l])[0]), @@ -3922,8 +3698,7 @@ } function w(a, o) { var s = i(a, o) - if ((u && c.push([a, o]), y)) - (f = a), (p = o), (h = s), (y = !1), s && (m.lineStart(), m.point(a, o)) + if ((u && c.push([a, o]), y)) (f = a), (p = o), (h = s), (y = !1), s && (m.lineStart(), m.point(a, o)) else if (s && _) m.point(a, o) else { var l = [(d = Math.max(gi, Math.min(di, d))), (g = Math.max(gi, Math.min(di, g)))], @@ -3979,10 +3754,7 @@ } })(l, x, t, e, n, r) ? s && (m.lineStart(), m.point(a, o), (v = !1)) - : (_ || (m.lineStart(), m.point(l[0], l[1])), - m.point(x[0], x[1]), - s || m.lineEnd(), - (v = !1)) + : (_ || (m.lineStart(), m.point(l[0], l[1])), m.point(x[0], x[1]), s || m.lineEnd(), (v = !1)) } ;(d = a), (g = o), (_ = s) } @@ -4362,9 +4134,7 @@ this._string = [] } function Ja(t) { - return ( - 'm0,' + t + 'a' + t + ',' + t + ' 0 1,1 0,' + -2 * t + 'a' + t + ',' + t + ' 0 1,1 0,' + 2 * t + 'z' - ) + return 'm0,' + t + 'a' + t + ',' + t + ' 0 1,1 0,' + -2 * t + 'a' + t + ',' + t + ' 0 1,1 0,' + 2 * t + 'z' } function Za(t, e, n) { var r = zt(t, e - Vr, n).concat(e) @@ -4517,8 +4287,7 @@ this._string.push('L', t, ',', e) break default: - null == this._circle && (this._circle = Ja(this._radius)), - this._string.push('M', t, ',', e, this._circle) + null == this._circle && (this._circle = Ja(this._radius)), this._string.push('M', t, ',', e, this._circle) } }, result: function () { @@ -4563,15 +4332,8 @@ r = n * ni(t), i = n * ii(t), a = ii(e), - o = ei( - oi((o = qa * a - Ya * i) * o + (o = Ya * r - Va * a) * o + (o = Va * i - qa * r) * o), - Va * r + qa * i + Ya * a - ) - ;(Oa += o), - (Pa += o * (Va + (Va = r))), - (Wa += o * (qa + (qa = i))), - (ja += o * (Ya + (Ya = a))), - ro(Va, qa, Ya) + o = ei(oi((o = qa * a - Ya * i) * o + (o = Ya * r - Va * a) * o + (o = Va * i - qa * r) * o), Va * r + qa * i + Ya * a) + ;(Oa += o), (Pa += o * (Va + (Va = r))), (Wa += o * (qa + (qa = i))), (ja += o * (Ya + (Ya = a))), ro(Va, qa, Ya) } function so() { eo.point = no @@ -4615,11 +4377,7 @@ r = Ua, i = e * e + n * n + r * r return i < 1e-12 && - ((e = Pa), - (n = Wa), - (r = ja), - Oa < Vr && ((e = Na), (n = Ia), (r = Ra)), - (i = e * e + n * n + r * r) < 1e-12) + ((e = Pa), (n = Wa), (r = ja), Oa < Vr && ((e = Na), (n = Ia), (r = Ra)), (i = e * e + n * n + r * r) < 1e-12) ? [NaN, NaN] : [ei(n, e) * Jr, si(r / oi(i)) * Jr] } @@ -4681,14 +4439,7 @@ for (var l = 0, u = t.length; l < u; ++l) if ((f = (c = t[l]).length)) for ( - var c, - f, - p = c[f - 1], - h = So(p), - d = p[1] / 2 + Xr, - g = ii(d), - _ = ni(d), - y = 0; + var c, f, p = c[f - 1], h = So(p), d = p[1] / 2 + Xr, g = ii(d), _ = ni(d), y = 0; y < f; ++y, h = m, g = b, _ = S, p = v ) { @@ -4712,19 +4463,14 @@ var L = yo(a, A) xo(L) var M = (k ^ (w >= 0) ? -1 : 1) * si(L[2]) - ;(r > M || (r === M && (A[0] || A[1]))) && - (s += k ^ (w >= 0) ? 1 : -1) + ;(r > M || (r === M && (A[0] || A[1]))) && (s += k ^ (w >= 0) ? 1 : -1) } } return (o < -Vr || (o < Vr && bo < -Vr)) ^ (1 & s) })(a, r) o.length ? (f || (i.polygonStart(), (f = !0)), pi(o, zo, t, n, i)) - : t && - (f || (i.polygonStart(), (f = !0)), - i.lineStart(), - n(null, null, 1, i), - i.lineEnd()), + : t && (f || (i.polygonStart(), (f = !0)), i.lineStart(), n(null, null, 1, i), i.lineEnd()), f && (i.polygonEnd(), (f = !1)), (o = a = null) }, @@ -4762,8 +4508,7 @@ if ((s.pop(), a.push(s), (s = null), h)) if (1 & l) { if ((e = (n = p[0]).length - 1) > 0) { - for (f || (i.polygonStart(), (f = !0)), i.lineStart(), t = 0; t < e; ++t) - i.point((r = n[t])[0], r[1]) + for (f || (i.polygonStart(), (f = !0)), i.lineStart(), t = 0; t < e; ++t) i.point((r = n[t])[0], r[1]) i.lineEnd() } } else h > 1 && 2 & l && p.push(p.pop().concat(p.shift())), o.push(p.filter(To)) @@ -4927,9 +4672,7 @@ L = F - r, M = A - i, C = v * L - y * M - ;((C * C) / m > e || - Qr((y * L + v * M) / m - 0.5) > 0.3 || - o * p + s * h + l * d < Do) && + ;((C * C) / m > e || Qr((y * L + v * M) / m - 0.5) > 0.3 || o * p + s * h + l * d < Do) && (n(r, i, a, o, s, l, F, A, z, (x /= w), (b /= w), S, g, _), _.point(F, A), n(F, A, z, x, b, S, u, c, f, p, h, d, g, _)) @@ -4968,22 +4711,7 @@ function v(r, i) { var a = go([r, i]), o = t(r, i) - n( - c, - f, - u, - p, - h, - d, - (c = o[0]), - (f = o[1]), - (u = r), - (p = a[0]), - (h = a[1]), - (d = a[2]), - 16, - e - ), + n(c, f, u, p, h, d, (c = o[0]), (f = o[1]), (u = r), (p = a[0]), (h = a[1]), (d = a[2]), 16, e), e.point(c, f) } function m() { @@ -5127,8 +4855,7 @@ var l = 2, u = t.length, c = new Array(u) - for (c[0] = (e += t[0]) * r + a, c[1] = (n += t[1]) * i + o; l < u; ) - (c[l] = t[l]), ++l + for (c[0] = (e += t[0]) * r + a, c[1] = (n += t[1]) * i + o; l < u; ) (c[l] = t[l]), ++l return c } })(t.transform), @@ -5138,8 +4865,7 @@ for (var i = r[t < 0 ? ~t : t], a = 0, o = i.length; a < o; ++a) e.push(n(i[a], a)) t < 0 && (function (t, e) { - for (var n, r = t.length, i = r - e; i < --r; ) - (n = t[i]), (t[i++] = t[r]), (t[r] = n) + for (var n, r = t.length, i = r - e; i < --r; ) (n = t[i]), (t[i++] = t[r]), (t[r] = n) })(e, o) } function a(t) { @@ -5218,11 +4944,7 @@ (o = qo[a][1]), (s = qo[a + 1][1]), (l = qo[Ho(19, a + 2)][1]), - (r -= - (d = - (e >= 0 ? Uo : -Uo) * - (s + (h * (l - o)) / 2 + (h * h * (l - 2 * s + o)) / 2) - - e) * $o) + (r -= (d = (e >= 0 ? Uo : -Uo) * (s + (h * (l - o)) / 2 + (h * h * (l - 2 * s + o)) / 2) - e) * $o) } while (Po(d) > 1e-12 && --g > 0) break } @@ -5300,8 +5022,7 @@ i.style.left = u + 'px' } } - i.offsetTop + i.clientHeight > a.top + s && - (i.style.top = i.offsetTop - i.clientHeight + 'px') + i.offsetTop + i.clientHeight > a.top + s && (i.style.top = i.offsetTop - i.clientHeight + 'px') }), n(), n @@ -6329,8 +6050,7 @@ if (Array.isArray(i.insetTemplates_[r])) for (var a = 0; a < i.insetTemplates_[r].length; a++) if (Array.isArray(i.insetTemplates_[r][a])) - for (var o = 0; o < i.insetTemplates_[r][a].length; o++) - i.insetTemplates_[r][a][o][n](e) + for (var o = 0; o < i.insetTemplates_[r][a].length; o++) i.insetTemplates_[r][a][o][n](e) else i.insetTemplates_[r][a][n](e) else i.insetTemplates_[r][n](e) } @@ -6539,13 +6259,11 @@ if (Array.isArray(i.insetTemplates_[o][s])) for (var l = 0; l < i.insetTemplates_[o][s].length; l++) { var u = i.insetTemplates_[o][s][l] - ;(u.drawCoastalMargin_ = i.drawCoastalMargin_), - i.drawCoastalMargin_ && a(u) + ;(u.drawCoastalMargin_ = i.drawCoastalMargin_), i.drawCoastalMargin_ && a(u) } else { var c = i.insetTemplates_[o][s] - ;(c.drawCoastalMargin_ = i.drawCoastalMargin_), - i.drawCoastalMargin_ && a(c) + ;(c.drawCoastalMargin_ = i.drawCoastalMargin_), i.drawCoastalMargin_ && a(c) } else { var f = i.insetTemplates_[o] @@ -6616,8 +6334,7 @@ (o = r[t.geo_ + '_' + t.proj_] && r[t.geo_ + '_' + t.proj_][a] ? r[t.geo_ + '_' + t.proj_][a] || [] - : (null === (n = r[t.geo_ + '_' + t.proj_]) || void 0 === n ? void 0 : n.en) || - []), + : (null === (n = r[t.geo_ + '_' + t.proj_]) || void 0 === n ? void 0 : n.en) || []), t.labelsToShow_.includes('cc') && (o = o.concat(r[t.geo_ + '_' + t.proj_].cc)), t.labelsToShow_.includes('values') && t._geom.nutsrg) ) { @@ -6778,10 +6495,7 @@ var n = t._projection([e.x, e.y]), r = n[0], i = n[1] - return 'translate(' - .concat(r, ',') - .concat(i, ') rotate(') - .concat(e.rotate, ')') + return 'translate('.concat(r, ',').concat(i, ') rotate(').concat(e.rotate, ')') } return 'rotate(0)' }) @@ -6826,10 +6540,7 @@ var n = t._projection([e.x, e.y]), r = n[0], i = n[1] - return 'translate(' - .concat(r, ',') - .concat(i, ') rotate(') - .concat(e.rotate, ')') + return 'translate('.concat(r, ',').concat(i, ') rotate(').concat(e.rotate, ')') } return 'rotate(0)' }) @@ -6890,9 +6601,7 @@ } if ('WORLD' == i.geo_) return [ - mn( - 'https://raw.githubusercontent.com/eurostat/eurostat-map/master/src/assets/topojson/WORLD_4326.json' - ), + mn('https://raw.githubusercontent.com/eurostat/eurostat-map/master/src/assets/topojson/WORLD_4326.json'), ] var r = [], a = [] @@ -7129,10 +6838,7 @@ if (r.apply(this, arguments)) { var n = b(this, e).event(t), i = this.__zoom, - s = Math.max( - l[0], - Math.min(l[1], i.k * Math.pow(2, o.apply(this, arguments))) - ), + s = Math.max(l[0], Math.min(l[1], i.k * Math.pow(2, o.apply(this, arguments)))), c = Mn(t) if (n.wheel) (n.mouse[0][0] === c[0] && n.mouse[0][1] === c[1]) || @@ -7164,11 +6870,7 @@ } o.event(t).zoom( 'mouse', - a( - v(o.that.__zoom, (o.mouse[0] = Mn(t, i)), o.mouse[1]), - o.extent, - u - ) + a(v(o.that.__zoom, (o.mouse[0] = Mn(t, i)), o.mouse[1]), o.extent, u) ) }, !0 @@ -7187,8 +6889,7 @@ }, 0)), 'onselectstart' in n ? r.on('selectstart.drag', null) - : ((n.style.MozUserSelect = n.__noselect), - delete n.__noselect) + : ((n.style.MozUserSelect = n.__noselect), delete n.__noselect) })(t.view, o.moved), Pr(t), o.event(t).end() @@ -7203,8 +6904,7 @@ n = yt(t).on('dragstart.drag', Fn, kn) 'onselectstart' in e ? n.on('selectstart.drag', Fn, kn) - : ((e.__noselect = e.style.MozUserSelect), - (e.style.MozUserSelect = 'none')) + : ((e.__noselect = e.style.MozUserSelect), (e.style.MozUserSelect = 'none')) })(t.view), Rr(t), (o.mouse = [l, this.__zoom.invert(l)]), @@ -7237,9 +6937,7 @@ for (Rr(n), o = 0; o < c; ++o) (l = [(l = Mn((s = u[o]), this)), this.__zoom.invert(l), s.identifier]), f.touch0 - ? f.touch1 || - f.touch0[2] === l[2] || - ((f.touch1 = l), (f.taps = 0)) + ? f.touch1 || f.touch0[2] === l[2] || ((f.touch1 = l), (f.taps = 0)) : ((f.touch0 = l), (a = !0), (f.taps = 1 + !!t)) t && (t = clearTimeout(t)), a && @@ -7304,15 +7002,10 @@ o.touch0 && o.touch0[2] === a.identifier ? delete o.touch0 : o.touch1 && o.touch1[2] === a.identifier && delete o.touch1 - if ( - (o.touch1 && !o.touch0 && ((o.touch0 = o.touch1), delete o.touch1), - o.touch0) - ) + if ((o.touch1 && !o.touch0 && ((o.touch0 = o.touch1), delete o.touch1), o.touch0)) o.touch0[1] = this.__zoom.invert(o.touch0[0]) else if ( - (o.end(), - 2 === o.taps && - ((a = Mn(a, this)), Math.hypot(e[0] - a[0], e[1] - a[1]) < g)) + (o.end(), 2 === o.taps && ((a = Mn(a, this)), Math.hypot(e[0] - a[0], e[1] - a[1]) < g)) ) { var u = yt(this).on('dblclick.zoom') u && u.apply(this, arguments) @@ -7329,10 +7022,7 @@ b(this, arguments) .event(r) .start() - .zoom( - null, - 'function' == typeof e ? e.apply(this, arguments) : e - ) + .zoom(null, 'function' == typeof e ? e.apply(this, arguments) : e) .end() }) }), @@ -7340,10 +7030,7 @@ _.scaleTo( t, function () { - return ( - this.__zoom.k * - ('function' == typeof e ? e.apply(this, arguments) : e) - ) + return this.__zoom.k * ('function' == typeof e ? e.apply(this, arguments) : e) }, n, r @@ -7355,12 +7042,7 @@ function () { var t = i.apply(this, arguments), r = this.__zoom, - o = - null == n - ? m(t) - : 'function' == typeof n - ? n.apply(this, arguments) - : n, + o = null == n ? m(t) : 'function' == typeof n ? n.apply(this, arguments) : n, s = r.invert(o), l = 'function' == typeof e ? e.apply(this, arguments) : e return a(v(y(r, l), o, s), t, u) @@ -7392,12 +7074,7 @@ function () { var t = i.apply(this, arguments), o = this.__zoom, - s = - null == r - ? m(t) - : 'function' == typeof r - ? r.apply(this, arguments) - : r + s = null == r ? m(t) : 'function' == typeof r ? r.apply(this, arguments) : r return a( Ir.translate(s[0], s[1]) .scale(o.k) @@ -7418,33 +7095,20 @@ return t && (this.sourceEvent = t), this }, start: function () { - return ( - 1 == ++this.active && - ((this.that.__zooming = this), this.emit('start')), - this - ) + return 1 == ++this.active && ((this.that.__zooming = this), this.emit('start')), this }, zoom: function (t, e) { return ( - this.mouse && - 'mouse' !== t && - (this.mouse[1] = e.invert(this.mouse[0])), - this.touch0 && - 'touch' !== t && - (this.touch0[1] = e.invert(this.touch0[0])), - this.touch1 && - 'touch' !== t && - (this.touch1[1] = e.invert(this.touch1[0])), + this.mouse && 'mouse' !== t && (this.mouse[1] = e.invert(this.mouse[0])), + this.touch0 && 'touch' !== t && (this.touch0[1] = e.invert(this.touch0[0])), + this.touch1 && 'touch' !== t && (this.touch1[1] = e.invert(this.touch1[0])), (this.that.__zoom = e), this.emit('zoom'), this ) }, end: function () { - return ( - 0 == --this.active && (delete this.that.__zooming, this.emit('end')), - this - ) + return 0 == --this.active && (delete this.that.__zooming, this.emit('end')), this }, emit: function (t) { var e = yt(this.that).datum() @@ -7488,11 +7152,7 @@ }), (_.translateExtent = function (t) { return arguments.length - ? ((u[0][0] = +t[0][0]), - (u[1][0] = +t[1][0]), - (u[0][1] = +t[0][1]), - (u[1][1] = +t[1][1]), - _) + ? ((u[0][0] = +t[0][0]), (u[1][0] = +t[1][0]), (u[0][1] = +t[0][1]), (u[1][1] = +t[1][1]), _) : [ [u[0][0], u[0][1]], [u[1][0], u[1][1]], @@ -7539,18 +7199,12 @@ }), (i.buildInsets = function () { i.insetBoxPosition_ || - (i.insetBoxPosition_ = [ - i.width_ - i.insetBoxWidth_ - 2 * i.insetBoxPadding_, - 2 * i.insetBoxPadding_, - ]) + (i.insetBoxPosition_ = [i.width_ - i.insetBoxWidth_ - 2 * i.insetBoxPadding_, 2 * i.insetBoxPadding_]) var t = yt('#' + i.svgId_) .select('#drawing' + i.svgId_) .append('g') .attr('id', 'insetsgroup') - .attr( - 'transform', - 'translate(' + i.insetBoxPosition_[0] + ',' + i.insetBoxPosition_[1] + ')' - ) + .attr('transform', 'translate(' + i.insetBoxPosition_[0] + ',' + i.insetBoxPosition_[1] + ')') 'default' === i.insets_ && (i.insets_ = os(i.insetBoxWidth_, i.insetBoxPadding_)) for (var e = 0; e < i.insets_.length; e++) { var n = i.insets_[e] @@ -7559,10 +7213,7 @@ 0 == yt('#' + n.svgId).size()) ) { var r = null == n.x ? i.insetBoxPadding_ : n.x, - a = - null == n.y - ? i.insetBoxPadding_ + e * (i.insetBoxPadding_ + i.insetBoxWidth_) - : n.y + a = null == n.y ? i.insetBoxPadding_ + e * (i.insetBoxPadding_ + i.insetBoxWidth_) : n.y t.append('g') .attr('id', 'insetzg' + n.svgId) .attr('transform', 'translate(' + r + ',' + a + ')') @@ -7583,18 +7234,11 @@ i.tooltip_ ? (i._tooltip = Qo(i.tooltip_)) : (i._tooltip = Qo()) var t = as[i.geo_ + '_' + i.proj_] i.geoCenter() || - (t - ? i.geoCenter(t.geoCenter) - : i.geoCenter([0.5 * (l.bbox[0] + l.bbox[2]), 0.5 * (l.bbox[1] + l.bbox[3])])), + (t ? i.geoCenter(t.geoCenter) : i.geoCenter([0.5 * (l.bbox[0] + l.bbox[2]), 0.5 * (l.bbox[1] + l.bbox[3])])), i.pixSize_ || (t ? i.pixSize((800 * t.pixSize) / i.width_) - : i.pixSize( - Math.min( - (l.bbox[2] - l.bbox[0]) / i.width_, - (l.bbox[3] - l.bbox[1]) / i.height_ - ) - )) + : i.pixSize(Math.min((l.bbox[2] - l.bbox[0]) / i.width_, (l.bbox[3] - l.bbox[1]) / i.height_))) var e, a = [ i.geoCenter_[0] - 0.5 * i.pixSize_ * i.width_, @@ -7644,13 +7288,7 @@ r = (m ? Ro : Io)(f, p - t[0], h - t[1], x, b, m) return ( (n = (function (t, e, n) { - return (t %= Kr) - ? e || n - ? Ao(Co(t), Eo(e, n)) - : Co(t) - : e || n - ? Eo(e, n) - : Lo + return (t %= Kr) ? (e || n ? Ao(Co(t), Eo(e, n)) : Co(t)) : e || n ? Eo(e, n) : Lo })(_, y, v)), (s = Ao(e, r)), (l = Ao(n, s)), @@ -7680,9 +7318,7 @@ return arguments.length ? ((w = t), (S = void 0), M()) : w }), (F.postclip = function (t) { - return arguments.length - ? ((z = t), (T = r = i = a = null), M()) - : z + return arguments.length ? ((z = t), (T = r = i = a = null), M()) : z }), (F.clipAngle = function (t) { return arguments.length @@ -7724,19 +7360,13 @@ var T = b - x, z = Qr(T - qr) < Vr if ( - (!z && - w < S && - ((m = S), (S = w), (w = m)), + (!z && w < S && ((m = S), (S = w), (w = m)), z || T < Vr ? z ? (S + w > 0) ^ - (v[1] < - (Qr(v[0] - x) < Vr - ? S - : w)) + (v[1] < (Qr(v[0] - x) < Vr ? S : w)) : S <= v[1] && v[1] <= w - : (T > qr) ^ - (x <= v[0] && v[0] <= b)) + : (T > qr) ^ (x <= v[0] && v[0] <= b)) ) { var k = mo(h, (-d + y) / g) return vo(k, p), [v, ho(k)] @@ -7769,22 +7399,12 @@ ? 0 : s(f, p) : g - ? s( - f + - (f < 0 - ? qr - : -qr), - p - ) + ? s(f + (f < 0 ? qr : -qr), p) : 0 if ( - (!e && - (u = l = g) && - t.lineStart(), + (!e && (u = l = g) && t.lineStart(), g !== l && - (!(h = o(e, d)) || - ci(e, h) || - ci(d, h)) && + (!(h = o(e, d)) || ci(e, h) || ci(d, h)) && (d[2] = 1), g !== l) ) @@ -7794,11 +7414,7 @@ (h = o(d, e)), t.point(h[0], h[1])) : ((h = o(e, d)), - t.point( - h[0], - h[1], - 2 - ), + t.point(h[0], h[1], 2), t.lineEnd()), (e = h) else if (i && e && r ^ g) { @@ -7808,30 +7424,15 @@ ((c = 0), r ? (t.lineStart(), - t.point( - y[0][0], - y[0][1] - ), - t.point( - y[1][0], - y[1][1] - ), + t.point(y[0][0], y[0][1]), + t.point(y[1][0], y[1][1]), t.lineEnd()) - : (t.point( - y[1][0], - y[1][1] - ), + : (t.point(y[1][0], y[1][1]), t.lineEnd(), t.lineStart(), - t.point( - y[0][0], - y[0][1], - 3 - ))) + t.point(y[0][0], y[0][1], 3))) } - !g || - (e && ci(e, d)) || - t.point(d[0], d[1]), + !g || (e && ci(e, d)) || t.point(d[0], d[1]), (e = d), (l = g), (n = _) @@ -7851,22 +7452,12 @@ s = ii(e), l = r * n null == i - ? ((i = e + r * Kr), - (a = e - l / 2)) + ? ((i = e + r * Kr), (a = e - l / 2)) : ((i = Fo(o, i)), (a = Fo(o, a)), - (r > 0 ? i < a : i > a) && - (i += r * Kr)) - for ( - var u, c = i; - r > 0 ? c > a : c < a; - c -= l - ) - (u = ho([ - o, - -s * ni(c), - -s * ii(c), - ])), + (r > 0 ? i < a : i > a) && (i += r * Kr)) + for (var u, c = i; r > 0 ? c > a : c < a; c -= l) + (u = ho([o, -s * ni(c), -s * ii(c)])), t.point(u[0], u[1]) } })(a, t, n, i, e, r) @@ -7883,12 +7474,7 @@ ? ((z = null == t ? ((T = r = i = a = null), yi) - : _i( - (T = +t[0][0]), - (r = +t[0][1]), - (i = +t[1][0]), - (a = +t[1][1]) - )), + : _i((T = +t[0][0]), (r = +t[0][1]), (i = +t[1][0]), (a = +t[1][1]))), M()) : null == T ? null @@ -7941,11 +7527,7 @@ return Ii(F, t, e) }), function () { - return ( - (e = t.apply(this, arguments)), - (F.invert = e.invert && A), - L() - ) + return (e = t.apply(this, arguments)), (F.invert = e.invert && A), L() } ) })(function () { @@ -8014,12 +7596,7 @@ ? ((y = null == t ? ((h = n = r = i = null), yi) - : _i( - (h = +t[0][0]), - (n = +t[0][1]), - (r = +t[1][0]), - (i = +t[1][1]) - )), + : _i((h = +t[0][0]), (n = +t[0][1]), (r = +t[1][0]), (i = +t[1][1]))), v()) : null == h ? null @@ -8035,9 +7612,7 @@ return arguments.length ? ((l = +t[0]), (u = +t[1]), v()) : [l, u] }), (m.angle = function (n) { - return arguments.length - ? ((e = ii((p = (n % 360) * Zr))), (t = ni(p)), v()) - : p * Jr + return arguments.length ? ((e = ii((p = (n % 360) * Zr))), (t = ni(p)), v()) : p * Jr }), (m.reflectX = function (t) { return arguments.length ? ((c = t ? -1 : 1), v()) : c < 0 @@ -8077,10 +7652,7 @@ i = 4.5 function a(t) { return ( - t && - ('function' == typeof i && r.pointRadius(+i.apply(this, arguments)), - zi(t, n(r))), - r.result() + t && ('function' == typeof i && r.pointRadius(+i.apply(this, arguments)), zi(t, n(r))), r.result() ) } return ( @@ -8097,9 +7669,7 @@ return zi(t, n(Sa)), Sa.result() }), (a.projection = function (e) { - return arguments.length - ? ((n = null == e ? ((t = null), yi) : (t = e).stream), a) - : t + return arguments.length ? ((n = null == e ? ((t = null), yi) : (t = e).stream), a) : t }), (a.context = function (t) { return arguments.length @@ -8109,9 +7679,7 @@ : e }), (a.pointRadius = function (t) { - return arguments.length - ? ((i = 'function' == typeof t ? t : (r.pointRadius(+t), +t)), a) - : i + return arguments.length ? ((i = 'function' == typeof t ? t : (r.pointRadius(+t), +t)), a) : i }), a.projection(t).context(e) ) @@ -8242,12 +7810,7 @@ (i._geom.mixed.rg1 = Ko(u[1], u[1].objects.nutsrg).features), (i._geom.mixed.rg2 = Ko(u[2], u[2].objects.nutsrg).features), (i._geom.mixed.rg3 = Ko(u[3], u[3].objects.nutsrg).features), - [ - i._geom.mixed.rg0, - i._geom.mixed.rg1, - i._geom.mixed.rg2, - i._geom.mixed.rg3, - ].forEach(function (t, e) { + [i._geom.mixed.rg0, i._geom.mixed.rg1, i._geom.mixed.rg2, i._geom.mixed.rg3].forEach(function (t, e) { s.append('g') .attr('id', 'g_nutsrg') .selectAll('path') @@ -8434,12 +7997,7 @@ (c ? (o = 'mixed' == i.nutsLevel_ - ? [].concat( - r(c[0].features), - r(c[1].features), - r(c[2].features), - r(c[3].features) - ) + ? [].concat(r(c[0].features), r(c[1].features), r(c[2].features), r(c[3].features)) : c.features) : 'WORLD' == i.geo_ && ((o = []), @@ -8452,16 +8010,9 @@ _n(t, e, n[e]) }) : Object.getOwnPropertyDescriptors - ? Object.defineProperties( - t, - Object.getOwnPropertyDescriptors(n) - ) + ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(n)) : rs(Object(n)).forEach(function (e) { - Object.defineProperty( - t, - e, - Object.getOwnPropertyDescriptor(n, e) - ) + Object.defineProperty(t, e, Object.getOwnPropertyDescriptor(n, e)) }) } return t @@ -8489,9 +8040,7 @@ }) .on('mouseover', function (t, e) { if (i.countriesToShow_ && 'WORLD' !== i.geo_) { - if ( - i.countriesToShow_.includes(e.properties.id[0] + e.properties.id[1]) - ) { + if (i.countriesToShow_.includes(e.properties.id[0] + e.properties.id[1])) { var n = yt(this.childNodes[0]) n.attr('fill___', n.attr('fill')), n.attr('fill', i.nutsrgSelFillSty_), @@ -8537,8 +8086,7 @@ .style('stroke-linejoin', 'round') .style('paint-order', 'stroke')), i.subtitle() && - (i.subtitlePosition() || - i.subtitlePosition([10, 8 + i.titleFontSize() + 5 + i.subtitleFontSize()]), + (i.subtitlePosition() || i.subtitlePosition([10, 8 + i.titleFontSize() + 5 + i.subtitleFontSize()]), i .svg() .append('text') @@ -8577,16 +8125,12 @@ i.botTxtTooltipTxt_ && i._tooltip.mousemove(t) }) .on('mouseout', function (t) { - i.botTxtTooltipTxt_ && i._tooltip.mouseout(t), - i._tooltip.style('max-width', i._tooltip.mw___) + i.botTxtTooltipTxt_ && i._tooltip.mouseout(t), i._tooltip.style('max-width', i._tooltip.mw___) }), i.showSourceLink_ && i.stat() && i.stat().eurostatDatasetCode) ) { var _ = i.stat().eurostatDatasetCode, - y = 'https://ec.europa.eu/eurostat/databrowser/view/'.concat( - _, - '/default/table?lang=en' - ), + y = 'https://ec.europa.eu/eurostat/databrowser/view/'.concat(_, '/default/table?lang=en'), v = i .svg() .append('a') @@ -8603,15 +8147,11 @@ .attr('text-anchor', 'end') .on('mouseover', function () { var t = yt(this) - t.attr('fill', 'lightblue'), - t.style('cursor', 'pointer'), - t.style('text-decoration', 'underline') + t.attr('fill', 'lightblue'), t.style('cursor', 'pointer'), t.style('text-decoration', 'underline') }) .on('mouseout', function () { var t = yt(this) - t.attr('fill', 'black'), - t.style('cursor', 'default'), - t.style('text-decoration', 'none') + t.attr('fill', 'black'), t.style('cursor', 'default'), t.style('text-decoration', 'none') }) .node() .getComputedTextLength() @@ -8778,8 +8318,7 @@ var t = i.svg_.selectAll('g.labels-container > *') if ((t && t.remove(), i.labelling_)) { var e = i.svg_.select('#zoomgroup' + i.svgId_) - f(i, e), - i.labelsToShow_.includes('values') && i.updateValuesLabels && i.updateValuesLabels(i) + f(i, e), i.labelsToShow_.includes('values') && i.updateValuesLabels && i.updateValuesLabels(i) } if (i.insetTemplates_) for (var n in i.insetTemplates_) @@ -8791,9 +8330,7 @@ var o = i.insetTemplates_[n][r][a] if (o.labelling_) { var s = o.svg_.select('#zoomgroup' + o.svgId_) - f(o, s), - o.labelsToShow_.includes('values') && - i.updateValuesLabels(o) + f(o, s), o.labelsToShow_.includes('values') && i.updateValuesLabels(o) } } } else if (i.insetTemplates_[n][r].svgId_ !== i.svgId_) { @@ -8830,20 +8367,14 @@ ) }), (i.statLabelsTextFunction = function (t) { - if ( - i.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1]) || - 'WORLD' == i.geo_ - ) { + if (i.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1]) || 'WORLD' == i.geo_) { var e = i.statData().get(t.properties.id) if (!e || (!e.value && 0 !== e && 0 !== e.value)) return '' if (':' !== e.value) return Zo(e.value) } }), (i.statLabelsFilterFunction = function (t) { - if ( - i.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1]) || - 'WORLD' == i.geo_ - ) { + if (i.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1]) || 'WORLD' == i.geo_) { var e = i.statData().get(t.properties.id) return !(!e || (!e.value && 0 !== e && 0 !== e.value)) } @@ -9139,11 +8670,7 @@ a = t.getUTCMilliseconds() return isNaN(t) ? 'Invalid Date' - : ((e = t.getUTCFullYear()) < 0 - ? '-' + ps(-e, 6) - : e > 9999 - ? '+' + ps(e, 6) - : ps(e, 4)) + + : ((e = t.getUTCFullYear()) < 0 ? '-' + ps(-e, 6) : e > 9999 ? '+' + ps(e, 6) : ps(e, 4)) + '-' + ps(t.getUTCMonth() + 1, 2) + '-' + @@ -9222,9 +8749,7 @@ o = function (t, e, n) { var r, i = [] - if ( - (n && !ws(n.name) && (n = null), 'string' == typeof t && (t = [t]), Array.isArray(t) || Ss(t)) - ) { + if ((n && !ws(n.name) && (n = null), 'string' == typeof t && (t = [t]), Array.isArray(t) || Ss(t))) { if (t.length === e) return n && -1 === @@ -9249,11 +8774,9 @@ case 'bundle': var s = [], l = 0 - if (((this.error = null), (this.length = 0), null === t || 'object' != typeof t)) - return void (this.class = null) + if (((this.error = null), (this.length = 0), null === t || 'object' != typeof t)) return void (this.class = null) if (t.hasOwnProperty('error')) return void (this.error = t.error) - if ('dataset' === t.class || 'collection' === t.class || 'dimension' === t.class) - return new bs(t) + if ('dataset' === t.class || 'collection' === t.class || 'dimension' === t.class) return new bs(t) for (r in t) l++, s.push(r) ;(this.__tree__ = t), (this.length = l), (this.id = s) break @@ -9271,8 +8794,7 @@ f = n.size || (n.dimension && n.dimension.size) if ( ((this.size = f), - (this.value = - n.hasOwnProperty('value') && null !== n.value && 0 !== n.value.length ? n.value : {}), + (this.value = n.hasOwnProperty('value') && null !== n.value && 0 !== n.value.length ? n.value : {}), Array.isArray(this.value) || Ss(this.value)) ) c = this.value.length @@ -9310,8 +8832,7 @@ var b = d[m[u]] null !== b && (v = v.concat(b)) } - for (d.classification = [], u = 0; u < _; u++) - x(g[u], v) || d.classification.push(g[u]) + for (d.classification = [], u = 0; u < _; u++) x(g[u], v) || d.classification.push(g[u]) 0 === d.classification.length && (d.classification = null) } ;(this.role = d), (this.n = c) @@ -9325,8 +8846,7 @@ } } else { var k = 0 - for (r in ((h[g[S]].category.index = {}), h[g[S]].category.label)) - h[g[S]].category.index[r] = k++ + for (r in ((h[g[S]].category.index = {}), h[g[S]].category.label)) h[g[S]].category.index[r] = k++ } } else this.length = 0 break @@ -9478,9 +8998,7 @@ r = [], i = this.id.length, a = function (t, e) { - if (null !== t) - for (var n in t) - for (var r = null !== t[n] ? t[n].length : 0; r--; ) if (t[n][r] === e) return n + if (null !== t) for (var n in t) for (var r = null !== t[n] ? t[n].length : 0; r--; ) if (t[n][r] === e) return n return null } if (null === this || 'dataset' !== this.class) return null @@ -9556,11 +9074,7 @@ if ('object' != typeof t) return this 'object' != typeof e ? ('boolean' == typeof e && !0 === e && (r = !0), ('boolean' == typeof n && !0 === n) || (n = !1)) - : ((r = s(e, 'clone')), - (n = s(e, 'drop')), - (i = s(e, 'stringify')), - (a = s(e, 'ovalue')), - (o = s(e, 'ostatus'))) + : ((r = s(e, 'clone')), (n = s(e, 'drop')), (i = s(e, 'stringify')), (a = s(e, 'ovalue')), (o = s(e, 'ostatus'))) var l, u = this.value, c = r ? new bs(JSON.parse(JSON.stringify(this))) : this, @@ -9651,11 +9165,8 @@ (l.size = l.dimension.size), delete l.dimension.id, delete l.dimension.size, - l.dimension.hasOwnProperty('role') && - ((l.role = l.dimension.role), delete l.dimension.role)), - l.hasOwnProperty('status') && - -1 !== ['null', '{}', '[]'].indexOf(JSON.stringify(l.status)) && - delete l.status, + l.dimension.hasOwnProperty('role') && ((l.role = l.dimension.role), delete l.dimension.role)), + l.hasOwnProperty('status') && -1 !== ['null', '{}', '[]'].indexOf(JSON.stringify(l.status)) && delete l.status, l.hasOwnProperty('role') && (delete l.role.classification, ['geo', 'time', 'metric'].forEach(function (t) { @@ -9723,9 +9234,7 @@ } return i } - return e - ? { value: this.value[p], status: this.status ? this.status[p] : null } - : this.value[p] + return e ? { value: this.value[p], status: this.status ? this.status[p] : null } : this.value[p] } s = 'array' } @@ -9801,9 +9310,7 @@ var v = e.call(this, W[r], r) void 0 !== v && _.push(v) } - return 'object' === t.type - ? { cols: n.cols, rows: _ } - : ('array' === t.type && _.unshift(n[0]), _) + return 'object' === t.type ? { cols: n.cols, rows: _ } : ('array' === t.type && _.unshift(n[0]), _) } if ('arrobj' === t.type || 'objarr' === t.type) { var m = [], @@ -9971,8 +9478,7 @@ (l = function (t, e, n) { var r = p(t), i = h(e) - n && nt.push({ id: 'status', label: i, type: 'string' }), - nt.push({ id: 'value', label: r, type: G }) + n && nt.push({ id: 'status', label: i, type: 'string' }), nt.push({ id: 'value', label: r, type: G }) }), (u = function (t) { dt.push({ v: t }) @@ -10016,15 +9522,13 @@ for (i = 0; i < Y[r]; i++) for (var ot in V[q[r]].category.index) if (V[q[r]].category.index[ot] === i) { - var st = - 'id' !== t.content && V[q[r]].category.label ? V[q[r]].category.label[ot] : ot + var st = 'id' !== t.content && V[q[r]].category.label ? V[q[r]].category.label[ot] : ot at.push(st) } K.push(at), Z.push(D) } for (l(t.vlabel, t.slabel, g), o = K.length, r = 0; r < o; r++) { - for (var lt = [], ut = 0, ct = K[r].length; ut < ct; ut++) - for (var ft = 0; ft < J / Z[r]; ft++) lt.push(K[r][ut]) + for (var lt = [], ut = 0, ct = K[r].length; ut < ct; ut++) for (var ft = 0; ft < J / Z[r]; ft++) lt.push(K[r][ut]) Q.push(lt) } for (o = Q.length, r = 0; r < o; r++) { @@ -10160,8 +9664,7 @@ ) for (var a in e) { var o = e[a] - if (Array.isArray(o)) - for (var s = 0; s < o.length; s++) i.push('&', a, '=', o[s]) + if (Array.isArray(o)) for (var s = 0; s < o.length; s++) i.push('&', a, '=', o[s]) else i.push('&', a, '=', o) } return i.join('') @@ -10194,8 +9697,7 @@ }), (e.metadata.time = n.Dimension('time').id[0]), (e._data_ = (function (t) { - for (var e = {}, n = t.Dimension('geo').id, r = 0; r < n.length; r++) - e[n[r]] = t.Data(r) + for (var e = {}, n = t.Dimension('geo').id, r = 0; r < n.length; r++) e[n[r]] = t.Data(r) return e })(n)), r && r() @@ -10214,9 +9716,7 @@ for (var r = {}, i = 0; i < t.length; i++) { var a = t[i], o = a[n] - r[a[e]] = o - ? { value: isNaN(+o) ? o : +o, status: '' } - : { value: ':', status: '' } + r[a[e]] = o ? { value: isNaN(+o) ? o : +o, status: '' } : { value: ':', status: '' } } return r })(n, e.geoCol_, e.valueCol_)), @@ -10286,13 +9786,11 @@ function Fs(t, e) { let n, r if (void 0 === e) - for (const e of t) - null != e && (void 0 === n ? e >= e && (n = r = e) : (n > e && (n = e), r < e && (r = e))) + for (const e of t) null != e && (void 0 === n ? e >= e && (n = r = e) : (n > e && (n = e), r < e && (r = e))) else { let i = -1 for (let a of t) - null != (a = e(a, ++i, t)) && - (void 0 === n ? a >= a && (n = r = a) : (n > a && (n = a), r < a && (r = a))) + null != (a = e(a, ++i, t)) && (void 0 === n ? a >= a && (n = r = a) : (n > a && (n = a), r < a && (r = a))) } return [n, r] } @@ -10341,9 +9839,7 @@ T = S.enter().append('g').attr('class', 'tick'), z = S.select('line'), k = S.select('text') - ;(b = b.merge( - b.enter().insert('path', '.tick').attr('class', 'domain').attr('stroke', 'currentColor') - )), + ;(b = b.merge(b.enter().insert('path', '.tick').attr('class', 'domain').attr('stroke', 'currentColor'))), (S = S.merge(T)), (z = z.merge( T.append('line') @@ -10452,13 +9948,7 @@ n = 1 return ( (e.exponent = function (e) { - return arguments.length - ? 1 == (n = +e) - ? t(je, je) - : 0.5 === n - ? t(Hs, Bs) - : t(js(n), js(1 / n)) - : n + return arguments.length ? (1 == (n = +e) ? t(je, je) : 0.5 === n ? t(Hs, Bs) : t(js(n), js(1 / n))) : n }), ln(e) ) @@ -10516,8 +10006,7 @@ const n = 10 ** e return function (t) { this._ += t[0] - for (let e = 1, r = t.length; e < r; ++e) - this._ += Math.round(arguments[e] * n) / n + t[e] + for (let e = 1, r = t.length; e < r; ++e) this._ += Math.round(arguments[e] * n) / n + t[e] } })(t)) } @@ -10558,8 +10047,7 @@ m = v / y, x = v / _ Math.abs(m - 1) > ol && this._append`L${t + m * u},${e + m * c}`, - this._append`A${i},${i},0,0,${+(c * p > u * h)},${(this._x1 = t + x * s)},${(this._y1 = - e + x * l)}` + this._append`A${i},${i},0,0,${+(c * p > u * h)},${(this._x1 = t + x * s)},${(this._y1 = e + x * l)}` } else this._append`L${(this._x1 = t)},${(this._y1 = e)}` } arc(t, e, n, r, i, a) { @@ -10576,8 +10064,7 @@ n && (f < 0 && (f = (f % al) + al), f > sl - ? this._append`A${n},${n},0,1,${c},${t - o},${e - s}A${n},${n},0,1,${c},${(this._x1 = - l)},${(this._y1 = u)}` + ? this._append`A${n},${n},0,1,${c},${t - o},${e - s}A${n},${n},0,1,${c},${(this._x1 = l)},${(this._y1 = u)}` : f > ol && this._append`A${n},${n},0,${+(f >= il)},${c},${(this._x1 = t + n * Math.cos(i))},${(this._y1 = e + n * Math.sin(i))}`) @@ -10693,12 +10180,8 @@ if (F > Qs) { var C = rl((F / p) * Js(k)), E = rl((F / h) * Js(k)) - ;(T -= 2 * C) > Qs - ? ((S += C *= y ? 1 : -1), (w -= C)) - : ((T = 0), (S = w = (d + g) / 2)), - (z -= 2 * E) > Qs - ? ((x += E *= y ? 1 : -1), (b -= E)) - : ((z = 0), (x = b = (d + g) / 2)) + ;(T -= 2 * C) > Qs ? ((S += C *= y ? 1 : -1), (w -= C)) : ((T = 0), (S = w = (d + g) / 2)), + (z -= 2 * E) > Qs ? ((x += E *= y ? 1 : -1), (b -= E)) : ((z = 0), (x = b = (d + g) / 2)) } var D = h * Ys(x), O = h * Js(x), @@ -10718,8 +10201,7 @@ c = o - i, f = s - a, p = f * l - c * u - if (!(p * p < Qs)) - return [t + (p = (c * (e - a) - f * (t - i)) / p) * l, e + p * u] + if (!(p * p < Qs)) return [t + (p = (c * (e - a) - f * (t - i)) / p) * l, e + p * u] })(D, O, j, H, P, W, N, I)) ) { var B = D - R[0], @@ -10747,14 +10229,7 @@ M < A ? s.arc(v.cx, v.cy, M, qs(v.y01, v.x01), qs(m.y01, m.x01), !y) : (s.arc(v.cx, v.cy, M, qs(v.y01, v.x01), qs(v.y11, v.x11), !y), - s.arc( - 0, - 0, - h, - qs(v.cy + v.y11, v.cx + v.x11), - qs(m.cy + m.y11, m.cx + m.x11), - !y - ), + s.arc(0, 0, h, qs(v.cy + v.y11, v.cx + v.x11), qs(m.cy + m.y11, m.cx + m.x11), !y), s.arc(m.cx, m.cy, M, qs(m.y11, m.x11), qs(m.y01, m.x01), !y))) : (s.moveTo(D, O), s.arc(0, 0, h, x, b, !y)) : s.moveTo(D, O), @@ -10766,14 +10241,7 @@ L < A ? s.arc(v.cx, v.cy, L, qs(v.y01, v.x01), qs(m.y01, m.x01), !y) : (s.arc(v.cx, v.cy, L, qs(v.y01, v.x01), qs(v.y11, v.x11), !y), - s.arc( - 0, - 0, - p, - qs(v.cy + v.y11, v.cx + v.x11), - qs(m.cy + m.y11, m.cx + m.x11), - y - ), + s.arc(0, 0, p, qs(v.cy + v.y11, v.cx + v.x11), qs(m.cy + m.y11, m.cx + m.x11), y), s.arc(m.cx, m.cy, L, qs(m.y11, m.x11), qs(m.y01, m.x01), !y))) : s.arc(0, 0, p, w, S, y) : s.lineTo(N, I) @@ -10891,10 +10359,7 @@ for (s.lineEnd(), s.lineStart(), p = c - 1; p >= f; --p) s.point(y[p], v[p]) s.lineEnd(), s.areaEnd() } - _ && - ((y[c] = +t(h, c, u)), - (v[c] = +e(h, c, u)), - s.point(r ? +r(h, c, u) : y[c], n ? +n(h, c, u) : v[c])) + _ && ((y[c] = +t(h, c, u)), (v[c] = +e(h, c, u)), s.point(r ? +r(h, c, u) : y[c], n ? +n(h, c, u) : v[c])) } if (d) return (s = null), d + '' || null } @@ -11093,8 +10558,7 @@ this._point = 0 }, lineEnd: function () { - ;(this._line || (0 !== this._line && 1 === this._point)) && this._context.closePath(), - (this._line = 1 - this._line) + ;(this._line || (0 !== this._line && 1 === this._point)) && this._context.closePath(), (this._line = 1 - this._line) }, point: function (t, e) { switch (((t = +t), (e = +e), this._point)) { @@ -11123,11 +10587,7 @@ }), (n.statData_ = { default: zs(), color: zs(), size: zs(), v1: zs(), v2: zs() }), (n.statData = function (t, e) { - return arguments.length - ? 1 == arguments.length - ? n.statData_[t] - : ((n.statData_[t] = e), n) - : n.statData_.default + return arguments.length ? (1 == arguments.length ? n.statData_[t] : ((n.statData_[t] = e), n)) : n.statData_.default }), (n.noDataText_ = 'No data available'), (n.lg_ = 'en'), @@ -11196,9 +10656,7 @@ (n.updateStatData = function () { for (var t in n.stat_) { if (!n.stat(t) && n.statData(t).get()) return - 'default' != t || - n.stat(t) || - n.stat(t, { eurostatDatasetCode: 'demo_r_d3dens', unitText: 'inhab./km²' }) + 'default' != t || n.stat(t) || n.stat(t, { eurostatDatasetCode: 'demo_r_d3dens', unitText: 'inhab./km²' }) var e = zs(n.stat(t)) n.statData(t, e) var r = n.nutsLevel_ @@ -11290,8 +10748,7 @@ var e = 'http://www.w3.org/2000/xmlns/' t = t.cloneNode(!0) for ( - var n = window.location.href + '#', - r = document.createTreeWalker(t, NodeFilter.SHOW_ELEMENT, null, !1); + var n = window.location.href + '#', r = document.createTreeWalker(t, NodeFilter.SHOW_ELEMENT, null, !1); r.nextNode(); ) { @@ -11308,8 +10765,7 @@ a.f() } } - t.setAttributeNS(e, 'xmlns', 'http://www.w3.org/2000/svg'), - t.setAttributeNS(e, 'xmlns:xlink', 'http://www.w3.org/1999/xlink') + t.setAttributeNS(e, 'xmlns', 'http://www.w3.org/2000/svg'), t.setAttributeNS(e, 'xmlns:xlink', 'http://www.w3.org/1999/xlink') var s = new window.XMLSerializer().serializeToString(t) return new Blob([s], { type: 'image/svg+xml' }) } @@ -11343,10 +10799,7 @@ n.push( '\n
\n \n \n \n \n \n \n
\n ' .concat(Zo(r.value), ' ') - .concat( - i || '', - '\n
\n
\n ' - ) + .concat(i || '', '\n \n \n \n \n \n ') ) var a = r.status if (a && e.tooltip_.showFlags) @@ -11359,9 +10812,7 @@ }, Dl = function () { for ( - var t = {}, - e = ['w', 'h', 'x', 'y', 'z', 's', 'lvl', 'time', 'proj', 'geo', 'ny', 'lg', 'sl', 'clnb'], - n = 0; + var t = {}, e = ['w', 'h', 'x', 'y', 'z', 's', 'lvl', 'time', 'proj', 'geo', 'ny', 'lg', 'sl', 'clnb'], n = 0; n < e.length; n++ ) @@ -11426,10 +10877,7 @@ for ( var s = n.labelFormatter ? n.labelFormatter : nn('.' + n.labelDecNb + 'f'), l = function () { - var o = - n.boxPadding + - (n.title ? n.titleFontSize + n.boxPadding : 0) + - u * n.shapeHeight, + var o = n.boxPadding + (n.title ? n.titleFontSize + n.boxPadding : 0) + u * n.shapeHeight, l = n.ascending ? t.clnb() - u - 1 : u r .append('rect') @@ -11439,19 +10887,14 @@ .attr('height', n.shapeHeight) .attr('fill', t.classToFillStyle()(l, t.clnb())) .on('mouseover', function () { - if ( - (yt(this).style('fill', t.nutsrgSelFillSty()), - i(e, l), - n.map.insetTemplates_) - ) { + if ((yt(this).style('fill', t.nutsrgSelFillSty()), i(e, l), n.map.insetTemplates_)) { var r = n.map.insetTemplates_ for (var a in r) if (Array.isArray(r[a])) for (var o = 0; o < r[a].length; o++) if (Array.isArray(r[a][o])) for (var s = 0; s < r[a][o].length; s++) - r[a][o][s].svgId_ !== n.svgId_ && - i(r[a][o][s].svg(), l) + r[a][o][s].svgId_ !== n.svgId_ && i(r[a][o][s].svg(), l) else r[a][o].svgId_ !== n.svgId_ && i(r[a][o].svg(), l) else r[a].svgId_ !== n.svgId_ && i(r[a].svg(), l) } @@ -11468,8 +10911,7 @@ for (var o = 0; o < r[i].length; o++) if (Array.isArray(r[i][o])) for (var s = 0; s < r[i][o].length; s++) - r[i][o][s].svgId_ !== n.svgId_ && - a(r[i][o][s].svg(), l) + r[i][o][s].svgId_ !== n.svgId_ && a(r[i][o][s].svg(), l) else r[i][o].svgId_ !== n.svgId_ && a(r[i][o].svg(), l) else r[i].svgId_ !== n.svgId_ && a(r[i].svg(), l) } @@ -11488,19 +10930,10 @@ r .append('text') .attr('class', 'eurostatmap-legend-label') - .attr( - 'x', - n.boxPadding + - Math.max(n.shapeWidth, n.sepLineLength) + - n.labelOffset - ) + .attr('x', n.boxPadding + Math.max(n.shapeWidth, n.sepLineLength) + n.labelOffset) .attr('y', o + n.shapeHeight) .attr('dominant-baseline', 'middle') - .text( - n.labels - ? n.labels[u] - : s(t.classifier().invertExtent(l)[n.ascending ? 0 : 1]) - ) + .text(n.labels ? n.labels[u] : s(t.classifier().invertExtent(l)[n.ascending ? 0 : 1])) .style('font-size', n.labelFontSize + 'px') .style('font-family', t.fontFamily_) .style('fill', n.fontFill) @@ -11512,10 +10945,7 @@ l() if (n.noData) { var c = - n.boxPadding + - (n.title ? n.titleFontSize + n.boxPadding : 0) + - t.clnb() * n.shapeHeight + - n.boxPadding + n.boxPadding + (n.title ? n.titleFontSize + n.boxPadding : 0) + t.clnb() * n.shapeHeight + n.boxPadding r .append('rect') .attr('x', n.boxPadding) @@ -11526,37 +10956,27 @@ .attr('stroke', 'black') .attr('stroke-width', 0.5) .on('mouseover', function () { - if ( - (yt(this).style('fill', t.nutsrgSelFillSty()), - i(e, 'nd'), - n.map.insetTemplates_) - ) { + if ((yt(this).style('fill', t.nutsrgSelFillSty()), i(e, 'nd'), n.map.insetTemplates_)) { var r = n.map.insetTemplates_ for (var a in r) if (Array.isArray(r[a])) for (var o = 0; o < r[a].length; o++) if (Array.isArray(r[a][o])) for (var s = 0; s < r[a][o].length; s++) - r[a][o][s].svgId_ !== n.svgId_ && - i(r[a][o][s].svg(), 'nd') + r[a][o][s].svgId_ !== n.svgId_ && i(r[a][o][s].svg(), 'nd') else r[a][o].svgId_ !== n.svgId_ && i(r[a][o].svg(), 'nd') else r[a].svgId_ !== n.svgId_ && i(r[a].svg(), 'nd') } }) .on('mouseout', function () { - if ( - (yt(this).style('fill', t.noDataFillStyle()), - a(e, 'nd'), - n.map.insetTemplates_) - ) { + if ((yt(this).style('fill', t.noDataFillStyle()), a(e, 'nd'), n.map.insetTemplates_)) { var r = n.map.insetTemplates_ for (var i in r) if (Array.isArray(r[i])) for (var o = 0; o < r[i].length; o++) if (Array.isArray(r[i][o])) for (var s = 0; s < r[i][o].length; s++) - r[i][o][s].svgId_ !== n.svgId_ && - a(r[i][o][s].svg(), 'nd') + r[i][o][s].svgId_ !== n.svgId_ && a(r[i][o][s].svg(), 'nd') else r[i][o].svgId_ !== n.svgId_ && a(r[i][o].svg(), 'nd') else r[i].svgId_ !== n.svgId_ && a(r[i].svg(), 'nd') } @@ -11822,10 +11242,7 @@ r .append('text') .attr('x', n.colorLegend ? n.colorLegend.labelOffset.x : n.noDataShapeWidth + 5) - .attr( - 'y', - n.colorLegend ? n.colorLegend.shapeHeight / 2 + 1 : n.noDataShapeHeight / 2 + 1 - ) + .attr('y', n.colorLegend ? n.colorLegend.shapeHeight / 2 + 1 : n.noDataShapeHeight / 2 + 1) .attr('dominant-baseline', 'middle') .attr('class', 'eurostatmap-legend-label') .text(i) @@ -11851,8 +11268,7 @@ } function l(t, e, r, i, a) { var o = 'triangle' == n.map.psShape_ || 'diamond' == n.map.psShape_ ? r : r / 2 - 0 == n.sizeLegend._totalD3SymbolsHeight && - (n.sizeLegend._totalD3SymbolsHeight += o + n.boxPadding) + 0 == n.sizeLegend._totalD3SymbolsHeight && (n.sizeLegend._totalD3SymbolsHeight += o + n.boxPadding) var s = t.classifierSize_(t.classifierSize_.domain()[1]), l = s, u = @@ -11875,9 +11291,7 @@ .append('path') .attr('d', p) .attr('transform', function () { - return 'translate(' - .concat(n.sizeLegend.shapeOffset.x, ',') - .concat(n.sizeLegend.shapeOffset.y, ')') + return 'translate('.concat(n.sizeLegend.shapeOffset.x, ',').concat(n.sizeLegend.shapeOffset.y, ')') }) var h = s / 2 + n.sizeLegend.labelOffset.x c.append('text') @@ -11896,21 +11310,14 @@ s = n.boxPadding if ( (t.customSymbols.prevSymb || - ((o = - n.boxPadding + - (n.sizeLegend.title ? n.titleFontSize + n.sizeLegend.titlePadding : 0) + - 20), + ((o = n.boxPadding + (n.sizeLegend.title ? n.titleFontSize + n.sizeLegend.titlePadding : 0) + 20), (t.customSymbols.initialTranslateY = o), (t.customSymbols.prevScale = r)), t.customSymbols.prevSymb) ) { var l = t.customSymbols.prevSymb.node().getBBox() - ;(t.customSymbols.nodeHeights = - t.customSymbols.nodeHeights + l.height * t.customSymbols.prevScale), - (o = - t.customSymbols.initialTranslateY + - t.customSymbols.nodeHeights + - n.sizeLegend.shapePadding * (i - 1)), + ;(t.customSymbols.nodeHeights = t.customSymbols.nodeHeights + l.height * t.customSymbols.prevScale), + (o = t.customSymbols.initialTranslateY + t.customSymbols.nodeHeights + n.sizeLegend.shapePadding * (i - 1)), (t.customSymbols.prevScale = r) } var u = n._sizeLegendNode @@ -11936,9 +11343,7 @@ .concat(n.sizeLegend.shapeOffset.x, ',') .concat(n.sizeLegend.shapeOffset.y, ') scale(') .concat(r, ')') - : 'translate(' - .concat(n.sizeLegend.shapeOffset.x, ',') - .concat(n.sizeLegend.shapeOffset.y, ')') + : 'translate('.concat(n.sizeLegend.shapeOffset.x, ',').concat(n.sizeLegend.shapeOffset.y, ')') }) var c = s + t.classifierSize_(t.classifierSize_.domain()[0]) + n.sizeLegend.labelOffset.x, f = n.sizeLegend.shapeOffset.y / 2 + 1 @@ -11983,9 +11388,7 @@ .concat(n.sizeLegend.shapeOffset.x, ',') .concat(n.sizeLegend.shapeOffset.y, ') scale(') .concat(r, ')') - : 'translate(' - .concat(n.sizeLegend.shapeOffset.x, ',') - .concat(n.sizeLegend.shapeOffset.y, ')') + : 'translate('.concat(n.sizeLegend.shapeOffset.x, ',').concat(n.sizeLegend.shapeOffset.y, ')') }) var c = o + n.map.psBarWidth_ + n.sizeLegend.labelOffset.x, p = r / 2 + n.sizeLegend.labelOffset.y @@ -12085,11 +11488,7 @@ var e = t.classifierSize_.domain() n.sizeLegend.values ? (n._sizeLegendValues = n.sizeLegend.values) - : (n._sizeLegendValues = [ - Math.floor(e[1]), - Math.floor(e[1] / 2), - Math.floor(e[0]), - ]), + : (n._sizeLegendValues = [Math.floor(e[1]), Math.floor(e[1] / 2), Math.floor(e[0])]), !n.sizeLegend.title && n.title && (n.sizeLegend.title = n.title), n.sizeLegend.title && n._sizeLegendNode @@ -12107,9 +11506,7 @@ a = n.boxPadding + 2 * r + - (n.sizeLegend.title - ? n.titleFontSize + n.sizeLegend.titlePadding - : 0) + + (n.sizeLegend.title ? n.titleFontSize + n.sizeLegend.titlePadding : 0) + 20, o = n._sizeLegendNode .append('g') @@ -12175,10 +11572,7 @@ } })(e, n.sizeLegend), (n._colorLegendNode = r.append('g').attr('class', 'color-legend-container')), - n._colorLegendNode.attr( - 'transform', - 'translate(0,'.concat(n._sizeLegendNode.node().getBBox().height, ')') - ), + n._colorLegendNode.attr('transform', 'translate(0,'.concat(n._sizeLegendNode.node().getBBox().height, ')')), e.classifierColor_ && n.colorLegend && (function (t) { @@ -12225,10 +11619,7 @@ n = yt(this.parentNode).attr('fill') yt(this).attr('fill___', n), e.each(function (e, n) { - yt(this.childNodes[0]).attr( - 'fill', - t.nutsrgSelFillSty() - ) + yt(this.childNodes[0]).attr('fill', t.nutsrgSelFillSty()) }), yt(this).style('fill', t.nutsrgSelFillSty()) }) @@ -12259,9 +11650,9 @@ .attr('dominant-baseline', 'middle') .text(function (r) { return e( - t.classifierColor_.invertExtent( - n.ascending ? s + 1 : s - 1 - )[n.ascending ? 0 : 1] + t.classifierColor_.invertExtent(n.ascending ? s + 1 : s - 1)[ + n.ascending ? 0 : 1 + ] ) }) .style('font-size', n.labelFontSize + 'px') @@ -12274,11 +11665,7 @@ ) s() if (n.colorLegend.noData) { - var u = - n.titleFontSize + - n.colorLegend.marginTop + - o * n.colorLegend.shapeHeight + - 20 + var u = n.titleFontSize + n.colorLegend.marginTop + o * n.colorLegend.shapeHeight + 20 a( 0, 0, @@ -12350,11 +11737,7 @@ } class au extends Map { constructor(t, e = su) { - if ( - (super(), - Object.defineProperties(this, { _intern: { value: new Map() }, _key: { value: e } }), - null != t) - ) + if ((super(), Object.defineProperties(this, { _intern: { value: new Map() }, _key: { value: e } }), null != t)) for (const [e, n] of t) this.set(e, n) } get(t) { @@ -12576,19 +11959,15 @@ (e.classToText_ = void 0), (e.tooltip_.textFunction = hu), (e.classifier_ = void 0), - ['classToFillStyle_', 'classToText_', 'noDataFillStyle_', 'tooltipText_', 'classifier_'].forEach( - function (t) { - e[t.substring(0, t.length - 1)] = function (n) { - return arguments.length ? ((e[t] = n), e) : e[t] - } + ['classToFillStyle_', 'classToText_', 'noDataFillStyle_', 'tooltipText_', 'classifier_'].forEach(function (t) { + e[t.substring(0, t.length - 1)] = function (n) { + return arguments.length ? ((e[t] = n), e) : e[t] } - ), + }), t && - ['classToFillStyle', 'classToText', 'noDataFillStyle', 'tooltipText', 'classifier'].forEach( - function (n) { - null != t[n] && e[n](t[n]) - } - ), + ['classToFillStyle', 'classToText', 'noDataFillStyle', 'tooltipText', 'classifier'].forEach(function (n) { + null != t[n] && e[n](t[n]) + }), (e.updateClassification = function () { var t = e.statData().getUniqueValues(), n = r(Array(t.length).keys()) @@ -12608,8 +11987,7 @@ }), (e.updateStyle = function () { if (!e.classToFillStyle()) { - for (var t = {}, n = e.classifier().domain(), r = 0; r < n.length; r++) - t[n[r]] = cu[r % 12] + for (var t = {}, n = e.classifier().domain(), r = 0; r < n.length; r++) t[n[r]] = cu[r % 12] e.classToFillStyle(t) } var i = 'WORLD' == e.geo_ ? 'path.worldrg' : 'path.nutsrg', @@ -12621,9 +11999,7 @@ .attr('fill', function () { var t = yt(this).attr('ecl') return t && 'nd' !== t - ? e.classToFillStyle_[e.classifier().domain()[t]] || - e.noDataFillStyle_ || - 'gray' + ? e.classToFillStyle_[e.classifier().domain()[t]] || e.noDataFillStyle_ || 'gray' : e.noDataFillStyle_ || 'gray' }) .end() @@ -12631,16 +12007,11 @@ function () { a.on('mouseover', function (t, n) { if (e.countriesToShow_ && 'WORLD' !== e.geo_) { - if ( - e.countriesToShow_.includes( - n.properties.id[0] + n.properties.id[1] - ) - ) { + if (e.countriesToShow_.includes(n.properties.id[0] + n.properties.id[1])) { var r = yt(this) r.attr('fill___', r.attr('fill')), r.attr('fill', e.nutsrgSelFillSty_), - e._tooltip && - e._tooltip.mouseover(e.tooltip_.textFunction(n, e)) + e._tooltip && e._tooltip.mouseover(e.tooltip_.textFunction(n, e)) } } else { var i = yt(this) @@ -12651,9 +12022,7 @@ }) .on('mousemove', function (t, n) { e.countriesToShow_ && 'WORLD' !== e.geo_ - ? e.countriesToShow_.includes( - n.properties.id[0] + n.properties.id[1] - ) && + ? e.countriesToShow_.includes(n.properties.id[0] + n.properties.id[1]) && e._tooltip && e._tooltip.mousemove(t) : e._tooltip && e._tooltip.mousemove(t) @@ -12662,8 +12031,7 @@ var t = yt(this) t.attr('fill'), t.attr('fill___') && - (t.attr('fill', t.attr('fill___')), - e._tooltip && e._tooltip.mouseout()) + (t.attr('fill', t.attr('fill___')), e._tooltip && e._tooltip.mouseout()) }) }, function (t) {} @@ -12800,11 +12168,7 @@ .attr('height', o) .attr('fill', s) .on('mouseover', function () { - var a = ( - 'mixed' == n.map.nutsLevel_ - ? e.selectAll('#g_nutsrg') - : e.select('#g_nutsrg') - ) + var a = ('mixed' == n.map.nutsLevel_ ? e.selectAll('#g_nutsrg') : e.select('#g_nutsrg')) .selectAll("[ecl1='" + r + "']") .filter("[ecl2='" + i + "']") a.style('fill', t.nutsrgSelFillSty()), @@ -12814,10 +12178,7 @@ yt(this).style('fill', t.nutsrgSelFillSty()) }) .on('mouseout', function () { - ;('mixed' == n.map.nutsLevel_ - ? e.selectAll('#g_nutsrg') - : e.select('#g_nutsrg') - ) + ;('mixed' == n.map.nutsLevel_ ? e.selectAll('#g_nutsrg') : e.select('#g_nutsrg')) .selectAll("[ecl1='" + r + "']") .filter("[ecl2='" + i + "']") .style('fill', function () { @@ -12880,8 +12241,7 @@ .attr('stroke', n.fontFill) .attr('stroke-width', 1) } - var x = - n.squareSize + n.arrowHeight + n.arrowPadding.x + n.xAxisLabelsOffset.y + n.axisPadding.y + var x = n.squareSize + n.arrowHeight + n.arrowPadding.x + n.xAxisLabelsOffset.y + n.axisPadding.y u .append('path') .attr('class', 'bivariate-axis-arrow') @@ -12928,9 +12288,7 @@ .attr('y', 0 == n.rotation ? -n.labelFontSize : n.labelFontSize + n.arrowHeight / 2) .attr( 'transform', - 0 == n.rotation - ? 'rotate(-90) translate(0,0)' - : 'rotate(90) translate(' + n.labelFontSize / 2 + ',0)' + 0 == n.rotation ? 'rotate(-90) translate(0,0)' : 'rotate(90) translate(' + n.labelFontSize / 2 + ',0)' ) .text(n.label2) .style('font-size', n.labelFontSize + 'px') @@ -12961,14 +12319,8 @@ .attr('marker-units', 'strokeWidth'), n.noData) ) { - var S = - 0 == n.rotation - ? n.noDataYOffset + n.squareSize / n.map.clnb_ + n.arrowHeight / 2 - : n.noDataYOffset - ;(l = - 0 == n.rotation - ? l + n.squareSize + S - : l + 1.4142 * n.squareSize + 2 * n.boxPadding + S), + var S = 0 == n.rotation ? n.noDataYOffset + n.squareSize / n.map.clnb_ + n.arrowHeight / 2 : n.noDataYOffset + ;(l = 0 == n.rotation ? l + n.squareSize + S : l + 1.4142 * n.squareSize + 2 * n.boxPadding + S), i .append('rect') .attr('x', n.boxPadding) @@ -12980,9 +12332,7 @@ .attr('stroke-width', 0.7) .on('mouseover', function () { var r = ( - 'mixed' == n.map.nutsLevel_ - ? e.selectAll('#g_nutsrg') - : e.select('#g_nutsrg') + 'mixed' == n.map.nutsLevel_ ? e.selectAll('#g_nutsrg') : e.select('#g_nutsrg') ).selectAll("[nd='nd']") r.style('fill', t.nutsrgSelFillSty()), r.attr('fill___', function (t) { @@ -12991,10 +12341,7 @@ yt(this).style('fill', t.nutsrgSelFillSty()) }) .on('mouseout', function () { - ;('mixed' == n.map.nutsLevel_ - ? e.selectAll('#g_nutsrg') - : e.select('#g_nutsrg') - ) + ;('mixed' == n.map.nutsLevel_ ? e.selectAll('#g_nutsrg') : e.select('#g_nutsrg')) .selectAll("[nd='nd']") .style('fill', function (t) { yt(this).attr('fill___') @@ -13141,10 +12488,7 @@ } for (var s in a) o(s) if (n.noData) { - var l = - n.boxPadding + - (n.title ? n.titleFontSize + n.boxPadding : 0) + - i * (n.shapeHeight + n.shapePadding) + var l = n.boxPadding + (n.title ? n.titleFontSize + n.boxPadding : 0) + i * (n.shapeHeight + n.shapePadding) r .append('rect') .attr('x', n.boxPadding) @@ -13177,9 +12521,7 @@ .style('font-family', t.fontFamily_) .style('fill', n.fontFill) .on('mouseover', function () { - e.select('#g_nutsrg') - .selectAll("[nd='nd']") - .style('fill', t.nutsrgSelFillSty()) + e.select('#g_nutsrg').selectAll("[nd='nd']").style('fill', t.nutsrgSelFillSty()) }) .on('mouseout', function () { e.select('#g_nutsrg') @@ -13214,8 +12556,7 @@ e) ) for (var r in e) - if ('colorLegend' == r || 'sizeLegend' == r) - for (var i in n[r]) e[r][i] && (n[r][i] = e[r][i]) + if ('colorLegend' == r || 'sizeLegend' == r) for (var i in n[r]) e[r][i] && (n[r][i] = e[r][i]) else n[r] = e[r] return ( (n.update = function () { @@ -13240,17 +12581,11 @@ .style('font-family', t.fontFamily_) .style('fill', n.fontFill) var a = t.sizeClassifier_(St(r.values)), - o = - n.boxPadding + - (r.title ? n.titleFontSize + n.boxPadding + r.titlePadding : 0) + - 2 * a, + o = n.boxPadding + (r.title ? n.titleFontSize + n.boxPadding + r.titlePadding : 0) + 2 * a, s = e .append('g') .attr('fill', 'black') - .attr( - 'transform', - 'translate('.concat(a + n.boxPadding, ',').concat(o, ')') - ) + .attr('transform', 'translate('.concat(a + n.boxPadding, ',').concat(o, ')')) .attr('text-anchor', 'right') .selectAll('g') .data(r.values) @@ -13296,10 +12631,7 @@ e .append('text') .attr('x', n.boxPadding) - .attr( - 'y', - n._sizeLegendHeight + n.legendSpacing + n.boxPadding + n.titleFontSize - ) + .attr('y', n._sizeLegendHeight + n.legendSpacing + n.boxPadding + n.titleFontSize) .text(r.title) .style('font-size', n.titleFontSize + 'px') .style('font-weight', n.titleFontWeight) @@ -13379,10 +12711,7 @@ .attr('stroke', 'black') .attr('stroke-width', 0.5) .on('mouseover', function () { - i - .select('#g_nutsrg') - .selectAll("[nd='nd']") - .style('fill', t.nutsrgSelFillSty()), + i.select('#g_nutsrg').selectAll("[nd='nd']").style('fill', t.nutsrgSelFillSty()), yt(this).style('fill', t.nutsrgSelFillSty()) }) .on('mouseout', function () { @@ -13404,9 +12733,7 @@ .style('font-family', t.fontFamily_) .style('fill', n.fontFill) .on('mouseover', function () { - i.select('#g_nutsrg') - .selectAll("[nd='nd']") - .style('fill', t.nutsrgSelFillSty()) + i.select('#g_nutsrg').selectAll("[nd='nd']").style('fill', t.nutsrgSelFillSty()) }) .on('mouseout', function () { i.select('#g_nutsrg') @@ -13510,30 +12837,22 @@ function () { r.on('mouseover', function (n, r) { if (e.countriesToShow_ && 'WORLD' !== e.geo_) { - if ( - e.countriesToShow_.includes( - r.properties.id[0] + r.properties.id[1] - ) - ) { + if (e.countriesToShow_.includes(r.properties.id[0] + r.properties.id[1])) { var i = yt(this) i.attr('fill___', i.attr('fill')), i.attr('fill', t.nutsrgSelFillSty_), - e._tooltip && - e._tooltip.mouseover(e.tooltip_.textFunction(r, e)) + e._tooltip && e._tooltip.mouseover(e.tooltip_.textFunction(r, e)) } } else { var a = yt(this) a.attr('fill___', a.attr('fill')), a.attr('fill', t.nutsrgSelFillSty_), - e._tooltip && - e._tooltip.mouseover(e.tooltip_.textFunction(r, e)) + e._tooltip && e._tooltip.mouseover(e.tooltip_.textFunction(r, e)) } }) .on('mousemove', function (t, n) { e.countriesToShow_ && 'WORLD' !== e.geo_ - ? e.countriesToShow_.includes( - n.properties.id[0] + n.properties.id[1] - ) && + ? e.countriesToShow_.includes(n.properties.id[0] + n.properties.id[1]) && e._tooltip && e._tooltip.mousemove(t) : e._tooltip && e._tooltip.mousemove(t) @@ -13541,8 +12860,7 @@ .on('mouseout', function () { var e = yt(this) e.attr('fill___') && - (e.attr('fill', e.attr('fill___')), - t._tooltip && t._tooltip.mouseout()) + (e.attr('fill', e.attr('fill___')), t._tooltip && t._tooltip.mouseout()) }) }, function (t) {} @@ -13554,23 +12872,18 @@ .style('display', function (t) { var n = yt(this).attr('ecl'), r = yt(this).attr('lvl') - return (n && - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - )) || + return (n && e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1])) || '0' == r ? 'block' : 'none' }) .style('stroke', function (e) { var n = yt(this).attr('lvl') - if (yt(this).attr('ecl') && '0' !== n) - return t.nutsbnStroke_[parseInt(n)] || '#777' + if (yt(this).attr('ecl') && '0' !== n) return t.nutsbnStroke_[parseInt(n)] || '#777' }) .style('stroke-width', function (e) { var n = yt(this).attr('lvl') - if (yt(this).attr('ecl') && '0' !== n) - return t.nutsbnStrokeWidth_[parseInt(n)] || 0.2 + if (yt(this).attr('ecl') && '0' !== n) return t.nutsbnStrokeWidth_[parseInt(n)] || 0.2 }), e.labelsToShow_.includes('values') && e.updateValuesLabels(t) } @@ -13611,15 +12924,11 @@ : e.colorFun_ }), (e.threshold = function (t) { - return arguments.length - ? ((e.threshold_ = t), e.clnb(t.length + 1), e) - : e.threshold_ + return arguments.length ? ((e.threshold_ = t), e.clnb(t.length + 1), e) : e.threshold_ }), (e.filtersDefinitionFunction = function (t) { return arguments.length - ? ((e.filtersDefinitionFunction_ = t), - e.svg() && e.filtersDefinitionFunction_(e.svg(), e.clnb_), - e) + ? ((e.filtersDefinitionFunction_ = t), e.svg() && e.filtersDefinitionFunction_(e.svg(), e.clnb_), e) : e.filtersDefinitionFunction_ }), t && @@ -13642,11 +12951,8 @@ for (var r = 0; r < e.insetTemplates_[t].length; r++) if (Array.isArray(e.insetTemplates_[t][r])) for (var i = 0; i < e.insetTemplates_[t][r].length; i++) - e.insetTemplates_[t][r][i].svgId_ !== e.svgId_ && - n(e.insetTemplates_[t][r][i]) - else - e.insetTemplates_[t][r].svgId_ !== e.svgId_ && - n(e.insetTemplates_[t][r]) + e.insetTemplates_[t][r][i].svgId_ !== e.svgId_ && n(e.insetTemplates_[t][r][i]) + else e.insetTemplates_[t][r].svgId_ !== e.svgId_ && n(e.insetTemplates_[t][r]) else e.insetTemplates_[t].svgId_ !== e.svgId_ && n(e.insetTemplates_[t]) return n(e), e }), @@ -13657,11 +12963,8 @@ for (var n = 0; n < e.insetTemplates_[t].length; n++) if (Array.isArray(e.insetTemplates_[t][n])) for (var r = 0; r < e.insetTemplates_[t][n].length; r++) - e.insetTemplates_[t][n][r].svgId_ !== e.svgId_ && - i(e.insetTemplates_[t][n][r]) - else - e.insetTemplates_[t][n].svgId_ !== e.svgId_ && - i(e.insetTemplates_[t][n]) + e.insetTemplates_[t][n][r].svgId_ !== e.svgId_ && i(e.insetTemplates_[t][n][r]) + else e.insetTemplates_[t][n].svgId_ !== e.svgId_ && i(e.insetTemplates_[t][n]) else e.insetTemplates_[t].svgId_ !== e.svgId_ && i(e.insetTemplates_[t]) return i(e), e }), @@ -13695,12 +12998,8 @@ t.svg_.selectAll(':not(#insetsgroup) g.symbol > *').remove(), t._centroidFeatures && ((function (t) { - var e = ( - t.svg_ ? t.svg_.select('#zoomgroup' + t.svgId_) : null - ).select('#g_ps'), - n = t.statData('size').getArray() - ? t.statData('size') - : t.statData(), + var e = (t.svg_ ? t.svg_.select('#zoomgroup' + t.svgId_) : null).select('#g_ps'), + n = t.statData('size').getArray() ? t.statData('size') : t.statData(), i = r(t._centroidFeatures).sort(function (t, e) { var r = n.get(t.properties.id), i = n.get(e.properties.id) @@ -13726,11 +13025,7 @@ .data(i) .join('g') .attr('transform', function (e) { - return ( - 'translate(' + - t._projection(e.geometry.coordinates) + - ')' - ) + return 'translate(' + t._projection(e.geometry.coordinates) + ')' }) ) })(t), @@ -13777,9 +13072,8 @@ .attr('transform', function () { return ( this.getBoundingClientRect(), - 'translate('.concat( - -this.getAttribute('width') / 2 - ) + ', -'.concat(this.getAttribute('height'), ')') + 'translate('.concat(-this.getAttribute('width') / 2) + + ', -'.concat(this.getAttribute('height'), ')') ) }) .transition() @@ -13816,8 +13110,7 @@ var r = n.get(t.properties.id) if (0 == r || r) { var i = e.classifierSize_(+r.value) || 0 - if (e.psCustomShape_) - return e.psCustomShape_.size(i * i)() + if (e.psCustomShape_) return e.psCustomShape_.size(i * i)() var a = ru[e.psShape_] || ru.circle return tu() .type(a) @@ -13838,12 +13131,9 @@ var i = n.get(r.properties.id) return i && (i.value || 0 === i || 0 === i.value) && - e.countriesToShow_.includes( - r.properties.id[0] + r.properties.id[1] - ) - ? e.countriesToShow_.includes( - r.properties.id[0] + r.properties.id[1] - ) || 'WORLD' == t.geo_ + e.countriesToShow_.includes(r.properties.id[0] + r.properties.id[1]) + ? e.countriesToShow_.includes(r.properties.id[0] + r.properties.id[1]) || + 'WORLD' == t.geo_ ? 'block' : void 0 : 'none' @@ -13852,12 +13142,9 @@ var i = n.get(r.properties.id) return i && (i.value || 0 === i || 0 === i.value) && - e.countriesToShow_.includes( - r.properties.id[0] + r.properties.id[1] - ) - ? e.countriesToShow_.includes( - r.properties.id[0] + r.properties.id[1] - ) || 'WORLD' == t.geo_ + e.countriesToShow_.includes(r.properties.id[0] + r.properties.id[1]) + ? e.countriesToShow_.includes(r.properties.id[0] + r.properties.id[1]) || + 'WORLD' == t.geo_ ? 'block' : void 0 : 'none' @@ -13869,9 +13156,7 @@ if ( i && i.value && - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) + e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1]) ) return e.countriesToShow_.includes( t.properties.id[0] + t.properties.id[1] @@ -13885,9 +13170,7 @@ if ( i && i.value && - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) + e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1]) ) return (!e.countriesToShow_.includes( t.properties.id[0] + t.properties.id[1] @@ -14021,15 +13304,11 @@ }), (e.psColorFun = function (t) { return arguments.length - ? ((e.psColorFun_ = t), - (e.psClassToFillStyle_ = nu(e.psColorFun_, e.psColors_)), - e) + ? ((e.psColorFun_ = t), (e.psClassToFillStyle_ = nu(e.psColorFun_, e.psColors_)), e) : e.psColorFun_ }), (e.psThreshold = function (t) { - return arguments.length - ? ((e.psThreshold_ = t), e.psClasses(t.length + 1), e) - : e.psThreshold_ + return arguments.length ? ((e.psThreshold_ = t), e.psClasses(t.length + 1), e) : e.psThreshold_ }), (e.updateClassification = function () { if ( @@ -14043,9 +13322,7 @@ o = e.psMaxValue_ ? e.psMaxValue_ : e.statData('size').getMax() if ( ((t = i ? [a, o] : [e.statData().getMin(), e.statData().getMax()]), - e.classifierSize( - e.psSizeFun_().domain(t).range([e.psMinSize_, e.psMaxSize_]) - ), + e.classifierSize(e.psSizeFun_().domain(t).range([e.psMinSize_, e.psMaxSize_])), e.statData('color').getArray()) ) if ('quantile' === e.psClassificationMethod_) { @@ -14076,24 +13353,19 @@ for (var a = 0; a < e.insetTemplates_[t][i].length; a++) e.insetTemplates_[t][i][a].svgId_ !== e.svgId_ && n(e.insetTemplates_[t][i][a]) - else - e.insetTemplates_[t][i].svgId_ !== e.svgId_ && - n(e.insetTemplates_[t][i]) + else e.insetTemplates_[t][i].svgId_ !== e.svgId_ && n(e.insetTemplates_[t][i]) else e.insetTemplates_[t].svgId_ !== e.svgId_ && n(e.insetTemplates_[t]) return n(e), e }), (e.updateValuesLabels = function (t) { - t.svg_.selectAll('g.stat-label > *').remove(), - t.svg_.selectAll('g.stat-label-shadow > *').remove() + t.svg_.selectAll('g.stat-label > *').remove(), t.svg_.selectAll('g.stat-label-shadow > *').remove() var n = t.svg_.selectAll('g.stat-label'), r = t.statData('size').getArray() ? t.statData('size') : t.statData() return ( n .filter(function (t) { if ( - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) || + e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1]) || 'WORLD' == e.geo_ ) { var n = r.get(t.properties.id) @@ -14104,9 +13376,7 @@ .append('text') .text(function (t) { if ( - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) || + e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1]) || 'WORLD' == e.geo_ ) { var n = r.get(t.properties.id) @@ -14119,9 +13389,7 @@ .selectAll('g.stat-label-shadow') .filter(function (t) { if ( - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) || + e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1]) || 'WORLD' == e.geo_ ) { var n = r.get(t.properties.id) @@ -14132,9 +13400,7 @@ .append('text') .text(function (t) { if ( - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) || + e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1]) || 'WORLD' == e.geo_ ) { var n = r.get(t.properties.id) @@ -14154,9 +13420,7 @@ for (var r = 0; r < e.insetTemplates_[t][n].length; r++) e.insetTemplates_[t][n][r].svgId_ !== e.svgId_ && i(e.insetTemplates_[t][n][r]) - else - e.insetTemplates_[t][n].svgId_ !== e.svgId_ && - i(e.insetTemplates_[t][n]) + else e.insetTemplates_[t][n].svgId_ !== e.svgId_ && i(e.insetTemplates_[t][n]) else e.insetTemplates_[t].svgId_ !== e.svgId_ && i(e.insetTemplates_[t]) return e }), @@ -14182,53 +13446,32 @@ .svg() .selectAll(o) .attr('ecl1', function (t) { - if ( - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) - ) { - var n = - e.statData('v1').get(t.properties.id) || - e.statData().get(t.properties.id) + if (e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1])) { + var n = e.statData('v1').get(t.properties.id) || e.statData().get(t.properties.id) if (n) { var r = n.value - return (0 != r && !r) || ':' == r - ? 'nd' - : +e.classifier1_(+r) + return (0 != r && !r) || ':' == r ? 'nd' : +e.classifier1_(+r) } } }) .attr('ecl2', function (t) { - if ( - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) - ) { + if (e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1])) { var n = e.statData('v2').get(t.properties.id) if (n) { var r = n.value - return (0 != r && !r) || ':' == r - ? 'nd' - : +e.classifier2_(+r) + return (0 != r && !r) || ':' == r ? 'nd' : +e.classifier2_(+r) } } }) .attr('nd', function (t) { - if ( - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) - ) { + if (e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1])) { var n = e.statData('v1').get(t.properties.id) || e.statData().get(t.properties.id), r = e.statData('v2').get(t.properties.id) if (n && r) { var i = n.value - return (0 != i && !i) || - ':' == i || - (0 != (i = r.value) && !i) || - ':' == i + return (0 != i && !i) || ':' == i || (0 != (i = r.value) && !i) || ':' == i ? 'nd' : '' } @@ -14239,34 +13482,21 @@ .svg() .selectAll('path.nutsrg0') .attr('ecl1', function (t) { - if ( - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) - ) { + if (e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1])) { var n = - e.statData('v1').get(t.properties.id) || - e.statData().get(t.properties.id) + e.statData('v1').get(t.properties.id) || e.statData().get(t.properties.id) if (n) { var r = n.value - return (0 != r && !r) || ':' == r - ? 'nd' - : +e.classifier1_(+r) + return (0 != r && !r) || ':' == r ? 'nd' : +e.classifier1_(+r) } } }) .attr('ecl2', function (t) { - if ( - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) - ) { + if (e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1])) { var n = e.statData('v2').get(t.properties.id) if (n) { var r = n.value - return (0 != r && !r) || ':' == r - ? 'nd' - : +e.classifier2_(+r) + return (0 != r && !r) || ':' == r ? 'nd' : +e.classifier2_(+r) } } }), @@ -14274,11 +13504,7 @@ ) { var s = (function (t, e, n, r, i) { for (var a = [], o = ze(e, n), s = ze(r, i), l = 0; l < t; l++) { - for ( - var u = l / (t - 1), c = ze(o(u), s(u)), f = [], p = 0; - p < t; - p++ - ) + for (var u = l / (t - 1), c = ze(o(u), s(u)), f = [], p = 0; p < t; p++) f.push(c(p / (t - 1))) a.push(f) } @@ -14315,11 +13541,7 @@ .transition() .duration(e.transitionDuration()) .attr('fill', function (t) { - if ( - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - ) - ) { + if (e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1])) { var n = yt(this).attr('ecl1') if ('nd' === n) return e.noDataFillStyle() || 'gray' var r = yt(this).attr('ecl2') @@ -14336,34 +13558,22 @@ function () { r.on('mouseover', function (n, r) { if (e.countriesToShow_ && 'WORLD' !== e.geo_) { - if ( - e.countriesToShow_.includes( - r.properties.id[0] + r.properties.id[1] - ) - ) { + if (e.countriesToShow_.includes(r.properties.id[0] + r.properties.id[1])) { var i = yt(this) i.attr('fill___', i.attr('fill')), i.attr('fill', t.nutsrgSelFillSty_), - e._tooltip && - e._tooltip.mouseover( - e.tooltip_.textFunction(r, e) - ) + e._tooltip && e._tooltip.mouseover(e.tooltip_.textFunction(r, e)) } } else { var a = yt(this) a.attr('fill___', a.attr('fill')), a.attr('fill', t.nutsrgSelFillSty_), - e._tooltip && - e._tooltip.mouseover( - e.tooltip_.textFunction(r, e) - ) + e._tooltip && e._tooltip.mouseover(e.tooltip_.textFunction(r, e)) } }) .on('mousemove', function (t, n) { e.countriesToShow_ && 'WORLD' !== e.geo_ - ? e.countriesToShow_.includes( - n.properties.id[0] + n.properties.id[1] - ) && + ? e.countriesToShow_.includes(n.properties.id[0] + n.properties.id[1]) && e._tooltip && e._tooltip.mousemove(t) : e._tooltip && e._tooltip.mousemove(t) @@ -14371,8 +13581,7 @@ .on('mouseout', function () { var e = yt(this) e.attr('fill___') && - (e.attr('fill', e.attr('fill___')), - t._tooltip && t._tooltip.mouseout()) + (e.attr('fill', e.attr('fill___')), t._tooltip && t._tooltip.mouseout()) }) }, function (t) {} @@ -14387,9 +13596,7 @@ i = yt(this).attr('lvl') return (n && r && - e.countriesToShow_.includes( - t.properties.id[0] + t.properties.id[1] - )) || + e.countriesToShow_.includes(t.properties.id[0] + t.properties.id[1])) || '0' == i ? 'block' : 'none' @@ -14398,15 +13605,13 @@ var n = yt(this).attr('lvl'), r = yt(this).attr('ecl1'), i = yt(this).attr('ecl2') - if (r && i && '0' !== n) - return e.nutsbnStroke_[parseInt(n)] || '#777' + if (r && i && '0' !== n) return e.nutsbnStroke_[parseInt(n)] || '#777' }) .style('stroke-width', function (t) { var n = yt(this).attr('lvl'), r = yt(this).attr('ecl1'), i = yt(this).attr('ecl2') - if (r && i && '0' !== n) - return e.nutsbnStrokeWidth_[parseInt(n)] || 0.2 + if (r && i && '0' !== n) return e.nutsbnStrokeWidth_[parseInt(n)] || 0.2 }) } } @@ -14456,12 +13661,8 @@ for (var i = 0; i < e.insetTemplates_[t][r].length; i++) e.insetTemplates_[t][r][i].svgId_ !== e.svgId_ && n(e.insetTemplates_[t][r][i]) - else - e.insetTemplates_[t][r].svgId_ !== e.svgId_ && - n(e.insetTemplates_[t][r]) - else - e.insetTemplates_[t].svgId_ !== e.svgId_ && - n(e.insetTemplates_[t]) + else e.insetTemplates_[t][r].svgId_ !== e.svgId_ && n(e.insetTemplates_[t][r]) + else e.insetTemplates_[t].svgId_ !== e.svgId_ && n(e.insetTemplates_[t]) return n(e), e }), (e.updateStyle = function () { @@ -14473,12 +13674,8 @@ for (var r = 0; r < e.insetTemplates_[t][n].length; r++) e.insetTemplates_[t][n][r].svgId_ !== e.svgId_ && i(e.insetTemplates_[t][n][r]) - else - e.insetTemplates_[t][n].svgId_ !== e.svgId_ && - i(e.insetTemplates_[t][n]) - else - e.insetTemplates_[t].svgId_ !== e.svgId_ && - i(e.insetTemplates_[t]) + else e.insetTemplates_[t][n].svgId_ !== e.svgId_ && i(e.insetTemplates_[t][n]) + else e.insetTemplates_[t].svgId_ !== e.svgId_ && i(e.insetTemplates_[t]) return i(e), e }), (e.getLegendConstructor = function () { @@ -14533,8 +13730,7 @@ for (var c in t) u[c] = t[c] for (var f in ((u.filters = {}), t.filters)) u.filters[f] = t.filters[f] e.stat(l, u), - o && - ((e.catColors_ = e.catColors_ || {}), (e.catColors_[l] = o[s])), + o && ((e.catColors_ = e.catColors_ || {}), (e.catColors_[l] = o[s])), a && ((e.catLabels_ = e.catLabels_ || {}), (e.catLabels_[l] = a[s])) } return (n = i), e @@ -14572,8 +13768,7 @@ .selectAll('path.nutsrg') .attr('fill', function (t) { var n = t.properties.id - if (!e.countriesToShow_.includes(n[0] + n[1])) - return e.nutsrgFillStyle_ + if (!e.countriesToShow_.includes(n[0] + n[1])) return e.nutsrgFillStyle_ var i = r(n) if (!i) return e.noDataFillStyle() || 'gray' var a = e @@ -14586,10 +13781,7 @@ .attr('height', 1) .attr('patternUnits', 'userSpaceOnUse') e.stripeOrientation() && - a.attr( - 'patternTransform', - 'rotate(' + e.stripeOrientation() + ')' - ), + a.attr('patternTransform', 'rotate(' + e.stripeOrientation() + ')'), a .append('rect') .attr('x', 0) @@ -14630,28 +13822,17 @@ .selectAll(i) .on('mouseover', function (t, n) { if (e.countriesToShow_ && 'WORLD' !== e.geo_) { - if ( - e.countriesToShow_.includes( - n.properties.id[0] + n.properties.id[1] - ) - ) { + if (e.countriesToShow_.includes(n.properties.id[0] + n.properties.id[1])) { var r = yt(this) r.attr('fill___', r.attr('fill')), r.attr('fill', e.nutsrgSelFillSty_), - e._tooltip && - e._tooltip.mouseover( - e.tooltip_.textFunction(n, e) - ) + e._tooltip && e._tooltip.mouseover(e.tooltip_.textFunction(n, e)) } - } else - e._tooltip && - e._tooltip.mouseover(e.tooltip_.textFunction(n, e)) + } else e._tooltip && e._tooltip.mouseover(e.tooltip_.textFunction(n, e)) }) .on('mousemove', function (t, n) { e.countriesToShow_ && 'WORLD' !== e.geo_ - ? e.countriesToShow_.includes( - n.properties.id[0] + n.properties.id[1] - ) && + ? e.countriesToShow_.includes(n.properties.id[0] + n.properties.id[1]) && e._tooltip && e._tooltip.mousemove(t) : e._tooltip && e._tooltip.mousemove(t) @@ -14660,8 +13841,7 @@ var t = yt(this) t.attr('fill'), t.attr('fill___') && - (t.attr('fill', t.attr('fill___')), - e._tooltip && e._tooltip.mouseout()) + (t.attr('fill', t.attr('fill___')), e._tooltip && e._tooltip.mouseout()) }), e ) @@ -14674,15 +13854,7 @@ i.html(''), i.selectAll('*').remove(), t.properties.id - ? i - .append('div') - .html( - '' + - t.properties.na + - ' (' + - t.properties.id + - ')
' - ) + ? i.append('div').html('' + t.properties.na + ' (' + t.properties.id + ')
') : i.append('div').html('' + t.properties.na + '
') var a = [], o = r(t.properties.id) @@ -14782,9 +13954,7 @@ var d = {} for (var g in t) d[g] = t[g] for (var _ in ((d.filters = {}), t.filters)) d.filters[_] = t.filters[_] - e.stat(l, d), - (e.catColors_.other = e.pieOtherColor_), - (e.catLabels_.other = e.pieOtherText_) + e.stat(l, d), (e.catColors_.other = e.pieOtherColor_), (e.catLabels_.other = e.pieOtherText_) } return e }), @@ -14794,19 +13964,11 @@ if (Array.isArray(e.insetTemplates_[t])) for (var n = 0; n < e.insetTemplates_[t].length; n++) if (Array.isArray(e.insetTemplates_[t][n])) - for ( - var r = 0; - r < e.insetTemplates_[t][n].length; - r++ - ) + for (var r = 0; r < e.insetTemplates_[t][n].length; r++) e.insetTemplates_[t][n][r].svgId_ !== e.svgId_ && i(e.insetTemplates_[t][n][r]) - else - e.insetTemplates_[t][n].svgId_ !== e.svgId_ && - i(e.insetTemplates_[t][n]) - else - e.insetTemplates_[t].svgId_ !== e.svgId_ && - i(e.insetTemplates_[t]) + else e.insetTemplates_[t][n].svgId_ !== e.svgId_ && i(e.insetTemplates_[t][n]) + else e.insetTemplates_[t].svgId_ !== e.svgId_ && i(e.insetTemplates_[t]) return i(e), e }) var i = function (t) { @@ -14829,18 +13991,14 @@ }), Fs(i)) return ( - isNaN(a[0]) || - (e.sizeClassifier_ = $s() - .domain(a) - .range([e.pieMinRadius_, e.pieMaxRadius_])), + isNaN(a[0]) || (e.sizeClassifier_ = $s().domain(a).range([e.pieMinRadius_, e.pieMaxRadius_])), e ) } e.updateStyle = function () { if (!e.catColors_) { e.catColors({}) - for (var t = 0; t < n.length; t++) - e.catColors_[n[t]] = schemeCategory10[t % 10] + for (var t = 0; t < n.length; t++) e.catColors_[n[t]] = schemeCategory10[t % 10] } e.catLabels_ = e.catLabels_ || {} var r = [] @@ -14858,34 +14016,22 @@ .selectAll(s) .on('mouseover', function (t, n) { if (e.countriesToShow_ && 'WORLD' !== e.geo_) { - if ( - e.countriesToShow_.includes( - n.properties.id[0] + n.properties.id[1] - ) - ) { + if (e.countriesToShow_.includes(n.properties.id[0] + n.properties.id[1])) { var r = yt(this) r.attr('fill___', r.attr('fill')), r.attr('fill', e.nutsrgSelFillSty_), - e._tooltip && - e._tooltip.mouseover( - e.tooltip_.textFunction(n, e) - ) + e._tooltip && e._tooltip.mouseover(e.tooltip_.textFunction(n, e)) } } else { var i = yt(this) i.attr('fill___', i.attr('fill')), i.attr('fill', e.nutsrgSelFillSty_), - e._tooltip && - e._tooltip.mouseover( - e.tooltip_.textFunction(n, e) - ) + e._tooltip && e._tooltip.mouseover(e.tooltip_.textFunction(n, e)) } }) .on('mousemove', function (t, n) { e.countriesToShow_ && 'WORLD' !== e.geo_ - ? e.countriesToShow_.includes( - n.properties.id[0] + n.properties.id[1] - ) && + ? e.countriesToShow_.includes(n.properties.id[0] + n.properties.id[1]) && e._tooltip && e._tooltip.mousemove(t) : e._tooltip && e._tooltip.mousemove(t) @@ -14894,8 +14040,7 @@ var t = yt(this) t.attr('fill'), t.attr('fill___') && - (t.attr('fill', t.attr('fill___')), - e._tooltip && e._tooltip.mouseout()) + (t.attr('fill', t.attr('fill___')), e._tooltip && e._tooltip.mouseout()) }), r.forEach(function (t) { var n = [], @@ -14956,19 +14101,13 @@ var i, a = 0 if (r) - !(i = e.statData(r).get(t)) || - (0 != i.value && !i.value) || - isNaN(i.value) + !(i = e.statData(r).get(t)) || (0 != i.value && !i.value) || isNaN(i.value) ? e.showOnlyWhenComplete() && (a = void 0) : (a = i.value) else for (var o = 0; o < n.length; o++) { var s = n[o] - if ( - !(i = e.statData(s).get(t)) || - (0 != i.value && !i.value) || - isNaN(i.value) - ) { + if (!(i = e.statData(s).get(t)) || (0 != i.value && !i.value) || isNaN(i.value)) { if (e.showOnlyWhenComplete()) return } else a += i.value } @@ -15049,10 +14188,7 @@ n = d.centroid(t), r = d.centroid(t), i = t.startAngle + (t.endAngle - t.startAngle) / 2 - return ( - (r[0] = 0.95 * c * (i < Math.PI ? 1 : -1)), - [e, n, r] - ) + return (r[0] = 0.95 * c * (i < Math.PI ? 1 : -1)), [e, n, r] } }), f @@ -15069,39 +14205,26 @@ .attr('transform', function (t) { var e = d.centroid(t), n = t.startAngle + (t.endAngle - t.startAngle) / 2 - return ( - (e[0] = 0.99 * c * (n < Math.PI ? 1 : -1)), - 'translate(' + e + ')' - ) + return (e[0] = 0.99 * c * (n < Math.PI ? 1 : -1)), 'translate(' + e + ')' }) .style('text-anchor', function (t) { - return t.startAngle + (t.endAngle - t.startAngle) / 2 < - Math.PI + return t.startAngle + (t.endAngle - t.startAngle) / 2 < Math.PI ? 'start' : 'end' }) .style('font-size', '12px') var _ = document.createElement('div') - ;(_.style.padding = '10px'), - (_.style.paddingTop = '0px'), - (_.style.fontSize = '13px') + ;(_.style.padding = '10px'), (_.style.paddingTop = '0px'), (_.style.fontSize = '13px') for (var y = 0; y < n.length; y++) { var v = n[y], m = e.statData(v).get(t.properties.id) if (m && m.value) { - var x = - '' + - e.catLabels_[v] + - ': ' + - m.value.toFixed() + - '
' + var x = '' + e.catLabels_[v] + ': ' + m.value.toFixed() + '
' _.innerHTML = _.innerHTML + x } } var b = o(t.properties.id) - ;(_.innerHTML = - _.innerHTML + - 'Total: '.concat(b.toFixed(), '
')), + ;(_.innerHTML = _.innerHTML + 'Total: '.concat(b.toFixed(), '
')), i.node().appendChild(_) } else i.append('div').html(e.noDataText()) }), @@ -15166,12 +14289,8 @@ t.filters.time = o var s = {} for (var l in t) s[l] = t[l] - for (var u in ((s.filters = {}), t.filters)) - s.filters[u] = t.filters[u] - e.stat(o, s), - i && - ((e.catLabels_ = e.catLabels_ || {}), - (e.catLabels_[o] = i[a])) + for (var u in ((s.filters = {}), t.filters)) s.filters[u] = t.filters[u] + e.stat(o, s), i && ((e.catLabels_ = e.catLabels_ || {}), (e.catLabels_[o] = i[a])) } return (n = r), e }) @@ -15219,9 +14338,7 @@ .selectAll('#g_ps') .selectAll('g.symbol') .attr('id', function (e) { - return ( - t.push(e.properties.id), 'spark_' + e.properties.id - ) + return t.push(e.properties.id), 'spark_' + e.properties.id }), 'WORLD' == e.geo_ ? 'path.worldrg' : 'path.nutsrg') return ( @@ -15232,23 +14349,15 @@ if (r(n.properties.id)) if (e.countriesToShow_) { if ( - e.countriesToShow_.includes( - n.properties.id[0] + n.properties.id[1] - ) + e.countriesToShow_.includes(n.properties.id[0] + n.properties.id[1]) ) { var i = yt(this) i.attr('fill___', i.attr('fill')), i.attr('fill', e.nutsrgSelFillSty_), e._tooltip && - e._tooltip.mouseover( - e.tooltip_.textFunction(n, e) - ) + e._tooltip.mouseover(e.tooltip_.textFunction(n, e)) } - } else - e._tooltip && - e._tooltip.mouseover( - e.tooltip_.textFunction(n, e) - ) + } else e._tooltip && e._tooltip.mouseover(e.tooltip_.textFunction(n, e)) }) .on('mousemove', function (t, n) { r(n.properties.id) && @@ -15264,8 +14373,7 @@ var t = yt(this) t.attr('fill'), t.attr('fill___') && - (t.attr('fill', t.attr('fill___')), - e._tooltip && e._tooltip.mouseout()) + (t.attr('fill', t.attr('fill___')), e._tooltip && e._tooltip.mouseout()) }), t.forEach(function (t) { var i = e.svg().select('#spark_' + t), @@ -15318,10 +14426,7 @@ } : e.sparkLineColor_ ) - .attr( - 'stroke-width', - e.sparkLineStrokeWidth_ + 'px' - ) + .attr('stroke-width', e.sparkLineStrokeWidth_ + 'px') .attr('opacity', e.sparkLineOpacity_) .attr('fill-opacity', 0.3) .attr('stroke', 'none') @@ -15337,10 +14442,7 @@ }) ) .attr('transform', function (t) { - return 'translate(0,-'.concat( - o / 2, - ')' - ) + return 'translate(0,-'.concat(o / 2, ')') }), t .append('path') @@ -15355,10 +14457,7 @@ } : e.sparkLineColor_ ) - .attr( - 'stroke-width', - e.sparkLineStrokeWidth_ + 'px' - ) + .attr('stroke-width', e.sparkLineStrokeWidth_ + 'px') .attr( 'd', wl() @@ -15397,11 +14496,7 @@ var i = function (t) { for (var r, i = 0, a = 0; a < n.length; a++) { var o = n[a] - if ( - !(r = e.statData(o).get(t)) || - (0 != r.value && !r.value) || - isNaN(r.value) - ) { + if (!(r = e.statData(o).get(t)) || (0 != r.value && !r.value) || isNaN(r.value)) { if (e.showOnlyWhenComplete()) return } else r.value > i && (i = r.value) } @@ -15418,13 +14513,7 @@ t.properties.id ? a .append('div') - .html( - '' + - t.properties.na + - ' (' + - t.properties.id + - ')
' - ) + .html('' + t.properties.na + ' (' + t.properties.id + ')
') : a.append('div').html('' + t.properties.na + '
') var o = e.sparkTooltipChart_.height, s = e.sparkTooltipChart_.width, @@ -15447,11 +14536,7 @@ t.append('g') .attr('class', 'axis') .attr('transform', 'translate(0,' + a + ')') - .call( - ((o = u), Ns(3, o)) - .ticks(n.length) - .tickFormat(nn('.0f')) - ) + .call(((o = u), Ns(3, o)).ticks(n.length).tickFormat(nn('.0f'))) .selectAll('text') .style('text-anchor', 'end') .attr('dx', '-.8em') @@ -15548,10 +14633,7 @@ .attr('width', s + l.left + l.right) .attr('height', o + l.top + l.bottom) .append('g') - .attr( - 'transform', - 'translate(' + l.left + ',' + l.top + ')' - ), + .attr('transform', 'translate(' + l.left + ',' + l.top + ')'), u, s, o @@ -15788,7 +14870,7 @@ coastalMarginColor: '#c2daed', }, map = eurostatmap - .map('ch') + .map('choropleth') .classifMethod(mapConfig.classifMethod) .colors(mapConfig.colors) .threshold(mapConfig.thresholds) @@ -15822,9 +14904,7 @@ a.push( `\n
\n \n \n \n \n \n \n
\n ${ ((l = i.value), l.toLocaleString('en').replace(/,/gi, ' ')) - } ${ - o || '' - }\n
\n
\n ` + } ${o || ''}\n \n \n \n \n \n ` ), a.join('') ) diff --git a/examples/basic.html b/examples/basic.html index 9a65dc84..2a75e00b 100644 --- a/examples/basic.html +++ b/examples/basic.html @@ -11,7 +11,7 @@