igniteui-angular-charts
Version:
Ignite UI Angular charting components for building rich data visualizations for modern web apps.
1,308 lines (1,307 loc) • 46.7 kB
JavaScript
/*
THIS INFRAGISTICS ULTIMATE SOFTWARE LICENSE AGREEMENT ("AGREEMENT") LOCATED HERE:
https://www.infragistics.com/legal/license/igultimate-la
https://www.infragistics.com/legal/license/igultimate-eula
GOVERNS THE LICENSING, INSTALLATION AND USE OF INFRAGISTICS SOFTWARE. BY DOWNLOADING AND/OR INSTALLING AND USING INFRAGISTICS SOFTWARE: you are indicating that you have read and understand this Agreement, and agree to be legally bound by it on behalf of the yourself and your company.
*/
import { Base, markType, Point_$type, enumGetBox, EnumUtil, Array_$type, runOn, delegateCombine, typeCast, fromEnum, markDep } from "igniteui-angular-core";
import { IBucketizer_$type } from "./IBucketizer";
import { NotImplementedException } from "igniteui-angular-core";
import { CategoryAngleAxis } from "./CategoryAngleAxis";
import { NumericRadiusAxis } from "./NumericRadiusAxis";
import { truncate, intDivide, isNaN_ } from "igniteui-angular-core";
import { MarkerSeries } from "./MarkerSeries";
import { IHasCategoryModePreference_$type } from "./IHasCategoryModePreference";
import { DependencyProperty } from "igniteui-angular-core";
import { RadialLabelMode_$type } from "igniteui-angular-core";
import { CategoryCollisionMode_$type } from "./CategoryCollisionMode";
import { CategoryTransitionInMode_$type } from "./CategoryTransitionInMode";
import { HighlightingInfo } from "igniteui-angular-core";
import { BindingFormatter } from "igniteui-angular-core";
import { CategoryTransitionSourceFramePreparer } from "./CategoryTransitionSourceFramePreparer";
import { RadialFrame } from "./RadialFrame";
import { RadialSeriesRenderManager } from "./RadialSeriesRenderManager";
import { RadialAxes } from "./RadialAxes";
import { CoreGeometryUtil } from "igniteui-angular-core";
import { PolygonUtil } from "igniteui-angular-core";
import { List$1 } from "igniteui-angular-core";
import { SeriesPointOfInterest } from "./SeriesPointOfInterest";
import { ScalerParams } from "./ScalerParams";
import { Marker } from "./Marker";
import { MarkerSeriesView } from "./MarkerSeriesView";
import { ProportionalRadialLabelContext } from "./ProportionalRadialLabelContext";
import { MathUtil } from "igniteui-angular-core";
import { SeriesLayerPropertyOverlay } from "./SeriesLayerPropertyOverlay";
import { DoubleCollection } from "igniteui-angular-core";
import { Visibility_$type } from "igniteui-angular-core";
import { ChartSelection } from "./ChartSelection";
import { PropertyMetadata } from "igniteui-angular-core";
import { boxArray$1 } from "igniteui-angular-core";
import { round10N } from "igniteui-angular-core";
import { Pool$1 } from "igniteui-angular-core";
/**
* @hidden
*/
export let RadialBucketCalculator = /*@__PURE__*/ (() => {
class RadialBucketCalculator extends Base {
constructor(a) {
super();
this.a = null;
this.c = 0;
this.d = 0;
this.b = 0;
this.a = a;
}
getBucket(a) {
throw new NotImplementedException(0);
}
getBucketWithoutUnknowns(a) {
return this.getBucket(a);
}
getErrorBucket(a, b) {
return NaN;
}
getBucketInfo(a, b, c, d) {
a = this.c;
b = this.d;
c = this.b;
d = this.a.c9.ik;
return {
p0: a,
p1: b,
p2: c,
p3: d
};
}
e(a) {
let b = this.a.ca;
let c = this.a.b9;
let d = this.a.getEffectiveViewport();
let e = this.a.c9.zj;
if (b.isEmpty || c.isEmpty || e == null || this.a.c9.dp == null || this.a.c9.dp.count == 0) {
this.b = 0;
return;
}
let f = Math.floor(e.r1(c, d, b));
let g = Math.ceil(e.r0(c, d, b));
if (e.dn) {
g = Math.ceil(e.r1(c, d, b));
f = Math.floor(e.r0(c, d, b));
}
if (g < f) {
g = e.p7 + g;
}
let h = this.a.c9.zp;
let i = h != null ? h.td : 0.75;
let j = Math.min(c.width, c.height) * 0.5 * (i) * 2 * Math.PI;
let k = Math.floor((g - f + 1) * a / j);
this.b = truncate(Math.max(1, k));
this.c = truncate(Math.max(0, Math.floor(f / this.b) - 1));
this.d = truncate(Math.ceil(g / this.b));
if (e.ds) {
this.b = 1;
this.c = truncate(Math.max(0, Math.floor(f / this.b) - 1));
this.d = truncate(Math.ceil(g / this.b));
}
}
cacheValues() {
}
unCacheValues() {
}
}
RadialBucketCalculator.$t = markType(RadialBucketCalculator, 'RadialBucketCalculator', Base.$, [IBucketizer_$type]);
return RadialBucketCalculator;
})();
/**
* @hidden
*/
export let RadialBase = /*@__PURE__*/ (() => {
class RadialBase extends MarkerSeries {
constructor() {
super();
this.zy = null;
this.z5 = false;
this.z4 = false;
this.z2 = null;
this.z3 = null;
this.assigningRadialStyle = null;
this.assigningRadialMarkerStyle = null;
this.zc = null;
this.zg = null;
this.zd = null;
this.zf = null;
this.ze = null;
this.zu = new RadialFrame(4);
this.zv = new RadialFrame(4);
this.zs = new RadialFrame(4);
this.zq = null;
this.zo = null;
this.zo = new CategoryTransitionSourceFramePreparer();
this.zy = new RadialSeriesRenderManager();
}
rg(a) {
super.rg(a);
this.zr = a;
}
abr() {
if (this.dd.g) {
this.dd.t();
}
}
get categoryAxis() {
return this.zj;
}
a0() {
return this.zj;
}
b3() {
if (this.b4 == 0) {
return 1;
}
else {
return super.b3();
}
}
aah(a, b, c) {
let d = this.cw.ca;
let e = this.cw.b9;
let f = this.cw.getEffectiveViewport();
let g = this.al(a);
let h = this.zq.d(0, this.zp.tm, d, e, f);
let i = this.zq.e(0, this.zp.tm, d, e, f);
if (g == null) {
return false;
}
for (let j = 0; j < g.length; j++) {
let k = g[j];
if (k == null) {
continue;
}
if (k.length != 2) {
if (CoreGeometryUtil.l(a, k[0], boxArray$1(k), this.il / 2 + this.i1(c))) {
return true;
}
if (CoreGeometryUtil.i(a, { $type: Point_$type, x: h, y: i }, k[0], this.il / 2 + this.i1(c))) {
return true;
}
if (CoreGeometryUtil.i(a, k[k.length - 1], { $type: Point_$type, x: h, y: i }, this.il / 2 + this.i1(c))) {
return true;
}
let l = new Array(k.length + 2);
for (let m = 0; m < k.length; m++) {
l[m] = k[m];
}
l[l.length - 2] = { $type: Point_$type, x: h, y: i };
l[l.length - 1] = k[0];
if (PolygonUtil.b(boxArray$1(l), a)) {
return true;
}
}
else {
if (CoreGeometryUtil.i(a, k[0], k[1], this.il / 2 + this.i1(c))) {
return true;
}
if (CoreGeometryUtil.i(a, { $type: Point_$type, x: h, y: i }, k[0], this.il / 2 + this.i1(c))) {
return true;
}
if (CoreGeometryUtil.i(a, k[1], { $type: Point_$type, x: h, y: i }, this.il / 2 + this.i1(c))) {
return true;
}
let n = new Array(4);
n[0] = k[0];
n[1] = k[1];
n[2] = { $type: Point_$type, x: h, y: i };
n[3] = k[0];
if (PolygonUtil.b(boxArray$1(n), a)) {
return true;
}
}
}
return false;
}
aj(a) {
let b = this.zt();
let c = this.cw.ca;
let d = this.cw.b9;
let e = this.cw.getEffectiveViewport();
let f = this.an(this.a0(), b.k, this.aap(this.cw), this.aaq(this.cw), this.w1(a), true);
if (f == null) {
return null;
}
let g = f[0];
let h = f[1];
let i = this.zq.d(g[0], g[2], c, d, e);
let j = this.zq.e(g[0], g[2], c, d, e);
let k = this.zq.d(h[0], h[2], c, d, e);
let l = this.zq.e(h[0], h[2], c, d, e);
let m = new Array(1);
let n = new Array(2);
n[0] = { $type: Point_$type, x: i, y: j };
n[1] = { $type: Point_$type, x: k, y: l };
m[0] = n;
return m;
}
al(a) {
let b = this.zt();
let c = this.cw.ca;
let d = this.cw.b9;
let e = this.cw.getEffectiveViewport();
let f = this.an(this.a0(), b.k, this.aap(this.cw), this.aaq(this.cw), this.w1(a), true);
if (f == null) {
return null;
}
let g = f[0];
let h = f[1];
let i = new Array(1);
let j = new Array(2);
let k = this.zq.d(g[0], g[1], c, d, e);
let l = this.zq.e(g[0], g[1], c, d, e);
let m = this.zq.d(h[0], h[1], c, d, e);
let n = this.zq.e(h[0], h[1], c, d, e);
j[0] = { $type: Point_$type, x: k, y: l };
j[1] = { $type: Point_$type, x: m, y: n };
i[0] = j;
return i;
}
g2(a, b) {
if (this.g1(a, b)) {
return true;
}
if (this.x1(a, b)) {
return true;
}
return false;
}
y7(a, b) {
return null;
}
w0(a) {
let b = this.zj;
let c = this.zp;
if (b == null || c == null || this.dc == null) {
return { $type: Point_$type, x: NaN, y: NaN };
}
let d = NaN;
let e = NaN;
let f = this.zq.h(a.x, a.y, this.dc.yr, this.dc.y9, this.getEffectiveViewport(), d, e);
d = f.p5;
e = f.p6;
return { $type: Point_$type, x: d, y: e };
}
p5(a) {
if (this.zj != null && this.zj.ds && this.zj.s6(a)) {
if (this.fl) {
this.ba.a$y(this, a, this.zj.p8 - 1);
}
return;
}
super.p5(a);
}
eg(a) {
if (this.zj != null && this.zj.ds && this.zj.hasOthersCategory) {
if (this.zj.s6(a)) {
return true;
}
}
return super.eg(a);
}
p3(a) {
if (this.zj != null && this.zj.ds && this.zj.s6(a)) {
if (this.fl) {
this.ba.a$ao(this, a, this.dp.count - 1);
}
return;
}
super.p3(a);
}
ed(a, b, c, d, e) {
if (!this.hasMarkers) {
return false;
}
let f = this.zj;
let g = new ScalerParams(1, this.dc.yr, this.xc, f.dn);
g.c = this.getEffectiveViewport1(this.cw);
let h = this.zp;
let i = new ScalerParams(1, this.dc.yr, this.xc, h.dn);
i.c = this.getEffectiveViewport1(this.cw);
let j = this.aao;
a.clear();
this.xq.cw((k) => {
if (k._visibility == 0) {
let l = new SeriesPointOfInterest();
let m = k.n;
let n = k.o;
if (!e && (m < this.xc.left || m > this.xc.right || n < this.xc.top || n > this.xc.bottom)) {
return;
}
let o = null;
if (k.content != null) {
o = k.content.item;
}
let p;
let q;
let r = this.zq.h(m, n, this.cw.ca, this.cw.b9, this.cw.getEffectiveViewport(), p, q);
p = r.p5;
q = r.p6;
l.d = p;
l.e = q;
let s = l.e;
let t = k.ak;
l.f = this.abo(s, o, t, d, j, c, b, false);
l.b = k.content;
l.g = this.vz;
l.c = k.ak;
if (this.hf) {
l.g = this.v6(k.ak);
}
l.a = this.ar(k.ak, k.al);
a.add(l);
}
});
return true;
}
k1(a, b) {
let c = null;
if (this.dp != null) {
if (a >= 0 && a < this.dp.count) {
c = this.dp.item(a);
}
if (this.zj != null && this.zj.ds && a == this.zj.othersIndex) {
c = this.zj.tj(false);
}
}
let d = NaN;
if (c != null) {
d = this.jk(c);
}
let e = this.abo(d, c, a, this.aan >= 0 ? this.aan : 5, this.aao, false, false, b);
if (e != null) {
return e;
}
return super.k1(a, b);
}
abo(a, b, c, d, e, f, g, h) {
let i = null;
let j = this.zj.ds && this.zj.s6(b);
let k = this.zw;
if (h) {
k = this.zx;
}
if (k == 0) {
if (h) {
k = 5;
}
else {
k = 6;
}
}
if ((h && ((this.zd != null) || (j && this.ze != null))) || (!h && ((this.zg != null) || (j && this.zf != null)))) {
let l = this.aak(a, b, c, d, f);
let m = this.aal(a, b, c, e, f);
let n = this.aa5(c);
let o = ((() => {
let $ret = new ProportionalRadialLabelContext();
$ret.value = l;
$ret.percent = m;
$ret.label = n;
$ret.item = b;
return $ret;
})());
let p = null;
if (j) {
if (h) {
p = this.ze;
}
else {
p = this.zf;
}
if (p == null) {
if (h) {
p = this.zd;
}
else {
p = this.zg;
}
}
}
else {
if (h) {
p = this.zd;
}
else {
p = this.zg;
}
}
i = p.i(o);
}
else if (k != 1) {
switch (k) {
case 2:
i = this.aa6(a, b, c, d, f);
break;
case 3:
i = this.aa7(a, b, c, e, f);
break;
case 4:
{
let q = this.aa6(a, b, c, d, f);
let r = this.aa7(a, b, c, e, f);
i = q + this.aaw + r;
}
break;
case 5:
i = this.aa5(c);
break;
case 6:
{
let s = this.aa6(a, b, c, d, f);
let t = this.aa5(c);
i = t + this.aaw + s;
}
break;
case 7:
{
let u = this.aa7(a, b, c, e, f);
let v = this.aa5(c);
i = v + this.aaw + u;
}
break;
case 8:
{
let w = this.aa6(a, b, c, d, f);
let x = this.aa7(a, b, c, e, f);
let y = this.aa5(c);
i = y + this.aaw + w + this.aaw + x;
}
break;
}
}
else {
if (g) {
i = this.aa6(a, b, c, d, f);
}
else {
i = this.aa5(c);
}
}
return i;
}
aa5(a) {
let b = this.zj;
let c = this.au(true);
if (this.zj != null && this.zj.ds && this.zj.hasOthersCategory && a == this.zj.othersIndex) {
if (this.zc != null) {
c = this.zc;
}
}
if (c != null) {
let d = super.k1(a, false);
if (d != null) {
return c.i(d);
}
else {
return null;
}
}
else {
return b.i6(a);
}
}
aa6(a, b, c, d, e) {
let f = a;
f = this.aas(c, f);
if (e) {
return this.aau(f, d);
}
else {
a = this.jk(b);
if (!isNaN_(a)) {
return this.aau(a, d);
}
else {
return this.aau(f, d);
}
}
}
aak(a, b, c, d, e) {
let f = a;
f = this.aas(c, f);
if (e) {
return f;
}
else {
a = this.jk(b);
if (!isNaN_(a)) {
return a;
}
else {
return f;
}
}
}
aa7(a, b, c, d, e) {
if (this.zj == null || !this.zj.ds) {
return this.aa6(a, b, c, d, e);
}
let f = this.zj.td(c);
if (e) {
return this.aau(f, d) + "%";
}
else {
a = this.zj.td(c);
if (!isNaN_(a)) {
return this.aau(a, d) + "%";
}
else {
return this.aau(f, d) + "%";
}
}
}
aal(a, b, c, d, e) {
if (this.zj == null || !this.zj.ds) {
return this.aak(a, b, c, d, e);
}
let f = this.zj.td(c);
if (e) {
return f;
}
else {
a = this.zj.td(c);
if (!isNaN_(a)) {
return a;
}
else {
return f;
}
}
}
aas(a, b) {
return b;
}
aau(a, b) {
let c;
if (b >= 0) {
c = round10N(a, b);
}
else {
c = a;
}
let d = this.au(false);
if (d != null) {
let e = d;
return e.i(c);
}
else {
return MathUtil.t(c);
}
}
get_fw() {
return true;
}
get_fh() {
return true;
}
zz(a, b, c) {
let d = new HighlightingInfo();
d.i = this;
d.g = 0;
d.f = this.dp.count - 1;
d.c = true;
if (c != null && c.g == d.g && c.f == d.f) {
return c;
}
return d;
}
aag() {
return false;
}
hz() {
let a = super.hz();
if (this.aag()) {
let b = ((() => {
let $ret = new SeriesLayerPropertyOverlay();
$ret.r = true;
$ret.ad = "DashArray";
$ret.p = true;
$ret.x = ((() => {
let $ret = new DoubleCollection();
$ret.add(5);
$ret.add(5);
return $ret;
})());
$ret.q = true;
return $ret;
})());
a.add(b);
}
if (!this.aag()) {
let c = ((() => {
let $ret = new SeriesLayerPropertyOverlay();
$ret.r = true;
$ret.ad = "Brush";
$ret.p = true;
$ret.y = "ActualBrush";
$ret.q = true;
return $ret;
})());
c.valueResolving = delegateCombine(c.valueResolving, runOn(this, this.sh));
a.add(c);
}
if (!this.aag()) {
let d = ((() => {
let $ret = new SeriesLayerPropertyOverlay();
$ret.r = true;
$ret.ad = "Outline";
$ret.p = true;
$ret.y = "ActualOutline";
$ret.q = true;
return $ret;
})());
d.valueResolving = delegateCombine(d.valueResolving, runOn(this, this.sh));
a.add(d);
}
let e = ((() => {
let $ret = new SeriesLayerPropertyOverlay();
$ret.p = true;
$ret.ad = "IsTransitionInEnabled";
$ret.x = true;
$ret.q = true;
return $ret;
})());
a.add(e);
let f = ((() => {
let $ret = new SeriesLayerPropertyOverlay();
$ret.p = true;
$ret.ad = "TransitionInMode";
$ret.x = enumGetBox(CategoryTransitionInMode_$type, 20);
$ret.q = true;
return $ret;
})());
a.add(f);
return a;
}
k4() {
if (this.d4()) {
return this.bo.zv;
}
else {
return this.bo.zs;
}
}
z0(a, b, c) {
if (this.dp == null) {
return null;
}
let d = this.zr.da.c;
let e = this.zr.da.d;
let f = this.zr.da.b;
let g = this.zt();
let h = this.dp.count;
let i = this.zj;
let j = -1;
let k = -1;
let l = this.kc(b);
if (isNaN_(b.x) || isNaN_(b.y)) {
if (a != null && this.dp != null) {
if (this.zj.ds && this.zj.s6(a)) {
l = this.zj.othersIndex;
}
else {
l = this.dp.indexOf(a);
}
}
}
j = truncate(Math.floor((intDivide(l, f)))) * f;
k = j + (f - 1);
if (c != null && c.g == j && c.f == k) {
return c;
}
let m = new HighlightingInfo();
m.i = this;
m.g = j;
m.f = k;
return m;
}
z1(a, b, c) {
if (this.dp == null) {
return null;
}
let d = this.zr.da.c;
let e = this.zr.da.d;
let f = this.zr.da.b;
let g = this.zt();
let h = this.dp.count;
let i = this.zj;
let j = -1;
let k = -1;
let l = this.kc(b);
if (isNaN_(b.x) || isNaN_(b.y)) {
if (a != null && this.dp != null) {
if (this.zj.ds && this.zj.s6(a)) {
l = this.zj.othersIndex;
}
else {
l = this.dp.indexOf(a);
}
}
}
j = truncate(Math.floor((intDivide(l, f)))) * f;
k = j + (f - 1);
if (c != null && c.g == j && c.f == k) {
return c;
}
let m = new HighlightingInfo();
m.d = true;
m.i = this;
m.g = j;
m.f = k;
return m;
}
dh(a, b, c) {
if (this.ef && this.f2(this.by) && !c) {
let d = this.z0(a, b, this.z2);
this.z2 = d;
return d;
}
else {
let e = this.zz(a, b, this.z2);
this.z2 = e;
return e;
}
}
di(a, b, c) {
if (this.f2(this.by) && !c) {
let d = this.z1(a, b, this.z3);
this.z3 = d;
return d;
}
else {
let e = this.zz(a, b, this.z3);
e.d = true;
this.z3 = e;
return e;
}
}
aaf() {
return (this.assigningRadialStyle != null && this.z5) || this.d3 || (this.by != 1) || (this.cq != 1) || (this.cp != 1);
}
aae() {
return (this.assigningRadialMarkerStyle != null && this.z4) || this.d3 || (this.by != 1) || (this.cq != 1) || (this.cp != 1);
}
abu(a) {
if (this.assigningRadialStyle != null && this.z5) {
this.assigningRadialStyle(this, a);
}
}
abt(a) {
if (this.assigningRadialMarkerStyle != null && this.z4) {
this.assigningRadialMarkerStyle(this, a);
}
}
aap(a) {
return a.da.b;
}
aaq(a) {
return a.da.c;
}
ai() {
return [this.zj, this.zp];
}
s8(a, b) {
this.zr.da.e(this.ik);
this.r7(false);
}
s7(a, b) {
if (this.g7 && this.jz < 0.05 && (this.dc == null || !this.dc.gi())) {
this.g8 = true;
this.hb = false;
this.gq = false;
}
this.zr.da.e(this.ik);
this.r7(false);
}
rp(a, b, c, d) {
super.rp(a, b, c, d);
switch (b) {
case RadialBase.$$p[6]:
this.r7(false);
break;
case RadialBase.$$p[14]:
this.pq();
this.r7(false);
break;
case "SeriesViewer":
if (c != null && d == null) {
if (this.zj != null) {
this.zj.cx(this);
}
if (this.zp != null) {
this.zp.cx(this);
}
}
if (c == null && d != null) {
if (this.zj != null) {
this.zj.d3(this);
}
if (this.zp != null) {
this.zp.d3(this);
}
}
this.zr.da.e(this.ik);
this.r7(false);
break;
case RadialBase.$$p[0]:
if (this.zj != null && this.zp != null) {
this.zq = new RadialAxes(this.zp, this.zj);
}
if (c != null) {
c.cx(this);
}
if (d != null) {
d.d3(this);
}
this.zr.da.e(this.ik);
this.r7(false);
break;
case RadialBase.$$p[22]:
if (this.zj != null && this.zp != null) {
this.zq = new RadialAxes(this.zp, this.zj);
}
if (c != null) {
c.cx(this);
}
if (d != null) {
d.d3(this);
}
this.zr.da.e(this.ik);
if (this.zp == null || !this.zp.ec()) {
this.r7(false);
}
break;
case RadialBase.$$p[3]:
case RadialBase.$$p[4]:
if (this.aay != null) {
this.zc = new BindingFormatter();
this.zc.j = this.aay;
this.zc.d = this.y6;
}
else {
this.zc = null;
}
break;
case RadialBase.$$p[19]:
case RadialBase.$$p[20]:
if (this.abl != null) {
this.zg = new BindingFormatter();
this.zg.j = this.abl;
this.zg.d = this.zb;
}
else {
this.zg = null;
}
break;
case RadialBase.$$p[12]:
case RadialBase.$$p[13]:
if (this.abb != null) {
this.zd = new BindingFormatter();
this.zd.j = this.abb;
this.zd.d = this.y8;
}
else {
this.zd = null;
}
break;
case RadialBase.$$p[17]:
case RadialBase.$$p[18]:
if (this.abl != null) {
this.zf = new BindingFormatter();
this.zf.j = this.abi;
this.zf.d = this.za;
}
else {
this.zf = null;
}
break;
case RadialBase.$$p[15]:
case RadialBase.$$p[16]:
if (this.abb != null) {
this.ze = new BindingFormatter();
this.ze.j = this.abf;
this.ze.d = this.y9;
}
else {
this.ze = null;
}
break;
case "SyncLink":
if (this.c4 != null && this.dc != null) {
this.zr.da.e(this.ik);
this.r7(false);
}
break;
case "TransitionProgress":
this.zv.d(this.jz, this.zu, this.zs);
if (this.d7(this.cw)) {
return;
}
if (this.jz == 1) {
this.zs.ab();
this.abv(this.zs, this.zr);
if (this.g7) {
this.g7 = false;
this.pi();
this.dd.r = truncate(this.jh());
this.dd.b = this.de;
}
if (this.ha) {
this.ha = false;
this.pi();
this.dd.r = truncate(this.jh());
this.dd.b = this.de;
this.rf();
}
this.q2();
}
else {
this.abv(this.zv, this.zr);
}
if (this.dc != null) {
this.dc.st(this);
}
break;
case RadialBase.$$p[8]:
this.r7(false);
this.qz();
break;
case "VisibilityProxy":
if (EnumUtil.getEnumValue(Visibility_$type, c) != 0 && EnumUtil.getEnumValue(Visibility_$type, d) == 0) {
this.zr.da.e(this.ik);
}
break;
case RadialBase.$$p[10]:
this.z5 = this.aad();
this.r7(false);
break;
case RadialBase.$$p[9]:
this.z4 = this.aac();
this.r7(false);
break;
}
}
aad() {
return this.aaa;
}
aac() {
return this.z9;
}
z7(a) {
if (typeCast(NumericRadiusAxis.$, a) !== null) {
return true;
}
return false;
}
z6(a) {
if (typeCast(CategoryAngleAxis.$, a) !== null) {
return true;
}
return false;
}
kw(a) {
let b = this.kc(a);
let c = false;
if (this.zj != null && this.zj.ds) {
let d = this.zj;
let e = d.hasOthersCategory && b == this.zj.p7 - 1;
c = e;
}
if (c) {
return this.zj.tj(true);
}
return b >= 0 && this.dp != null && b < this.dp.count ? this.dp.item(b) : null;
}
aai(a) {
let b = this.cw.ca;
let c = this.cw.b9;
let d = this.cw.getEffectiveViewport();
if (this.zj != null && !b.isEmpty && !c.isEmpty && this.zq != null) {
let e = this.zq.c(a, b, c, d);
if (e < 0) {
e += Math.PI * 2;
}
if (e > Math.PI * 2) {
e -= Math.PI * 2;
}
return e;
}
return NaN;
}
iy(a) {
let b = this.cw.ca;
let c = this.cw.b9;
let d = this.getEffectiveViewport1(this.cw);
let e = -1;
if (this.zj != null && !b.isEmpty && !c.isEmpty && this.zq != null) {
let f = this.zq.c(a, b, c, d);
if (f < 0) {
f += Math.PI * 2;
}
if (f > Math.PI * 2) {
f -= Math.PI * 2;
}
let g = this.zj.getUnscaledAngle(f);
if (this.zj.categoryMode != 0) {
g -= 0.5;
}
e = g;
}
return e;
}
aaj(a, b, c, d) {
return this.zj.rz(a, b, c, d);
}
kc(a) {
let b = truncate(Math.round(this.iy(a)));
let c = false;
if (this.zj != null && this.zj.ds) {
let d = this.zj;
let e = d.hasOthersCategory && b == this.zj.p7 - 1;
c = e;
}
if (c) {
let f = this.zj;
return this.zj.p7 - 1;
}
if (this.dp != null && b == this.dp.count) {
b = 0;
}
return b;
}
gj(a) {
return false;
}
zt() {
let a = this.zs;
if (this.d4()) {
if (this.dd.g) {
this.dd.t();
}
a = this.zv;
}
return a;
}
qo() {
super.qo();
if (this.zj != null) {
this.zj.lv(false);
}
if (this.zp != null) {
this.zp.lv(false);
}
}
hk(a, b, c) {
let d = true;
let e = c;
if (!super.hk(a, b, c) || !c.r() || b.isEmpty || a.isEmpty || this.zj == null || this.zj.itemsSource == null || this.zp == null || this.zq == null || this.dp == null || this.zj.b2 == null || this.zp.b2 == null || this.zp.qt == this.zp.qs) {
e.da.b = 0;
d = false;
}
return d;
}
zm() {
return 1;
}
aam() {
return Math.max(0, 0.5 * this.zp.tc);
}
gt() {
return this.aab;
}
gu() {
return true;
}
r8(a) {
super.r8(a);
this.zr.da.e(this.ik);
if (this.d7(this.cw)) {
this.zs.ae();
this.zv.ae();
this.zu.ae();
return;
}
if (this.gx) {
if (this.d4()) {
if (this.dd.g) {
this.dd.t();
}
this.abv(this.zv, this.zr);
}
else {
this.abv(this.zs, this.zr);
}
return;
}
if (this.gl(a)) {
let b = this.zu;
if (this.d4()) {
if (this.dd.g) {
this.dd.t();
}
this.zu = this.zv;
this.zv = b;
}
else {
this.zu = this.zs;
this.zs = b;
}
let c = false;
this.abs(this.zs, this.zr);
if (this.g9) {
this.dd.w();
this.dd.r = truncate(this.ji());
this.dd.b = this.df != null ? this.df : this.de;
if (this.ha) {
let d = this.zv;
this.zv = this.zu;
this.zu = d;
c = true;
}
this.zo.x(this, this.zu, this.zs, this.isVertical, this.zj, this.zp, this.zn, this.zm(), this.c6, this.c5(), runOn(this, this.aam), this.zr.b9);
if (this.ha) {
let e = this.zv;
this.zv = this.zu;
this.zu = e;
}
this.ha = false;
}
if (this.hc) {
this.dd.w();
this.dd.r = truncate(this.jj());
this.dd.b = this.dg != null ? this.dg : this.de;
if (this.g7) {
let f = this.zv;
this.zv = this.zu;
this.zu = f;
c = true;
}
this.zo.x(this, this.zu, this.zs, this.isVertical, this.zj, this.zp, this.zn, this.zm(), this.c6, this.c5(), runOn(this, this.aam), this.zr.b9);
let g = this.zs;
this.zs = this.zu;
this.zu = g;
if (this.g7) {
let h = this.zv;
this.zv = this.zu;
this.zu = h;
}
this.g7 = false;
}
this.eb = false;
if (!c) {
this.pd();
}
this.so();
if (this.g9) {
this.g8 = false;
this.g7 = true;
}
if (this.hc) {
this.hb = false;
this.ha = true;
}
}
else {
this.abs(this.zs, this.zr);
this.abv(this.zs, this.zr);
}
}
aar() {
if (this.bo != null) {
let a = this.bo;
return a.aar();
}
let b = 0;
for (let c of fromEnum(this.dc.b9)) {
if (c == this || this.bo == c) {
return b;
}
let d = typeCast(RadialBase.$, c);
if (d != null && d.zj == this.zj && d.preferredCategoryMode(d.zj) == 2) {
b++;
}
}
return -1;
}
ak(a, b) {
let c = new List$1(ChartSelection.$, 0);
this.qh(a, c, b);
return c.toArray();
}
qh(a, b, c) {
let d = this.cw.ca;
let e = this.cw.b9;
let f = this.cw.getEffectiveViewport();
let g, h;
let i = this.zq.f(this.dc.yw(a), d, e, f, g, h);
g = i.p4;
h = i.p5;
if (g == -1 || h == -1) {
return;
}
let j = h - g + 1;
if (g > h) {
j = this.zj.p8 - g + h + 1;
}
if (j > 0 && (c == 7 || c == 6)) {
b.add(((() => {
let $ret = new ChartSelection();
$ret.series = this;
return $ret;
})()));
return;
}
for (let k = 0; k < j; k++) {
let l = (k + g) % (this.zj.p8);
if (c == 2 || c == 1) {
b.add(((() => {
let $ret = new ChartSelection();
$ret.item = this.zj.pj.item(l);
return $ret;
})()));
}
else {
b.add(((() => {
let $ret = new ChartSelection();
$ret.item = this.zj.pj.item(l);
$ret.series = this;
return $ret;
})()));
}
}
}
}
RadialBase.$t = markType(RadialBase, 'RadialBase', MarkerSeries.$, [IHasCategoryModePreference_$type]);
RadialBase.$$p = markDep(DependencyProperty, PropertyMetadata, RadialBase, 'raisePropertyChanged', ['AngleAxis:zj:abw', [CategoryAngleAxis.$, null], 'AutoCalloutLabelPrecision:aan:abx', [1, -1], 'AutoCalloutLabelValueSeparator:aaw:aby', [2, " - "], 'AutoCalloutOthersLabelFormat:aay:abz', [2, null], 'AutoCalloutOthersLabelFormatSpecifiers:y6:ab0', [Array_$type, null], 'AutoCalloutPercentagePrecision:aao:ab1', [1, 2], 'AutoCalloutRadialLabelMode:zw:ab2', [RadialLabelMode_$type, enumGetBox(RadialLabelMode_$type, 0)], 'CategoryCollisionMode:zk:ab3', [CategoryCollisionMode_$type, enumGetBox(CategoryCollisionMode_$type, 1)], 'ClipSeriesToBounds:z8:ab4', [0, false], 'IsCustomRadialMarkerStyleAllowed:z9:ab5', [0, false], 'IsCustomRadialStyleAllowed:aaa:ab6', [0, false], 'IsTransitionInEnabled:aab:ab7', [0, false], 'LegendProportionalRadialLabelFormat:abb:ab8', [2, null], 'LegendProportionalRadialLabelFormatSpecifiers:y8:ab9', [Array_$type, null], 'LegendRadialLabelMode:zx:aca', [RadialLabelMode_$type, enumGetBox(RadialLabelMode_$type, 0)], 'OthersLegendProportionalRadialLabelFormat:abf:acb', [2, null], 'OthersLegendProportionalRadialLabelFormatSpecifiers:y9:acc', [Array_$type, null], 'OthersProportionalRadialLabelFormat:abi:acd', [2, null], 'OthersProportionalRadialLabelFormatSpecifiers:za:ace', [Array_$type, null], 'ProportionalRadialLabelFormat:abl:acf', [2, null], 'ProportionalRadialLabelFormatSpecifiers:zb:acg', [Array_$type, null], 'TransitionInMode:zn:ach', [CategoryTransitionInMode_$type, enumGetBox(CategoryTransitionInMode_$type, 0)], 'ValueAxis:zp:aci', [NumericRadiusAxis.$, null]]);
return RadialBase;
})();
/**
* @hidden
*/
export let RadialBaseView = /*@__PURE__*/ (() => {
class RadialBaseView extends MarkerSeriesView {
constructor(a) {
super(a);
this.da = null;
this.c9 = null;
this.db = null;
this.dc = 0;
this.dd = null;
this.c9 = a;
this.db = new Pool$1(Marker.$);
this.c0(this.db);
}
cw(a) {
this.db.c(a);
}
}
RadialBaseView.$t = markType(RadialBaseView, 'RadialBaseView', MarkerSeriesView.$);
return RadialBaseView;
})();