@hybridcore/ui 1.6.30 → 1.6.32

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.
@@ -3,18 +3,18 @@ import { useTheme as Ue, useThemeProps as $e } from "@mui/material";
3
3
  import Q from "lodash";
4
4
  import { useState as Ne, useRef as M, useLayoutEffect as Ge, useEffect as He } from "react";
5
5
  import { getTooltipDateFormat as We, attachCursorTooltip as ze } from "../_common/tooltip.js";
6
- import { applyValueFormat as Ze } from "../_common/utils.js";
7
- import { c as O, a as Ae } from "../../../Entity-BJCuhdq_.js";
8
- import { X as qe, V as Je } from "../../../AxisRenderer-BCQoUJw6.js";
9
- import { X as Ke } from "../../../XYCursor-CVUSpqb9.js";
10
- import { A as Qe, a as et } from "../../../AxisRendererY-AXWvGU6r.js";
11
- import { L as tt } from "../../../Legend-CFvQiIfn.js";
6
+ import { applyInterfaceColors as Ze, applyValueFormat as qe } from "../_common/utils.js";
7
+ import { X as Je, V as Ke } from "../../../AxisRenderer-BCQoUJw6.js";
8
+ import { X as Qe } from "../../../XYCursor-CVUSpqb9.js";
9
+ import { A as et, a as tt } from "../../../AxisRendererY-AXWvGU6r.js";
10
+ import { c as S, a as Ae } from "../../../Entity-BJCuhdq_.js";
11
+ import { L as it } from "../../../Legend-CFvQiIfn.js";
12
12
  import { L as G } from "../../../LineSeries-D_IL2qGF.js";
