@carbon/charts 1.16.4 → 1.16.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -0
- package/dist/{_baseEach-DHzZsRNB.mjs → _baseEach-Bp7pBkX8.mjs} +2 -2
- package/dist/{_baseEach-DHzZsRNB.mjs.map → _baseEach-Bp7pBkX8.mjs.map} +1 -1
- package/dist/{angle-utils-D8sXyiIj.mjs → angle-utils-BCx3SRS2.mjs} +2 -2
- package/dist/{angle-utils-D8sXyiIj.mjs.map → angle-utils-BCx3SRS2.mjs.map} +1 -1
- package/dist/chart.d.ts +5 -0
- package/dist/charts/alluvial.d.ts +5 -0
- package/dist/charts/area-stacked.d.ts +5 -0
- package/dist/charts/area.d.ts +5 -0
- package/dist/charts/bar-grouped.d.ts +5 -0
- package/dist/charts/bar-simple.d.ts +5 -0
- package/dist/charts/bar-stacked.d.ts +5 -0
- package/dist/charts/boxplot.d.ts +5 -0
- package/dist/charts/bubble.d.ts +5 -0
- package/dist/charts/bullet.d.ts +5 -0
- package/dist/charts/choropleth.d.ts +5 -0
- package/dist/charts/circle-pack.d.ts +5 -0
- package/dist/charts/combo.d.ts +5 -0
- package/dist/charts/donut.d.ts +5 -0
- package/dist/charts/gauge.d.ts +5 -0
- package/dist/charts/heatmap.d.ts +5 -0
- package/dist/charts/histogram.d.ts +5 -0
- package/dist/charts/line.d.ts +5 -0
- package/dist/charts/lollipop.d.ts +5 -0
- package/dist/charts/meter.d.ts +5 -0
- package/dist/charts/pie.d.ts +5 -0
- package/dist/charts/radar.d.ts +5 -0
- package/dist/charts/scatter.d.ts +5 -0
- package/dist/charts/tree.d.ts +5 -0
- package/dist/charts/treemap.d.ts +5 -0
- package/dist/charts/wordcloud.d.ts +5 -0
- package/dist/{choropleth-ChNZz853.mjs → choropleth-B7eXF9sA.mjs} +60 -112
- package/dist/choropleth-B7eXF9sA.mjs.map +1 -0
- package/dist/{color-scale-utils-C93P4hee.mjs → color-scale-utils-BaTmNvWt.mjs} +7 -12
- package/dist/{color-scale-utils-C93P4hee.mjs.map → color-scale-utils-BaTmNvWt.mjs.map} +1 -1
- package/dist/components/essentials/title-meter.d.ts +0 -1
- package/dist/components/index.mjs +1 -1
- package/dist/demo/index.mjs +19 -20
- package/dist/demo/index.mjs.map +1 -1
- package/dist/index.mjs +138 -8
- package/dist/index.mjs.map +1 -1
- package/dist/interfaces/layout.d.ts +28 -3
- package/dist/interfaces/services.d.ts +39 -0
- package/dist/model/cartesian-charts.d.ts +7 -1
- package/dist/model/circle-pack.d.ts +6 -5
- package/dist/model/heatmap.d.ts +7 -1
- package/dist/model/index.mjs +1 -1
- package/dist/model/model.d.ts +15 -3
- package/dist/model/tree.d.ts +9 -2
- package/dist/services/index.mjs +3 -3
- package/dist/umd/bundle.umd.js +1 -1
- package/dist/umd/bundle.umd.js.map +1 -1
- package/dist/{wordcloud-KxSjz0Gg.mjs → wordcloud-BsEQRUwL.mjs} +50 -18
- package/dist/wordcloud-BsEQRUwL.mjs.map +1 -0
- package/dist/{zoom-B7KfNcH9.mjs → zoom-E2POxw6n.mjs} +8 -13
- package/dist/{zoom-B7KfNcH9.mjs.map → zoom-E2POxw6n.mjs.map} +1 -1
- package/package.json +5 -5
- package/dist/choropleth-ChNZz853.mjs.map +0 -1
- package/dist/wordcloud-KxSjz0Gg.mjs.map +0 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { B as Ys, af as Ba, h as Ga, o as qs, p as Ks, a6 as Ha, _ as Ua, ag as $a, ah as Fa, m as v, n as Me, x as ut, U as fs, A as ne, s as he, ai as Lt, Z as we, W as za, z as Js, t as Wa, aj as Fe, c as yn, b as En, F as ke, ak as Tt, al as He, G as $e, O as Ue, am as ja, H as ct, i as Xa, Q as te, J as Ae, an as Se, ao as Za, a as Ya, P as me, L as yt, K as Rt, ap as an, v as qa, aq as vs, R as je } from "./color-scale-utils-
|
|
1
|
+
import { B as Ys, af as Ba, h as Ga, o as qs, p as Ks, a6 as Ha, _ as Ua, ag as $a, ah as Fa, m as v, n as Me, x as ut, U as fs, A as ne, s as he, ai as Lt, Z as we, W as za, z as Js, t as Wa, aj as Fe, c as yn, b as En, F as ke, ak as Tt, al as He, G as $e, O as Ue, am as ja, H as ct, i as Xa, Q as te, J as Ae, an as Se, ao as Za, a as Ya, P as me, L as yt, K as Rt, ap as an, v as qa, aq as vs, R as je } from "./color-scale-utils-BaTmNvWt.mjs";
|
|
2
2
|
import { select as T, pointer as qt, brushX as Qs, scaleTime as Ka, extent as Kt, area as Gn, line as Hn, axisBottom as Un, axisLeft as ea, axisTop as Ja, axisRight as Qa, scaleLinear as qe, arc as At, easeLinear as ei, path as $n, interpolateNumber as ta, quantize as ti, scaleBand as Fn, hierarchy as zn, pack as ni, pie as si, interpolate as ai, interpolateRound as ii, min as bn, max as ys, lineRadial as ri, curveLinearClosed as oi, cluster as li, tree as ci, linkHorizontal as di, treemap as hi, hsl as na, color as sa, geoPath as ui, geoNaturalEarth1 as pi, geoMercator as gi, geoEquirectangular as mi, geoConicEquidistant as fi, geoConicEqualArea as vi, geoAlbers as yi, geoEqualEarth as Ei } from "d3";
|
|
3
|
-
import { t as Ht, D as S, c as Sn, G as Es, a as bi, p as le, r as bs, b as Si } from "./angle-utils-
|
|
3
|
+
import { t as Ht, D as S, c as Sn, G as Es, a as bi, p as le, r as bs, b as Si } from "./angle-utils-BCx3SRS2.mjs";
|
|
4
4
|
import { y as j, _ as f, K as ie, r as We, q as st, L as Oi, A as Ce, m as z, s as Xe, V as dt, S as ge, e as B, Z as at, i as xe, f as Ss, J as rn, d as Ti, F as kt, n as on, H as ln, C as cn, p as Dt, b as Os, D as dn, Q as xi, x as Ze, $ as Pt, N as hn } from "./enums-DwsxZqjR.mjs";
|
|
5
5
|
import { sankey as Li, sankeyLinkHorizontal as Ai, sankeyJustify as wi, sankeyLeft as Mi, sankeyRight as Ci } from "d3-sankey";
|
|
6
6
|
import { R as X } from "./a11y-ePqvrObQ.mjs";
|
|
7
|
-
import { b as aa } from "./_baseEach-
|
|
7
|
+
import { b as aa } from "./_baseEach-Bp7pBkX8.mjs";
|
|
8
8
|
import _i from "d3-cloud";
|
|
9
9
|
function Ii(o, e, t, n) {
|
|
10
10
|
for (var s = -1, a = o == null ? 0 : o.length; ++s < a; )
|
|
@@ -734,8 +734,7 @@ function xa() {
|
|
|
734
734
|
!(us(b) && (Q.tagNameCheck instanceof RegExp && be(Q.tagNameCheck, b) || Q.tagNameCheck instanceof Function && Q.tagNameCheck(b)) && (Q.attributeNameCheck instanceof RegExp && be(Q.attributeNameCheck, D) || Q.attributeNameCheck instanceof Function && Q.attributeNameCheck(D)) || // Alternative, second condition checks if it's an `is`-attribute, AND
|
|
735
735
|
// the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
|
|
736
736
|
D === "is" && Q.allowCustomizedBuiltInElements && (Q.tagNameCheck instanceof RegExp && be(Q.tagNameCheck, G) || Q.tagNameCheck instanceof Function && Q.tagNameCheck(G)))
|
|
737
|
-
)
|
|
738
|
-
return !1;
|
|
737
|
+
) return !1;
|
|
739
738
|
} else if (!en[D]) {
|
|
740
739
|
if (!be(ae, bt(G, q, ""))) {
|
|
741
740
|
if (!((D === "src" || D === "xlink:href" || D === "href") && b !== "script" && kr(G, "data:") === 0 && Jn[b])) {
|
|
@@ -1394,22 +1393,17 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
1394
1393
|
}
|
|
1395
1394
|
function to(o, e) {
|
|
1396
1395
|
if (o) {
|
|
1397
|
-
if (typeof o == "string")
|
|
1398
|
-
return xn(o, e);
|
|
1396
|
+
if (typeof o == "string") return xn(o, e);
|
|
1399
1397
|
var t = Object.prototype.toString.call(o).slice(8, -1);
|
|
1400
|
-
if (t === "Object" && o.constructor && (t = o.constructor.name), t === "Map" || t === "Set")
|
|
1401
|
-
|
|
1402
|
-
if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))
|
|
1403
|
-
return xn(o, e);
|
|
1398
|
+
if (t === "Object" && o.constructor && (t = o.constructor.name), t === "Map" || t === "Set") return Array.from(o);
|
|
1399
|
+
if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)) return xn(o, e);
|
|
1404
1400
|
}
|
|
1405
1401
|
}
|
|
1406
1402
|
function no(o) {
|
|
1407
|
-
if (typeof Symbol < "u" && o[Symbol.iterator] != null || o["@@iterator"] != null)
|
|
1408
|
-
return Array.from(o);
|
|
1403
|
+
if (typeof Symbol < "u" && o[Symbol.iterator] != null || o["@@iterator"] != null) return Array.from(o);
|
|
1409
1404
|
}
|
|
1410
1405
|
function so(o) {
|
|
1411
|
-
if (Array.isArray(o))
|
|
1412
|
-
return xn(o);
|
|
1406
|
+
if (Array.isArray(o)) return xn(o);
|
|
1413
1407
|
}
|
|
1414
1408
|
function xn(o, e) {
|
|
1415
1409
|
(e == null || e > o.length) && (e = o.length);
|
|
@@ -1500,10 +1494,8 @@ function Aa(o) {
|
|
|
1500
1494
|
return o;
|
|
1501
1495
|
}
|
|
1502
1496
|
function ho() {
|
|
1503
|
-
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham)
|
|
1504
|
-
|
|
1505
|
-
if (typeof Proxy == "function")
|
|
1506
|
-
return !0;
|
|
1497
|
+
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
|
|
1498
|
+
if (typeof Proxy == "function") return !0;
|
|
1507
1499
|
try {
|
|
1508
1500
|
return Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1509
1501
|
})), !0;
|
|
@@ -1627,10 +1619,8 @@ function bo(o) {
|
|
|
1627
1619
|
return o;
|
|
1628
1620
|
}
|
|
1629
1621
|
function So() {
|
|
1630
|
-
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham)
|
|
1631
|
-
|
|
1632
|
-
if (typeof Proxy == "function")
|
|
1633
|
-
return !0;
|
|
1622
|
+
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
|
|
1623
|
+
if (typeof Proxy == "function") return !0;
|
|
1634
1624
|
try {
|
|
1635
1625
|
return Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1636
1626
|
})), !0;
|
|
@@ -1714,22 +1704,17 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
1714
1704
|
}
|
|
1715
1705
|
function Lo(o, e) {
|
|
1716
1706
|
if (o) {
|
|
1717
|
-
if (typeof o == "string")
|
|
1718
|
-
return _n(o, e);
|
|
1707
|
+
if (typeof o == "string") return _n(o, e);
|
|
1719
1708
|
var t = Object.prototype.toString.call(o).slice(8, -1);
|
|
1720
|
-
if (t === "Object" && o.constructor && (t = o.constructor.name), t === "Map" || t === "Set")
|
|
1721
|
-
|
|
1722
|
-
if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))
|
|
1723
|
-
return _n(o, e);
|
|
1709
|
+
if (t === "Object" && o.constructor && (t = o.constructor.name), t === "Map" || t === "Set") return Array.from(o);
|
|
1710
|
+
if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)) return _n(o, e);
|
|
1724
1711
|
}
|
|
1725
1712
|
}
|
|
1726
1713
|
function Ao(o) {
|
|
1727
|
-
if (typeof Symbol < "u" && o[Symbol.iterator] != null || o["@@iterator"] != null)
|
|
1728
|
-
return Array.from(o);
|
|
1714
|
+
if (typeof Symbol < "u" && o[Symbol.iterator] != null || o["@@iterator"] != null) return Array.from(o);
|
|
1729
1715
|
}
|
|
1730
1716
|
function wo(o) {
|
|
1731
|
-
if (Array.isArray(o))
|
|
1732
|
-
return _n(o);
|
|
1717
|
+
if (Array.isArray(o)) return _n(o);
|
|
1733
1718
|
}
|
|
1734
1719
|
function _n(o, e) {
|
|
1735
1720
|
(e == null || e > o.length) && (e = o.length);
|
|
@@ -1795,10 +1780,8 @@ function Do(o) {
|
|
|
1795
1780
|
return o;
|
|
1796
1781
|
}
|
|
1797
1782
|
function Po() {
|
|
1798
|
-
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham)
|
|
1799
|
-
|
|
1800
|
-
if (typeof Proxy == "function")
|
|
1801
|
-
return !0;
|
|
1783
|
+
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
|
|
1784
|
+
if (typeof Proxy == "function") return !0;
|
|
1802
1785
|
try {
|
|
1803
1786
|
return Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1804
1787
|
})), !0;
|
|
@@ -1989,10 +1972,8 @@ function Fo(o) {
|
|
|
1989
1972
|
return o;
|
|
1990
1973
|
}
|
|
1991
1974
|
function zo() {
|
|
1992
|
-
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham)
|
|
1993
|
-
|
|
1994
|
-
if (typeof Proxy == "function")
|
|
1995
|
-
return !0;
|
|
1975
|
+
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
|
|
1976
|
+
if (typeof Proxy == "function") return !0;
|
|
1996
1977
|
try {
|
|
1997
1978
|
return Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1998
1979
|
})), !0;
|
|
@@ -2138,10 +2119,8 @@ function nl(o) {
|
|
|
2138
2119
|
return o;
|
|
2139
2120
|
}
|
|
2140
2121
|
function sl() {
|
|
2141
|
-
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham)
|
|
2142
|
-
|
|
2143
|
-
if (typeof Proxy == "function")
|
|
2144
|
-
return !0;
|
|
2122
|
+
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
|
|
2123
|
+
if (typeof Proxy == "function") return !0;
|
|
2145
2124
|
try {
|
|
2146
2125
|
return Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
2147
2126
|
})), !0;
|
|
@@ -2282,10 +2261,8 @@ function dl(o) {
|
|
|
2282
2261
|
return o;
|
|
2283
2262
|
}
|
|
2284
2263
|
function hl() {
|
|
2285
|
-
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham)
|
|
2286
|
-
|
|
2287
|
-
if (typeof Proxy == "function")
|
|
2288
|
-
return !0;
|
|
2264
|
+
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
|
|
2265
|
+
if (typeof Proxy == "function") return !0;
|
|
2289
2266
|
try {
|
|
2290
2267
|
return Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
2291
2268
|
})), !0;
|
|
@@ -2744,8 +2721,7 @@ class ml extends Y {
|
|
|
2744
2721
|
}
|
|
2745
2722
|
createClipPath() {
|
|
2746
2723
|
const e = this.parent, { cartesianScales: t } = this.services;
|
|
2747
|
-
if (!t)
|
|
2748
|
-
throw new Error("Service cartesianScales was undefined");
|
|
2724
|
+
if (!t) throw new Error("Service cartesianScales was undefined");
|
|
2749
2725
|
const n = t.getMainXScale(), s = t.getMainYScale(), [a, i] = n.range(), [r, l] = s.range();
|
|
2750
2726
|
if (!e)
|
|
2751
2727
|
throw new Error("svg is undefined");
|
|
@@ -2984,8 +2960,7 @@ class fl extends Y {
|
|
|
2984
2960
|
if (n) {
|
|
2985
2961
|
const s = T(this.services.domUtils.getHolder()), a = v(t, "style", "prefix");
|
|
2986
2962
|
this.tooltip = S.appendOrSelect(s, `div.${Me}--${a}--tooltip`), this.tooltip.style("max-width", null).attr("role", "tooltip"), this.isEventListenerAdded || (this.addTooltipEventListener(), this.isEventListenerAdded = !0), this.tooltip.classed("hidden", !0);
|
|
2987
|
-
} else
|
|
2988
|
-
!n && this.isEventListenerAdded && (this.removeTooltipEventListener(), this.isEventListenerAdded = !1);
|
|
2963
|
+
} else !n && this.isEventListenerAdded && (this.removeTooltipEventListener(), this.isEventListenerAdded = !1);
|
|
2989
2964
|
}
|
|
2990
2965
|
addOffsetByPlacement(e, t, n) {
|
|
2991
2966
|
const s = Object.assign({}, e);
|
|
@@ -3060,8 +3035,7 @@ const ht = class ht extends Y {
|
|
|
3060
3035
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
3061
3036
|
render(e = !0) {
|
|
3062
3037
|
const t = this.parent, n = this.getComponentContainer();
|
|
3063
|
-
if (!t)
|
|
3064
|
-
throw new Error("SVG was not defined");
|
|
3038
|
+
if (!t) throw new Error("SVG was not defined");
|
|
3065
3039
|
const s = S.appendOrSelect(
|
|
3066
3040
|
t,
|
|
3067
3041
|
"svg.chart-grid-backdrop"
|
|
@@ -3190,13 +3164,12 @@ class fh extends Y {
|
|
|
3190
3164
|
}
|
|
3191
3165
|
this.addBrushEventListener(w, c, l);
|
|
3192
3166
|
const A = S.appendOrSelect(t, this.brushSelector).call(this.brush);
|
|
3193
|
-
if (w !== void 0)
|
|
3194
|
-
|
|
3195
|
-
|
|
3196
|
-
|
|
3197
|
-
|
|
3198
|
-
|
|
3199
|
-
}
|
|
3167
|
+
if (w !== void 0) if (w[0].valueOf() === w[1].valueOf())
|
|
3168
|
+
A.call(this.brush.move, this.xScale.range()), this.updateBrushHandle(this.getComponentContainer(), this.xScale.range());
|
|
3169
|
+
else {
|
|
3170
|
+
const L = w.map((I) => this.xScale(I));
|
|
3171
|
+
L[1] - L[0] < this.MIN_SELECTION_DIFF || (A.call(this.brush.move, L), this.updateBrushHandle(this.getComponentContainer(), L));
|
|
3172
|
+
}
|
|
3200
3173
|
s && (this.brush.filter(() => !1), A.selectAll("rect").attr("cursor", "auto"));
|
|
3201
3174
|
}
|
|
3202
3175
|
}
|
|
@@ -4227,8 +4200,7 @@ class Ma extends Y {
|
|
|
4227
4200
|
class jn extends Y {
|
|
4228
4201
|
constructor() {
|
|
4229
4202
|
super(...arguments), this.type = "scatter", this.renderType = j.SVG, this.handleChartHolderOnHover = () => {
|
|
4230
|
-
if (!this.parent)
|
|
4231
|
-
throw new Error("Parent not defined");
|
|
4203
|
+
if (!this.parent) throw new Error("Parent not defined");
|
|
4232
4204
|
this.parent.selectAll("circle.dot").transition("chart-holder-hover-scatter").call(
|
|
4233
4205
|
(e) => {
|
|
4234
4206
|
var t;
|
|
@@ -4239,8 +4211,7 @@ class jn extends Y {
|
|
|
4239
4211
|
}
|
|
4240
4212
|
).attr("opacity", 1);
|
|
4241
4213
|
}, this.handleChartHolderOnMouseOut = () => {
|
|
4242
|
-
if (!this.parent)
|
|
4243
|
-
throw new Error("Parent not defined");
|
|
4214
|
+
if (!this.parent) throw new Error("Parent not defined");
|
|
4244
4215
|
this.parent.selectAll("circle.dot").transition("chart-holder-mouseout-scatter").call(
|
|
4245
4216
|
(e) => {
|
|
4246
4217
|
var t;
|
|
@@ -4252,8 +4223,7 @@ class jn extends Y {
|
|
|
4252
4223
|
).attr("opacity", 0);
|
|
4253
4224
|
}, this.handleLegendOnHover = (e) => {
|
|
4254
4225
|
const { hoveredElement: t } = e.detail, { groupMapsTo: n } = this.getOptions().data;
|
|
4255
|
-
if (!this.parent)
|
|
4256
|
-
throw new Error("Parent not defined");
|
|
4226
|
+
if (!this.parent) throw new Error("Parent not defined");
|
|
4257
4227
|
this.parent.selectAll("circle.dot").transition("legend-hover-scatter").call(
|
|
4258
4228
|
(s) => {
|
|
4259
4229
|
var a;
|
|
@@ -4264,8 +4234,7 @@ class jn extends Y {
|
|
|
4264
4234
|
}
|
|
4265
4235
|
).attr("opacity", (s) => s[n] !== t.datum().name ? 0.3 : 1);
|
|
4266
4236
|
}, this.handleLegendMouseOut = () => {
|
|
4267
|
-
if (!this.parent)
|
|
4268
|
-
throw new Error("Parent not defined");
|
|
4237
|
+
if (!this.parent) throw new Error("Parent not defined");
|
|
4269
4238
|
this.parent.selectAll("circle.dot").transition("legend-mouseout-scatter").call(
|
|
4270
4239
|
(e) => {
|
|
4271
4240
|
var t;
|
|
@@ -4279,8 +4248,7 @@ class jn extends Y {
|
|
|
4279
4248
|
}
|
|
4280
4249
|
init() {
|
|
4281
4250
|
const { events: e } = this.services;
|
|
4282
|
-
if (!e)
|
|
4283
|
-
throw new Error("Services events are undefined.");
|
|
4251
|
+
if (!e) throw new Error("Services events are undefined.");
|
|
4284
4252
|
e.addEventListener(
|
|
4285
4253
|
f.Legend.ITEM_HOVER,
|
|
4286
4254
|
this.handleLegendOnHover
|
|
@@ -4290,8 +4258,7 @@ class jn extends Y {
|
|
|
4290
4258
|
}
|
|
4291
4259
|
filterBasedOnZoomDomain(e) {
|
|
4292
4260
|
const { cartesianScales: t } = this.services;
|
|
4293
|
-
if (!t)
|
|
4294
|
-
throw new Error("Services cartesianScales are undefined.");
|
|
4261
|
+
if (!t) throw new Error("Services cartesianScales are undefined.");
|
|
4295
4262
|
const n = t.getDomainIdentifier(e), s = this.model.get("zoomDomain");
|
|
4296
4263
|
return s !== void 0 ? e.filter(
|
|
4297
4264
|
(a) => a[n].getTime() >= s[0].getTime() && a[n].getTime() <= s[1].getTime()
|
|
@@ -4308,8 +4275,7 @@ class jn extends Y {
|
|
|
4308
4275
|
});
|
|
4309
4276
|
} else {
|
|
4310
4277
|
const { cartesianScales: s } = this.services;
|
|
4311
|
-
if (!s)
|
|
4312
|
-
throw new Error("Services cartesianScales are undefined.");
|
|
4278
|
+
if (!s) throw new Error("Services cartesianScales are undefined.");
|
|
4313
4279
|
n = this.model.getDisplayData(this.configs.groups).filter((a) => {
|
|
4314
4280
|
const i = s.getRangeIdentifier(a);
|
|
4315
4281
|
return a[i] !== void 0 && a[i] !== null;
|
|
@@ -4321,8 +4287,7 @@ class jn extends Y {
|
|
|
4321
4287
|
if (!(v(this.getOptions(), "points", "enabled") || v(this.getOptions(), "bubble", "enabled")))
|
|
4322
4288
|
return;
|
|
4323
4289
|
const n = this.getComponentContainer({ withinChartClip: !0 }), s = this.getOptions(), { groupMapsTo: a } = s.data, { cartesianScales: i } = this.services;
|
|
4324
|
-
if (!i)
|
|
4325
|
-
throw new Error("Services cartesianScales are undefined.");
|
|
4290
|
+
if (!i) throw new Error("Services cartesianScales are undefined.");
|
|
4326
4291
|
const r = i.getDomainIdentifier(), l = n.selectAll("circle.dot").data(
|
|
4327
4292
|
this.getScatterData(),
|
|
4328
4293
|
(p) => `${p[a]}-${p[r]}`
|
|
@@ -4337,8 +4302,7 @@ class jn extends Y {
|
|
|
4337
4302
|
if (!t)
|
|
4338
4303
|
return !1;
|
|
4339
4304
|
const { cartesianScales: n } = this.services;
|
|
4340
|
-
if (!n)
|
|
4341
|
-
throw new Error("Cartesian scales service is undefined");
|
|
4305
|
+
if (!n) throw new Error("Cartesian scales service is undefined");
|
|
4342
4306
|
const s = n.getOrientation(), [a, i] = Fe(
|
|
4343
4307
|
n.getHighestDomainThreshold(),
|
|
4344
4308
|
n.getHighestRangeThreshold(),
|
|
@@ -4352,8 +4316,7 @@ class jn extends Y {
|
|
|
4352
4316
|
}
|
|
4353
4317
|
styleCircles(e, t) {
|
|
4354
4318
|
const n = this.getOptions(), { filled: s, fillOpacity: a } = n.points, { cartesianScales: i } = this.services;
|
|
4355
|
-
if (!i)
|
|
4356
|
-
throw new Error("Cartesian scales service is undefined");
|
|
4319
|
+
if (!i) throw new Error("Cartesian scales service is undefined");
|
|
4357
4320
|
const { groupMapsTo: r } = n.data, l = (u) => i.getDomainValue(u), c = (u) => i.getRangeValue(u), [d, p] = Fe(
|
|
4358
4321
|
l,
|
|
4359
4322
|
c,
|
|
@@ -4402,8 +4365,7 @@ class jn extends Y {
|
|
|
4402
4365
|
}
|
|
4403
4366
|
addEventListeners() {
|
|
4404
4367
|
const e = this, { groupMapsTo: t } = e.getOptions().data;
|
|
4405
|
-
if (!this.parent)
|
|
4406
|
-
throw new Error("Parent not defined");
|
|
4368
|
+
if (!this.parent) throw new Error("Parent not defined");
|
|
4407
4369
|
this.parent.selectAll("circle").on("mouseover", function(n, s) {
|
|
4408
4370
|
var i, r;
|
|
4409
4371
|
const a = T(this);
|
|
@@ -4470,8 +4432,7 @@ class jn extends Y {
|
|
|
4470
4432
|
var t;
|
|
4471
4433
|
(t = this.parent) == null || t.selectAll("circle").on("mousemove", null).on("mouseout", null);
|
|
4472
4434
|
const { events: e } = this.services;
|
|
4473
|
-
if (!e)
|
|
4474
|
-
throw new Error("Services events undefined");
|
|
4435
|
+
if (!e) throw new Error("Services events undefined");
|
|
4475
4436
|
e.removeEventListener(
|
|
4476
4437
|
f.Legend.ITEM_HOVER,
|
|
4477
4438
|
this.handleLegendOnHover
|
|
@@ -4492,8 +4453,7 @@ class Ca extends Y {
|
|
|
4492
4453
|
useAttrs: !0
|
|
4493
4454
|
}), l = S.appendOrSelect(a, `g.axis.${t}`);
|
|
4494
4455
|
let c, d;
|
|
4495
|
-
if (t === B.BOTTOM || t === B.TOP ? (c = this.configs.axes[B.LEFT] ? this.margins.left : 0, d = this.configs.axes[B.RIGHT] ? i - this.margins.right : i) : (c = r - this.margins.bottom, d = this.margins.top), !this.services.cartesianScales)
|
|
4496
|
-
throw new Error("Services cartesianScales undefined");
|
|
4456
|
+
if (t === B.BOTTOM || t === B.TOP ? (c = this.configs.axes[B.LEFT] ? this.margins.left : 0, d = this.configs.axes[B.RIGHT] ? i - this.margins.right : i) : (c = r - this.margins.bottom, d = this.margins.top), !this.services.cartesianScales) throw new Error("Services cartesianScales undefined");
|
|
4497
4457
|
const p = this.services.cartesianScales.getScaleByPosition(t);
|
|
4498
4458
|
this.scaleType === ge.LABELS || this.scaleType === ge.LABELS_RATIO ? p.rangeRound([c, d]) : p.range([c, d]);
|
|
4499
4459
|
let h;
|
|
@@ -5548,20 +5508,17 @@ function bl(o) {
|
|
|
5548
5508
|
return o;
|
|
5549
5509
|
}
|
|
5550
5510
|
function Sl(o) {
|
|
5551
|
-
if (o == null)
|
|
5552
|
-
return bl;
|
|
5511
|
+
if (o == null) return bl;
|
|
5553
5512
|
var e, t, n = o.scale[0], s = o.scale[1], a = o.translate[0], i = o.translate[1];
|
|
5554
5513
|
return function(r, l) {
|
|
5555
5514
|
l || (e = t = 0);
|
|
5556
5515
|
var c = 2, d = r.length, p = new Array(d);
|
|
5557
|
-
for (p[0] = (e += r[0]) * n + a, p[1] = (t += r[1]) * s + i; c < d; )
|
|
5558
|
-
p[c] = r[c], ++c;
|
|
5516
|
+
for (p[0] = (e += r[0]) * n + a, p[1] = (t += r[1]) * s + i; c < d; ) p[c] = r[c], ++c;
|
|
5559
5517
|
return p;
|
|
5560
5518
|
};
|
|
5561
5519
|
}
|
|
5562
5520
|
function Ol(o, e) {
|
|
5563
|
-
for (var t, n = o.length, s = n - e; s < --n; )
|
|
5564
|
-
t = o[s], o[s++] = o[n], o[n] = t;
|
|
5521
|
+
for (var t, n = o.length, s = n - e; s < --n; ) t = o[s], o[s++] = o[n], o[n] = t;
|
|
5565
5522
|
}
|
|
5566
5523
|
function Tl(o, e) {
|
|
5567
5524
|
return typeof e == "string" && (e = o.objects[e]), e.type === "GeometryCollection" ? { type: "FeatureCollection", features: e.geometries.map(function(t) {
|
|
@@ -5584,13 +5541,11 @@ function Xn(o, e) {
|
|
|
5584
5541
|
return t(d);
|
|
5585
5542
|
}
|
|
5586
5543
|
function i(d) {
|
|
5587
|
-
for (var p = [], h = 0, u = d.length; h < u; ++h)
|
|
5588
|
-
s(d[h], p);
|
|
5544
|
+
for (var p = [], h = 0, u = d.length; h < u; ++h) s(d[h], p);
|
|
5589
5545
|
return p.length < 2 && p.push(p[0]), p;
|
|
5590
5546
|
}
|
|
5591
5547
|
function r(d) {
|
|
5592
|
-
for (var p = i(d); p.length < 4; )
|
|
5593
|
-
p.push(p[0]);
|
|
5548
|
+
for (var p = i(d); p.length < 4; ) p.push(p[0]);
|
|
5594
5549
|
return p;
|
|
5595
5550
|
}
|
|
5596
5551
|
function l(d) {
|
|
@@ -5669,8 +5624,7 @@ function xl(o, e) {
|
|
|
5669
5624
|
}), a;
|
|
5670
5625
|
}
|
|
5671
5626
|
function Ll(o) {
|
|
5672
|
-
for (var e = -1, t = o.length, n, s = o[t - 1], a = 0; ++e < t; )
|
|
5673
|
-
n = s, s = o[e], a += n[0] * s[1] - n[1] * s[0];
|
|
5627
|
+
for (var e = -1, t = o.length, n, s = o[t - 1], a = 0; ++e < t; ) n = s, s = o[e], a += n[0] * s[1] - n[1] * s[0];
|
|
5674
5628
|
return Math.abs(a);
|
|
5675
5629
|
}
|
|
5676
5630
|
function Al(o) {
|
|
@@ -5991,7 +5945,6 @@ class Uh extends pl {
|
|
|
5991
5945
|
/**
|
|
5992
5946
|
* Uses the parent class truncate logic
|
|
5993
5947
|
* @param title d3 selection of title element that will be truncated
|
|
5994
|
-
* @param titlestring the original string that needs truncation
|
|
5995
5948
|
* @param maxWidth the max width the title can take
|
|
5996
5949
|
*/
|
|
5997
5950
|
truncateTitle(e, t) {
|
|
@@ -8247,8 +8200,7 @@ class su extends Y {
|
|
|
8247
8200
|
const m = T(this.parentNode).attr("data-uid");
|
|
8248
8201
|
return `${s.style.prefix}-leaf-${m}`;
|
|
8249
8202
|
}).attr("class", (m) => {
|
|
8250
|
-
for (; m.depth > 1; )
|
|
8251
|
-
m = m.parent;
|
|
8203
|
+
for (; m.depth > 1; ) m = m.parent;
|
|
8252
8204
|
return this.model.getColorClassName({
|
|
8253
8205
|
classNameTypes: [z.FILL],
|
|
8254
8206
|
dataGroupName: m.data.name,
|
|
@@ -8261,8 +8213,7 @@ class su extends Y {
|
|
|
8261
8213
|
animate: e
|
|
8262
8214
|
})
|
|
8263
8215
|
).attr("width", (m) => m.x1 - m.x0).attr("height", (m) => m.y1 - m.y0).style("fill", (m) => {
|
|
8264
|
-
for (; m.depth > 1; )
|
|
8265
|
-
m = m.parent;
|
|
8216
|
+
for (; m.depth > 1; ) m = m.parent;
|
|
8266
8217
|
return this.model.getFillColor(m.data.name, null, m.data);
|
|
8267
8218
|
}), h.selectAll("clipPath").data(
|
|
8268
8219
|
(m) => m.data.showLabel !== !0 ? [] : [1],
|
|
@@ -8285,8 +8236,7 @@ class su extends Y {
|
|
|
8285
8236
|
if (m.data.showLabel !== !0)
|
|
8286
8237
|
return [];
|
|
8287
8238
|
let E = m;
|
|
8288
|
-
for (; E.depth > 1; )
|
|
8289
|
-
E = E.parent;
|
|
8239
|
+
for (; E.depth > 1; ) E = E.parent;
|
|
8290
8240
|
const O = na(this.model.getFillColor(E.data.name));
|
|
8291
8241
|
return [
|
|
8292
8242
|
{
|
|
@@ -8313,8 +8263,7 @@ class su extends Y {
|
|
|
8313
8263
|
this.parent.selectAll("rect.leaf").on("mouseover", function(t, n) {
|
|
8314
8264
|
const s = T(this);
|
|
8315
8265
|
let a = getComputedStyle(this, null).getPropertyValue("fill"), i = n;
|
|
8316
|
-
for (; i.depth > 1; )
|
|
8317
|
-
i = i.parent;
|
|
8266
|
+
for (; i.depth > 1; ) i = i.parent;
|
|
8318
8267
|
s.transition("graph_element_mouseover_fill_update").call(
|
|
8319
8268
|
(r) => e.services.transitions.setupTransition({
|
|
8320
8269
|
transition: r,
|
|
@@ -8361,8 +8310,7 @@ class su extends Y {
|
|
|
8361
8310
|
const s = T(this);
|
|
8362
8311
|
s.classed("hovered", !1);
|
|
8363
8312
|
let a = n;
|
|
8364
|
-
for (; a.depth > 1; )
|
|
8365
|
-
a = a.parent;
|
|
8313
|
+
for (; a.depth > 1; ) a = a.parent;
|
|
8366
8314
|
s.transition().call(
|
|
8367
8315
|
(i) => e.services.transitions.setupTransition({
|
|
8368
8316
|
transition: i,
|
|
@@ -8711,4 +8659,4 @@ export {
|
|
|
8711
8659
|
Lh as y,
|
|
8712
8660
|
wh as z
|
|
8713
8661
|
};
|
|
8714
|
-
//# sourceMappingURL=choropleth-
|
|
8662
|
+
//# sourceMappingURL=choropleth-B7eXF9sA.mjs.map
|