@blueprint-chart/lib 2.1.0 → 2.2.0

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.
@@ -31,6 +31,7 @@ export declare function renderInsideArcLabels(parent: d3.Selection<SVGGElement,
31
31
  chartWidth: number;
32
32
  chartHeight: number;
33
33
  fontSize?: number;
34
+ bgColor?: string;
34
35
  }): void;
35
36
  export declare function renderAutoArcLabels(parent: d3.Selection<SVGGElement, unknown, null, undefined>, data: ArcLabelDatum[], opts: {
36
37
  outerRadius: number;
@@ -12,7 +12,7 @@ export declare const DEFAULT_BAR_GAP = 60;
12
12
  * to [0, 100]; non-finite or undefined values fall back to DEFAULT_BAR_GAP.
13
13
  */
14
14
  export declare function resolveBarGapPadding(barGap?: number): number;
15
- export declare function computeLinearDomain(values: number[], range?: AxisRange, scaleType?: ScaleType): [number, number];
15
+ export declare function computeLinearDomain(values: number[], range?: AxisRange, scaleType?: ScaleType, anchorZero?: boolean): [number, number];
16
16
  /**
17
17
  * Decade tick values (1, 10, 100, ...) for a logarithmic axis, or null when the
18
18
  * scale is not logarithmic or holds no decade.
@@ -7,6 +7,11 @@ export interface ValueLabelFitInput {
7
7
  /** px extent along y (vertical bar: length; horizontal bar: thickness) */
8
8
  barHeight: number;
9
9
  }
10
+ /**
11
+ * A per-character estimate held while labels were bare numbers. A number
12
+ * format adds a prefix and a suffix (`$1,200,000.0M`), and the shared measurer
13
+ * keeps the `max(measured, floor)` shape that a headless CJK render needs.
14
+ */
10
15
  export declare function estimateLabelWidth(text: string): number;
11
16
  export declare function shouldRenderValueLabel(input: ValueLabelFitInput): boolean;
12
17
  /**
package/dist/embed.js CHANGED
@@ -1,2 +1,2 @@
1
- import { a as e, i as t, o as n, r, t as i } from "./runtime-DDhsXDn5.js";
1
+ import { a as e, i as t, o as n, r, t as i } from "./runtime-gzeMNwqx.js";
2
2
  export { r as ERROR_MESSAGE, t as RESIZE_MESSAGE, i as buildSrcdoc, e as isErrorMessage, n as readResizeHeight };
package/dist/enums.d.ts CHANGED
@@ -44,6 +44,24 @@ export declare enum TickPosition {
44
44
  Above = "above",
45
45
  Below = "below"
46
46
  }
47
+ /**
48
+ * How the frame sizes itself, as the *renderer* names it.
49
+ *
50
+ * These are deliberately not the DSL's vocabulary. The `sizing` property in BPC
51
+ * source takes `responsive`, `fixed` or `max-width`, and the two sets share no
52
+ * value, so `sizing = standard` in a chart is not valid DSL. The mapping:
53
+ *
54
+ * | DSL `sizing` | FrameSizing | meaning |
55
+ * |--------------|----------------|-----------------------------------------|
56
+ * | `responsive` | `Auto` | fill the container |
57
+ * | `fixed` | `Standard` | a fixed width, set by `fixedWidth` |
58
+ * | `max-width` | `Standard` | fill up to `maxWidth` |
59
+ * | (n/a) | `AspectRatio` | reached through `heightMode`, not `sizing` |
60
+ *
61
+ * Renaming either side is a breaking change with no automatic migration (it
62
+ * would mean rewriting user BPC source), so the two vocabularies stay and this
63
+ * table is the contract. See issue #122.
64
+ */
47
65
  export declare enum FrameSizing {
48
66
  Auto = "auto",
49
67
  Standard = "standard",
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
- import { $ as e, A as t, At as n, B as r, Bt as i, C as a, Ct as o, D as s, Dt as c, E as l, Et as u, F as d, Ft as f, G as p, Gt as m, H as h, Ht as g, I as _, It as v, J as y, Jt as ee, K as te, Kt as ne, L as re, Lt as ie, M as ae, Mt as oe, N as se, Nt as ce, O as le, Ot as ue, P as b, Pt as de, Q as fe, R as pe, Rt as me, S as he, St as ge, T as _e, Tt as ve, U as x, Ut as ye, V as be, Vt as xe, W as Se, Wt as Ce, X as we, Xt as Te, Y as Ee, Yt as De, Z as Oe, Zt as ke, _ as Ae, _t as je, a as Me, at as Ne, b as Pe, bt as S, c as Fe, ct as Ie, d as Le, dt as Re, et as ze, f as Be, ft as Ve, g as He, gt as Ue, h as We, ht as Ge, i as Ke, it as qe, j as Je, jt as Ye, k as Xe, kt as Ze, l as Qe, lt as $e, m as et, mt as tt, n as nt, nt as rt, o as it, ot as at, p as ot, pt as st, q as ct, qt as lt, r as ut, rt as dt, s as ft, st as pt, t as mt, tt as ht, u as gt, ut as _t, v as vt, vt as yt, w as bt, wt as xt, x as St, xt as Ct, y as wt, yt as Tt, z as C, zt as Et } from "./render-bpc-BSt4wOjf.js";
2
- import { t as Dt } from "./runtime-DDhsXDn5.js";
1
+ import { $ as e, A as t, At as n, B as r, Bt as i, C as a, Ct as o, D as s, Dt as c, E as l, Et as u, F as d, Ft as f, G as p, Gt as m, H as h, Ht as g, I as _, It as v, J as y, Jt as ee, K as te, Kt as ne, L as re, Lt as ie, M as ae, Mt as oe, N as se, Nt as ce, O as le, Ot as ue, P as b, Pt as de, Q as fe, R as pe, Rt as me, S as he, St as ge, T as _e, Tt as ve, U as x, Ut as ye, V as be, Vt as xe, W as Se, Wt as Ce, X as we, Xt as Te, Y as Ee, Yt as De, Z as Oe, Zt as ke, _ as Ae, _t as je, a as Me, at as Ne, b as Pe, bt as S, c as Fe, ct as Ie, d as Le, dt as Re, et as ze, f as Be, ft as Ve, g as He, gt as Ue, h as We, ht as Ge, i as Ke, it as qe, j as Je, jt as Ye, k as Xe, kt as Ze, l as Qe, lt as $e, m as et, mt as tt, n as nt, nt as rt, o as it, ot as at, p as ot, pt as st, q as ct, qt as lt, r as ut, rt as dt, s as ft, st as pt, t as mt, tt as ht, u as gt, ut as _t, v as vt, vt as yt, w as bt, wt as xt, x as St, xt as Ct, y as wt, yt as Tt, z as C, zt as Et } from "./render-bpc-C4y50x4-.js";
2
+ import { t as Dt } from "./runtime-gzeMNwqx.js";
3
3
  import w from "chroma-js";
4
4
  //#region src/recommendations/intent.ts
5
5
  var Ot = [