13
- import { C as it } from "../../../Circle-BnfBNKBD.js";
14
- import { B as rt } from "../../../Bullet-Djj7Vs9T.js";
15
- import { G as nt, D as st } from "../../../GaplessDateAxis-B2g2jgSG.js";
16
- import { D as ot } from "../../../DateAxis-DEXKps1S.js";
17
- class at {
13
+ import { C as rt } from "../../../Circle-BnfBNKBD.js";
14
+ import { B as nt } from "../../../Bullet-Djj7Vs9T.js";
15
+ import { G as st, D as ot } from "../../../GaplessDateAxis-B2g2jgSG.js";
16
+ import { D as at } from "../../../DateAxis-DEXKps1S.js";
17
+ class lt {
18
18
  constructor(r, a) {
19
19
  Object.defineProperty(this, "_line", {
20
20
  enumerable: !0,
@@ -84,7 +84,7 @@ class at {
84
84
  (this._line || this._line !== 0 && this._point === 1) && this._context.closePath(), this._line = 1 - this._line;
85
85
  }
86
86
  point(r, a) {
87
- let h = NaN;
87
+ let d = NaN;
88
88
  if (r = +r, a = +a, !(r === this._x1 && a === this._y1)) {
89
89
  switch (this._point) {
90
90
  case 0:
@@ -94,19 +94,19 @@ class at {
94
94
  this._point = 2;
95
95
  break;
96
96
  case 2:
97
- this._point = 3, ae(this, Oe(this, h = De(this, r, a)), h);
97
+ this._point = 3, ae(this, Oe(this, d = De(this, r, a)), d);
98
98
  break;
99
99
  default:
100
- ae(this, this._t0, h = De(this, r, a));
100
+ ae(this, this._t0, d = De(this, r, a));
101
101
  break;
102
102
  }
103
- this._x0 = this._x1, this._x1 = r, this._y0 = this._y1, this._y1 = a, this._t0 = h;
103
+ this._x0 = this._x1, this._x1 = r, this._y0 = this._y1, this._y1 = a, this._t0 = d;
104
104
  }
105
105
  }
106
106
  }
107
107
  function Ie(i) {
108
108
  function r(a) {
109
- return new at(a, i);
109
+ return new lt(a, i);
110
110
  }
111
111
  return r;
112
112
  }
@@ -114,7 +114,7 @@ function ke(i) {
114
114
  return i < 0 ? -1 : 1;
115
115
  }
116
116
  function De(i, r, a) {
117
- let h = i._x1 - i._x0, s = r - i._x1, f = (i._y1 - i._y0) / (h || s < 0 && -0), c = (a - i._y1) / (s || h < 0 && -0), x = (f * s + c * h) / (h + s);
117
+ let d = i._x1 - i._x0, s = r - i._x1, f = (i._y1 - i._y0) / (d || s < 0 && -0), c = (a - i._y1) / (s || d < 0 && -0), x = (f * s + c * d) / (d + s);
118
118
  return (ke(f) + ke(c)) * Math.min(Math.abs(f), Math.abs(c), 0.5 * Math.abs(x)) || 0;
119
119
  }
120
120
  function Oe(i, r) {
@@ -122,8 +122,8 @@ function Oe(i, r) {
122
122
  return a ? (3 * (i._y1 - i._y0) / a - r) / 2 : r;
123
123
  }
124
124
  function ae(i, r, a) {
125
- let h = i._x0, s = i._y0, f = i._x1, c = i._y1, x = (f - h) / 1.5 * (1 - i._tension);
126
- i._context.bezierCurveTo(h + x, s + x * r, f - x, c - x * a, f, c);
125
+ let d = i._x0, s = i._y0, f = i._x1, c = i._y1, x = (f - d) / 1.5 * (1 - i._tension);
126
+ i._context.bezierCurveTo(d + x, s + x * r, f - x, c - x * a, f, c);
127
127
  }
128
128
  class H extends G {
129
129
  _afterNew() {
@@ -145,10 +145,10 @@ Object.defineProperty(H, "classNames", {
145
145
  writable: !0,
146
146
  value: G.classNames.concat([H.className])
147
147
  });
148
- const lt = [
148
+ const ct = [
149
149
  { lowerField: "low95", upperField: "high95", label: "95% expected move" },
150
150
  { lowerField: "low68", upperField: "high68", label: "68% expected move" }
151
- ], ct = [0.15, 0.3, 0.45], le = 1.1, ut = "spineValue", Te = 5, pt = 7.5, mt = {
151
+ ], ut = [0.15, 0.3, 0.45], le = 1.1, pt = "spineValue", Te = 5, mt = 7.5, ht = {
152
152
  millisecond: 1,
153
153
  second: 1e3,
154
154
  minute: 6e4,
@@ -157,18 +157,18 @@ const lt = [
157
157
  week: 6048e5,
158
158
  month: 2592e6,
159
159
  year: 31536e6
160
- }, T = (i) => new Date(i).getTime(), dt = (i) => new Intl.DateTimeFormat("en-US", {
160
+ }, O = (i) => new Date(i).getTime(), dt = (i) => new Intl.DateTimeFormat("en-US", {
161
161
  month: "short",
162
162
  day: "numeric",
163
163
  hour: "2-digit",
164
164
  minute: "2-digit"
165
- }).format(new Date(i)), Ce = (i) => i.label ?? dt(i.origin), Et = (i) => {
165
+ }).format(new Date(i)), Ce = (i) => i.label ?? dt(i.origin), Pt = (i) => {
166
166
  const r = Ue(), a = $e({ props: i, name: "HCForecastCone" }), {
167
- data: h = [],
167
+ data: d = [],
168
168
  dateField: s = "date",
169
169
  historyField: f = "close",
170
170
  centreField: c = "center",
171
- bands: x = lt,
171
+ bands: x = ct,
172
172
  forecasts: _,
173
173
  showOriginMarkers: ee = !0,
174
174
  nowValue: te,
@@ -179,20 +179,20 @@ const lt = [
179
179
  chartId: me = "forecast-cone-chart",
180
180
  height: Ee = "100%",
181
181
  width: Pe = "100%",
182
- loading: de = !1,
183
- emptyMessage: he = "No data available",
182
+ loading: he = !1,
183
+ emptyMessage: de = "No data available",
184
184
  sx: Le,
185
185
  ...Se
186
- } = a, C = Array.isArray(_) && _.length > 0, [fe, be] = Ne(
187
- () => C ? _.length - 1 : 0
186
+ } = a, T = Array.isArray(_) && _.length > 0, [fe, be] = Ne(
187
+ () => T ? _.length - 1 : 0
188
188
  ), [W, ie] = Ne(
189
189
  null
190
190
  ), Y = W ?? fe, z = M(Y);
191
191
  z.current = Y;
192
192
  const ge = M(W !== null);
193
193
  ge.current = W !== null;
194
- const w = Q.orderBy(h, [s]).map((e) => ({ ...e }));
195
- if (!C) {
194
+ const w = Q.orderBy(d, [s]).map((e) => ({ ...e }));
195
+ if (!T) {
196
196
  const e = w.findIndex(
197
197
  (p) => p[c] !== null && p[c] !== void 0
198
198
  );
@@ -203,21 +203,17 @@ const lt = [
203
203
  height: Ee,
204
204
  width: Pe,
205
205
  chartId: me,
206
- loading: de,
207
- emptyMessage: he,
206
+ loading: he,
207
+ emptyMessage: de,
208
208
  baseInterval: pe
209
209
  }, _e = M(null), ve = M(null), re = M(null), V = M(null);
210
210
  Ge(() => {
211
211
  var xe, we;
212
212
  if (!re.current) return;
213
213
  const e = Be.new(re.current);
214
- ve.current = e, e.setThemes([je.new(e)]), e.interfaceColors.setAll({
215
- text: O(r.palette.text.primary),
216
- grid: O(r.palette.divider),
217
- stroke: O(r.palette.divider)
218
- }), Ze(e);
214
+ ve.current = e, e.setThemes([je.new(e)]), Ze(e, r), qe(e);
219
215
  const p = e.container.children.push(
220
- qe.new(e, {
216
+ Je.new(e, {
221
217
  panX: !0,
222
218
  panY: !1,
223
219
  wheelX: "none",
@@ -229,38 +225,38 @@ const lt = [
229
225
  );
230
226
  _e.current = p, p.set(
231
227
  "cursor",
232
- Ke.new(e, { behavior: "none" })
228
+ Qe.new(e, { behavior: "none" })
233
229
  ).lineY.set("visible", !1);
234
- const Z = pe ?? { timeUnit: "hour", count: 1 }, ne = ue, Re = ne ? nt : ot, b = p.xAxes.push(
230
+ const Z = pe ?? { timeUnit: "hour", count: 1 }, ne = ue, Re = ne ? st : at, b = p.xAxes.push(
235
231
  Re.new(e, {
236
232
  maxDeviation: 0.1,
237
233
  groupData: !1,
238
234
  baseInterval: Z,
239
- renderer: Qe.new(e, {})
235
+ renderer: et.new(e, {})
240
236
  })
241
237
  );
242
238
  (xe = b.get("renderer")) == null || xe.grid.template.setAll({
243
- stroke: O(r.palette.divider),
239
+ stroke: S(r.palette.divider),
244
240
  strokeOpacity: 1
245
241
  });
246
- const E = p.yAxes.push(
247
- Je.new(e, {
248
- renderer: et.new(e, {})
242
+ const C = p.yAxes.push(
243
+ Ke.new(e, {
244
+ renderer: tt.new(e, {})
249
245
  })
250
246
  );
251
- (we = E.get("renderer")) == null || we.grid.template.setAll({
252
- stroke: O(r.palette.divider),
247
+ (we = C.get("renderer")) == null || we.grid.template.setAll({
248
+ stroke: S(r.palette.divider),
253
249
  strokeOpacity: 1
254
250
  });
255
- const B = O(ce), Ye = p.children.push(
256
- tt.new(e, { centerX: Ae, x: Ae })
257
- ), se = () => st.new(e, { dateFormat: "i", dateFields: [s] }), ye = C ? [] : w, q = [];
258
- x.forEach((u, d) => {
251
+ const B = S(ce), Ye = p.children.push(
252
+ it.new(e, { centerX: Ae, x: Ae })
253
+ ), se = () => ot.new(e, { dateFormat: "i", dateFields: [s] }), ye = T ? [] : w, q = [];
254
+ x.forEach((u, h) => {
259
255
  const l = p.series.push(
260
256
  H.new(e, {
261
- name: u.label ?? `Band ${d + 1}`,
257
+ name: u.label ?? `Band ${h + 1}`,
262
258
  xAxis: b,
263
- yAxis: E,
259
+ yAxis: C,
264
260
  valueYField: u.upperField,
265
261
  openValueYField: u.lowerField,
266
262
  valueXField: s,
@@ -273,7 +269,7 @@ const lt = [
273
269
  l.strokes.template.set("strokeOpacity", 0), l.fills.template.setAll({
274
270
  visible: !0,
275
271
  fill: B,
276
- fillOpacity: u.fillOpacity ?? ct[d] ?? 0.2
272
+ fillOpacity: u.fillOpacity ?? ut[h] ?? 0.2
277
273
  }), l.data.processor = se(), l.data.setAll(ye), q.push(l);
278
274
  });
279
275
  let F;
@@ -281,77 +277,77 @@ const lt = [
281
277
  H.new(e, {
282
278
  name: "Forecast centre",
283
279
  xAxis: b,
284
- yAxis: E,
280
+ yAxis: C,
285
281
  valueYField: c,
286
282
  valueXField: s,
287
283
  connect: R,
288
284
  autoGapCount: le,
289
- stroke: O(r.palette.error.main)
285
+ stroke: S(r.palette.error.main)
290
286
  })
291
287
  ), F.strokes.template.setAll({
292
288
  strokeWidth: 1.5,
293
289
  strokeDasharray: [4, 4]
294
290
  }), F.fills.template.set("visible", !1), F.data.processor = se(), F.data.setAll(ye));
295
- const L = C ? Q.orderBy(h, [s]).map((u) => ({ ...u })) : w, J = p.series.push(
291
+ const P = T ? Q.orderBy(d, [s]).map((u) => ({ ...u })) : w, J = p.series.push(
296
292
  G.new(e, {
297
293
  name: "History",
298
294
  xAxis: b,
299
- yAxis: E,
295
+ yAxis: C,
300
296
  valueYField: f,
301
297
  valueXField: s,
302
298
  // When false, the history line breaks at missing dates (gap > ~1 base
303
299
  // interval) instead of bridging across them.
304
300
  connect: R,
305
301
  autoGapCount: le,
306
- stroke: O(r.palette.primary.main)
302
+ stroke: S(r.palette.primary.main)
307
303
  })
308
304
  );
309
- J.strokes.template.setAll({ strokeWidth: 2 }), J.data.processor = se(), J.data.setAll(L), Ye.data.setAll(p.series.values);
310
- const K = (mt[Z.timeUnit] ?? 0) * Z.count / 2, oe = (u, d) => {
305
+ J.strokes.template.setAll({ strokeWidth: 2 }), J.data.processor = se(), J.data.setAll(P), Ye.data.setAll(p.series.values);
306
+ const K = (ht[Z.timeUnit] ?? 0) * Z.count / 2, oe = (u, h) => {
311
307
  var l;
312
308
  return (l = u.get("grid")) == null ? void 0 : l.setAll({
313
309
  visible: !0,
314
- stroke: O(r.palette.text.secondary),
315
- strokeOpacity: d,
310
+ stroke: S(r.palette.text.secondary),
311
+ strokeOpacity: h,
316
312
  strokeDasharray: [2, 3]
317
313
  });
318
314
  };
319
- if (C) {
315
+ if (T) {
320
316
  const u = /* @__PURE__ */ new Set();
321
- let d = 1 / 0, l = -1 / 0, v = -1 / 0;
317
+ let h = 1 / 0, l = -1 / 0, v = -1 / 0;
322
318
  const A = (t) => {
323
- typeof t == "number" && Number.isFinite(t) && (t < d && (d = t), t > l && (l = t));
319
+ typeof t == "number" && Number.isFinite(t) && (t < h && (h = t), t > l && (l = t));
324
320
  };
325
- L.forEach((t) => {
321
+ P.forEach((t) => {
326
322
  A(t[f]);
327
- const n = T(t[s]);
323
+ const n = O(t[s]);
328
324
  Number.isFinite(n) && u.add(n);
329
325
  });
330
- const y = L.length ? T(L[0][s]) : NaN;
326
+ const y = P.length ? O(P[0][s]) : NaN;
331
327
  if (_.forEach(
332
328
  (t) => t.rows.forEach((n) => {
333
329
  x.forEach((g) => {
334
330
  A(n[g.lowerField]), A(n[g.upperField]);
335
331
  }), c && A(n[c]);
336
- const m = T(n[s]);
332
+ const m = O(n[s]);
337
333
  Number.isFinite(m) && (u.add(m), m > v && (v = m));
338
334
  })
339
- ), L.length) {
340
- const t = T(L[L.length - 1][s]);
335
+ ), P.length) {
336
+ const t = O(P[P.length - 1][s]);
341
337
  Number.isFinite(t) && t > v && (v = t);
342
338
  }
343
- if (Number.isFinite(d) && Number.isFinite(l)) {
344
- const t = (l - d) * 0.05 || 1;
345
- E.set("min", d - t), E.set("max", l + t), E.set("strictMinMax", !0);
339
+ if (Number.isFinite(h) && Number.isFinite(l)) {
340
+ const t = (l - h) * 0.05 || 1;
341
+ C.set("min", h - t), C.set("max", l + t), C.set("strictMinMax", !0);
346
342
  }
347
343
  if (ne) {
348
344
  const t = p.series.push(
349
345
  G.new(e, {
350
346
  name: "Timeline",
351
347
  xAxis: b,
352
- yAxis: E,
348
+ yAxis: C,
353
349
  valueXField: s,
354
- valueYField: ut
350
+ valueYField: pt
355
351
  })
356
352
  );
357
353
  t.strokes.template.set("strokeOpacity", 0), t.fills.template.set("visible", !1), t.data.setAll(
@@ -359,7 +355,7 @@ const lt = [
359
355
  );
360
356
  }
361
357
  !ne && Number.isFinite(y) && Number.isFinite(v) && (b.set("min", y), b.set("max", v + K), b.set("strictMinMax", !0)), ee || _.forEach((t) => {
362
- const n = T(t.origin);
358
+ const n = O(t.origin);
363
359
  if (Number.isNaN(n)) return;
364
360
  const m = b.createAxisRange(
365
361
  b.makeDataItem({ value: n + K })
@@ -369,66 +365,66 @@ const lt = [
369
365
  const I = b.makeDataItem({ value: 0 }), j = b.createAxisRange(I);
370
366
  oe(j, 0.8);
371
367
  const X = /* @__PURE__ */ new Map(), U = (t, n) => t.setAll({
372
- radius: n ? pt : Te,
368
+ radius: n ? mt : Te,
373
369
  fillOpacity: n ? 1 : 0.6
374
370
  });
375
371
  if (ee) {
376
- const t = L.map((o) => ({ t: T(o[s]), v: o[f] })).filter(
372
+ const t = P.map((o) => ({ t: O(o[s]), v: o[f] })).filter(
377
373
  (o) => Number.isFinite(o.t) && typeof o.v == "number" && Number.isFinite(o.v)
378
374
  ), n = (o) => {
379
- let P;
375
+ let E;
380
376
  for (const k of t) {
381
377
  if (k.t > o) break;
382
- P = k.v;
378
+ E = k.v;
383
379
  }
384
- return P;
380
+ return E;
385
381
  }, m = [];
386
- _.forEach((o, P) => {
382
+ _.forEach((o, E) => {
387
383
  var $;
388
- const k = T(o.origin);
384
+ const k = O(o.origin);
389
385
  if (!Number.isFinite(k)) return;
390
- const S = c ? ($ = Q.orderBy(o.rows, [s]).find(
386
+ const L = c ? ($ = Q.orderBy(o.rows, [s]).find(
391
387
  (Fe) => Fe[c] !== null && Fe[c] !== void 0
392
- )) == null ? void 0 : $[c] : void 0, D = n(k) ?? S;
388
+ )) == null ? void 0 : $[c] : void 0, D = n(k) ?? L;
393
389
  typeof D != "number" || !Number.isFinite(D) || m.push({
394
390
  originDate: k,
395
391
  originValue: D,
396
- originIndex: P
392
+ originIndex: E
397
393
  });
398
394
  });
399
395
  const g = p.series.push(
400
396
  G.new(e, {
401
397
  name: "Forecast runs",
402
398
  xAxis: b,
403
- yAxis: E,
399
+ yAxis: C,
404
400
  valueXField: "originDate",
405
401
  valueYField: "originValue"
406
402
  })
407
403
  );
408
- g.strokes.template.set("strokeOpacity", 0), g.fills.template.set("visible", !1), g.bullets.push((o, P, k) => {
409
- const S = k.dataContext, D = it.new(o, {
404
+ g.strokes.template.set("strokeOpacity", 0), g.fills.template.set("visible", !1), g.bullets.push((o, E, k) => {
405
+ const L = k.dataContext, D = rt.new(o, {
410
406
  radius: Te,
411
407
  fill: B,
412
408
  fillOpacity: 0.6,
413
- stroke: O(r.palette.background.paper),
409
+ stroke: S(r.palette.background.paper),
414
410
  strokeWidth: 2,
415
411
  interactive: !0,
416
412
  cursorOverStyle: "pointer"
417
413
  });
418
- return U(D, S.originIndex === z.current), D.events.on(
414
+ return U(D, L.originIndex === z.current), D.events.on(
419
415
  "pointerover",
420
- () => ie(S.originIndex)
416
+ () => ie(L.originIndex)
421
417
  ), D.events.on(
422
418
  "pointerout",
423
419
  () => (
424
420
  // Guard against a neighbouring bullet's `pointerover` landing first.
425
421
  ie(
426
- ($) => $ === S.originIndex ? null : $
422
+ ($) => $ === L.originIndex ? null : $
427
423
  )
428
424
  )
429
425
  ), D.events.on("click", () => {
430
- be(S.originIndex), ie(null);
431
- }), X.set(S.originIndex, D), rt.new(o, { sprite: D });
426
+ be(L.originIndex), ie(null);
427
+ }), X.set(L.originIndex, D), nt.new(o, { sprite: D });
432
428
  }), g.data.setAll(m);
433
429
  }
434
430
  const N = (t) => {
@@ -438,18 +434,18 @@ const lt = [
438
434
  ...o
439
435
  }));
440
436
  q.forEach((o) => o.data.setAll(m)), F == null || F.data.setAll(m);
441
- const g = T(n.origin);
437
+ const g = O(n.origin);
442
438
  I.set("value", Number.isNaN(g) ? 0 : g + K), X.forEach(
443
- (o, P) => U(o, P === t)
439
+ (o, E) => U(o, E === t)
444
440
  );
445
441
  };
446
442
  V.current = N, N(z.current);
447
443
  } else {
448
444
  const u = w.findIndex(
449
445
  (y) => y[c] !== null && y[c] !== void 0
450
- ), d = [...w].reverse().find(
446
+ ), h = [...w].reverse().find(
451
447
  (y) => y[f] !== null && y[f] !== void 0
452
- ), l = u >= 0 ? w[u] : d, v = te !== void 0 ? T(te) : l ? T(l[s]) : NaN, A = Number.isNaN(v) ? NaN : v + K;
448
+ ), l = u >= 0 ? w[u] : h, v = te !== void 0 ? O(te) : l ? O(l[s]) : NaN, A = Number.isNaN(v) ? NaN : v + K;
453
449
  if (!Number.isNaN(A)) {
454
450
  const y = b.createAxisRange(
455
451
  b.makeDataItem({ value: A })
@@ -464,20 +460,20 @@ const lt = [
464
460
  theme: r,
465
461
  getText: () => {
466
462
  var U;
467
- const u = (N) => N == null ? "—" : e.numberFormatter.format(N), d = J.get("tooltipDataItem"), l = F == null ? void 0 : F.get("tooltipDataItem"), v = l ?? d ?? ((U = q[0]) == null ? void 0 : U.get("tooltipDataItem")), A = v == null ? void 0 : v.get("valueX"), y = typeof A == "number" ? e.dateFormatter.format(new Date(A), Ve) : "", I = [];
468
- if (C && ge.current) {
463
+ const u = (N) => N == null ? "—" : e.numberFormatter.format(N), h = J.get("tooltipDataItem"), l = F == null ? void 0 : F.get("tooltipDataItem"), v = l ?? h ?? ((U = q[0]) == null ? void 0 : U.get("tooltipDataItem")), A = v == null ? void 0 : v.get("valueX"), y = typeof A == "number" ? e.dateFormatter.format(new Date(A), Ve) : "", I = [];
464
+ if (T && ge.current) {
469
465
  const N = _[z.current];
470
466
  N && I.push(`Forecast run: ${Ce(N)}`);
471
467
  }
472
- const j = d == null ? void 0 : d.get("valueY");
468
+ const j = h == null ? void 0 : h.get("valueY");
473
469
  j != null && I.push(`History: ${u(j)}`);
474
470
  const X = l == null ? void 0 : l.get("valueY");
475
471
  return X != null && I.push(`Centre: ${u(X)}`), x.forEach((N, t) => {
476
472
  var o;
477
473
  const n = (o = q[t]) == null ? void 0 : o.get("tooltipDataItem"), m = n == null ? void 0 : n.get("valueY"), g = n == null ? void 0 : n.get("openValueY");
478
474
  if (m != null && g !== void 0 && g !== null) {
479
- const P = (m - g) / 2, k = N.label ?? `Band ${t + 1}`;
480
- I.push(`[${B.toCSSHex()}]●[/] ${k}: ±${u(P)}`);
475
+ const E = (m - g) / 2, k = N.label ?? `Band ${t + 1}`;
476
+ I.push(`[${B.toCSSHex()}]●[/] ${k}: ±${u(E)}`);
481
477
  }
482
478
  }), I.length === 0 ? "" : y ? `[bold]${y}[/]
483
479
  ${I.join(`
@@ -489,7 +485,7 @@ ${I.join(`
489
485
  };
490
486
  }, [
491
487
  r.palette.mode,
492
- h,
488
+ d,
493
489
  x,
494
490
  _,
495
491
  ee,
@@ -501,20 +497,20 @@ ${I.join(`
501
497
  var e;
502
498
  (e = V.current) == null || e.call(V, Y);
503
499
  }, [Y]);
504
- const Me = C ? _.map(Ce) : [];
500
+ const Me = T ? _.map(Ce) : [];
505
501
  return {
506
502
  chartDivRef: re,
507
503
  data: w,
508
504
  chartId: me,
509
- loading: de,
510
- emptyMessage: he,
511
- isMulti: C,
505
+ loading: he,
506
+ emptyMessage: de,
507
+ isMulti: T,
512
508
  origins: Me,
513
509
  selectedOriginIndex: fe,
514
510
  shownOriginIndex: Y,
515
511
  isPreviewing: W !== null,
516
512
  onOriginChange: (e) => {
517
- if (!C) return;
513
+ if (!T) return;
518
514
  const p = Math.max(0, Math.min(_.length - 1, e));
519
515
  be(p);
520
516
  },
@@ -524,5 +520,5 @@ ${I.join(`
524
520
  };
525
521
  };
526
522
  export {
527
- Et as useForecastConeChartLogic
523
+ Pt as useForecastConeChartLogic
528
524
  };