@bicharts/chart-host 0.5.19 → 0.5.20

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/README.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # @bicharts/chart-host
2
2
 
3
+ > **Make Generative AI for Charts *Better*.**
4
+
5
+ That is what **RegiaBI** is for; this package is the part that runs the result in your page,
6
+ so a generated chart behaves the same wherever it lands.
7
+
3
8
  Run a D3 chart generated by
4
9
  [Business Intelligence Champions](https://bizintelligencechampions.com) (BIC) in any web page.
5
10
 
@@ -88,7 +88,25 @@ function resolveOptions(p2) {
88
88
  animMaxIdealFrames: clamp(Number(p2.animMaxIdealFrames) || ANIM_MAX_IDEAL_FRAMES_DEFAULT, ANIM_MAX_IDEAL_FRAMES_MIN, ANIM_MAX_IDEAL_FRAMES_MAX),
89
89
  animStopAtEnd: !!p2.animStopAtEnd,
90
90
  filtersDuringPlay: !!p2.filtersDuringPlay,
91
- animTimelineStyle: (p2.animTimelineStyle || "").toString()
91
+ animTimelineStyle: (p2.animTimelineStyle || "").toString(),
92
+ // ---- card deck ----
93
+ // SECOND OCCURRENCE OF THE animLoopDelaySec BUG, six lines above (2026-08-13). The
94
+ // visual passed both of these, the generated code read both correctly, and this
95
+ // function — a whitelist that returns a NEW object — dropped them in between. Symptoms
96
+ // were exactly what the two defaults produce: flipSync undefined -> `!== false` -> true
97
+ // -> always synced, so "Flip Cards Together = Off" did nothing and the deck kept its
98
+ // shared strip; flipIntervalMs undefined -> `+(undefined || 0)` -> 0 -> the timer branch
99
+ // never ran, so a 1000 ms interval produced no flips. Two dead knobs, one omission.
100
+ //
101
+ // flipSync DEFAULTS TRUE, so it cannot use `!!p.flipSync` — that would read a missing
102
+ // value as "independent" and hand every deck twelve control strips. Absent means
103
+ // synced; only an explicit false switches it.
104
+ flipSync: p2.flipSync === void 0 || p2.flipSync === null ? true : !!p2.flipSync,
105
+ // 0 is MEANINGFUL here (manual only) and is the default, so numberOr — not
106
+ // `|| DEFAULT` — for the same reason animLoopDelaySec uses it. Clamping stays
107
+ // chart-side: the archetype already clamps 500..120000 and two clamps in two
108
+ // repositories is how they end up disagreeing.
109
+ flipIntervalMs: Math.max(0, numberOr(p2.flipIntervalMs, 0))
92
110
  };
93
111
  }
94
112
 
package/dist/index.mjs CHANGED
@@ -41,7 +41,7 @@ import {
41
41
  requiredD3Plugins,
42
42
  resolveOptions,
43
43
  stripEsmExports
44
- } from "./chunk-P2NWAYI7.mjs";
44
+ } from "./chunk-TBRWWGJW.mjs";
45
45
  import "./chunk-A2GMXZP7.mjs";
46
46
 
47
47
  // src/trivial.ts
package/dist/react.mjs CHANGED
@@ -4,7 +4,7 @@ import {
4
4
  createChartHost,
5
5
  geoFromCache,
6
6
  loadGeo
7
- } from "./chunk-P2NWAYI7.mjs";
7
+ } from "./chunk-TBRWWGJW.mjs";
8
8
  import "./chunk-A2GMXZP7.mjs";
9
9
 
10
10
  // src/react.tsx
@@ -77,5 +77,7 @@ export interface RenderOptions {
77
77
  animStopAtEnd?: boolean;
78
78
  filtersDuringPlay?: boolean;
79
79
  animTimelineStyle?: TimelineStyle;
80
+ flipSync?: boolean;
81
+ flipIntervalMs?: number;
80
82
  onSelect?: (rowIdxs: number[]) => void;
81
83
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bicharts/chart-host",
3
- "version": "0.5.19",
3
+ "version": "0.5.20",
4
4
  "description": "Run a BIC-generated D3 chart in any web host: compiles the generated render() function, applies the shared option defaults, resolves mark clicks (through tooltip overlays), owns the selection affordance, and translates row indices between cross-filtered charts. The same contract the BIC Power BI visual implements, minus Power BI. React bindings at @bicharts/chart-host/react.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",