@opendata-ai/openchart-engine 6.20.0 → 6.22.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.
- package/dist/index.d.ts +6 -0
- package/dist/index.js +756 -3592
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/src/__tests__/__snapshots__/compile-snapshot.test.ts.snap +1989 -0
- package/src/__tests__/axes.test.ts +65 -0
- package/src/__tests__/compile-snapshot.test.ts +156 -0
- package/src/charts/__tests__/registry.test.ts +6 -0
- package/src/charts/_shared/__tests__/density-filter.test.ts +32 -0
- package/src/charts/_shared/density-filter.ts +26 -0
- package/src/charts/bar/labels.ts +2 -6
- package/src/charts/builtin.ts +64 -0
- package/src/charts/column/labels.ts +2 -6
- package/src/charts/dot/labels.ts +2 -6
- package/src/charts/pie/labels.ts +4 -6
- package/src/charts/registry.ts +6 -0
- package/src/compile/__tests__/color-scale-range.test.ts +79 -0
- package/src/compile/__tests__/data-clip.test.ts +59 -0
- package/src/compile/__tests__/watermark-obstacle.test.ts +93 -0
- package/src/compile/color-scale-range.ts +38 -0
- package/src/compile/data-clip.ts +33 -0
- package/src/compile/watermark-obstacle.ts +54 -0
- package/src/compile.ts +20 -97
- package/src/layout/axes/thinning.ts +96 -0
- package/src/layout/axes/ticks.ts +266 -0
- package/src/layout/axes.ts +148 -249
package/dist/index.d.ts
CHANGED
|
@@ -428,6 +428,12 @@ declare function registerChartRenderer(type: string, renderer: ChartRenderer): v
|
|
|
428
428
|
declare function getChartRenderer(type: string): ChartRenderer | undefined;
|
|
429
429
|
/**
|
|
430
430
|
* Clear all registered renderers. Useful for testing.
|
|
431
|
+
*
|
|
432
|
+
* Note: the built-in renderers (line, bar, column, ...) register as a
|
|
433
|
+
* side-effect of importing `./builtin`. Once cleared, they do not come
|
|
434
|
+
* back on their own — subsequent `compileChart(...)` calls will return
|
|
435
|
+
* empty marks. Tests that call `clearRenderers()` should follow up with
|
|
436
|
+
* `registerBuiltinRenderers()` from `./builtin` to restore the defaults.
|
|
431
437
|
*/
|
|
432
438
|
declare function clearRenderers(): void;
|
|
433
439
|
|