@zuilib/charts 0.3.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.
Files changed (41) hide show
  1. package/README.md +140 -0
  2. package/dist/authoring.d.ts +47 -0
  3. package/dist/authoring.js +11 -0
  4. package/dist/chart-defaults.d.ts +60 -0
  5. package/dist/chart-defaults.js +24 -0
  6. package/dist/chart-frame-B9fxUxGG.d.ts +90 -0
  7. package/dist/chart-frame.d.ts +4 -0
  8. package/dist/chart-frame.js +14 -0
  9. package/dist/chart-legend.d.ts +25 -0
  10. package/dist/chart-legend.js +13 -0
  11. package/dist/chart-spec-CH0tAkLG.d.ts +226 -0
  12. package/dist/chart-tooltip.d.ts +44 -0
  13. package/dist/chart-tooltip.js +11 -0
  14. package/dist/chart.d.ts +78 -0
  15. package/dist/chart.js +24 -0
  16. package/dist/chunk-3VGLTPGL.js +19 -0
  17. package/dist/chunk-6QTIAMA3.js +169 -0
  18. package/dist/chunk-7WABBHMT.js +88 -0
  19. package/dist/chunk-7WJ26NHR.js +48 -0
  20. package/dist/chunk-BFTWWI46.js +148 -0
  21. package/dist/chunk-D7K23UFP.js +43 -0
  22. package/dist/chunk-G4FXJJ66.js +169 -0
  23. package/dist/chunk-HNJKYOPE.js +45 -0
  24. package/dist/chunk-IPOBQIYU.js +13 -0
  25. package/dist/chunk-MJDIQVJX.js +148 -0
  26. package/dist/chunk-PV27RZSV.js +61 -0
  27. package/dist/chunk-SHQZRND7.js +83 -0
  28. package/dist/chunk-UN3XPBZ5.js +17 -0
  29. package/dist/chunk-WVWGHGZE.js +90 -0
  30. package/dist/chunk-YMPZODMC.js +1084 -0
  31. package/dist/cross-filter.d.ts +62 -0
  32. package/dist/cross-filter.js +13 -0
  33. package/dist/format.d.ts +17 -0
  34. package/dist/format.js +7 -0
  35. package/dist/index.d.ts +13 -0
  36. package/dist/index.js +93 -0
  37. package/dist/interop.d.ts +46 -0
  38. package/dist/interop.js +12 -0
  39. package/dist/registry.d.ts +111 -0
  40. package/dist/registry.js +25 -0
  41. package/package.json +98 -0
@@ -0,0 +1,62 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { ReactNode } from 'react';
3
+
4
+ /** One cross-filtered dimension: a row field and the values kept. JSON-safe. */
5
+ interface CrossFilterEntry {
6
+ /** The field the values belong to (a row key; doubles as a data-grid column id). */
7
+ field: string;
8
+ /** The values kept. A mark click toggles its value here. */
9
+ values: (string | number)[];
10
+ }
11
+ /**
12
+ * Transient emphasis (hover, or a grid-selection echo): marks whose `field`
13
+ * value is in `values` render full-strength, the rest dim.
14
+ */
15
+ interface CrossFilterHighlight {
16
+ field: string;
17
+ values: (string | number)[];
18
+ }
19
+ interface CrossFilterState {
20
+ filters: CrossFilterEntry[];
21
+ highlight: CrossFilterHighlight | null;
22
+ }
23
+ declare const defaultCrossFilterState: CrossFilterState;
24
+ interface UseCrossFilterResult {
25
+ state: CrossFilterState;
26
+ /** True when any entry has values. */
27
+ filtered: boolean;
28
+ /**
29
+ * Toggles one value. `additive` (shift-click) keeps the field's other
30
+ * values; otherwise the value replaces them, and clicking the field's
31
+ * lone kept value clears the field.
32
+ */
33
+ toggleValue: (field: string, value: string | number, options?: {
34
+ additive?: boolean;
35
+ }) => void;
36
+ /** Removes the field's entry. */
37
+ clearField: (field: string) => void;
38
+ /** Removes every filter and the highlight. */
39
+ clearAll: () => void;
40
+ setHighlight: (highlight: CrossFilterHighlight | null) => void;
41
+ /** The kept values for a field, or null when the field is unfiltered. */
42
+ valuesFor: (field: string) => (string | number)[] | null;
43
+ }
44
+ interface CrossFilterProviderProps {
45
+ /**
46
+ * Controlled state. Left out, the provider keeps its own (from
47
+ * `defaultState`) and still reports through `onStateChange`.
48
+ */
49
+ state?: CrossFilterState;
50
+ /** Initial state when uncontrolled. @default no filters, no highlight */
51
+ defaultState?: CrossFilterState;
52
+ /** Receives the whole next state on every interaction. */
53
+ onStateChange?: (state: CrossFilterState) => void;
54
+ children: ReactNode;
55
+ }
56
+ declare function CrossFilterProvider({ state, defaultState, onStateChange, children }: CrossFilterProviderProps): react_jsx_runtime.JSX.Element;
57
+ /** The cross-filter state and actions. Throws outside a `CrossFilterProvider`. */
58
+ declare function useCrossFilter(): UseCrossFilterResult;
59
+ /** Like `useCrossFilter`, but null outside a provider — what chart internals use. */
60
+ declare function useOptionalCrossFilter(): UseCrossFilterResult | null;
61
+
62
+ export { type CrossFilterEntry, type CrossFilterHighlight, type CrossFilterProviderProps, type CrossFilterState, type UseCrossFilterResult, CrossFilterProvider as default, defaultCrossFilterState, useCrossFilter, useOptionalCrossFilter };
@@ -0,0 +1,13 @@
1
+ "use client";
2
+ import {
3
+ cross_filter_default,
4
+ defaultCrossFilterState,
5
+ useCrossFilter,
6
+ useOptionalCrossFilter
7
+ } from "./chunk-WVWGHGZE.js";
8
+ export {
9
+ cross_filter_default as default,
10
+ defaultCrossFilterState,
11
+ useCrossFilter,
12
+ useOptionalCrossFilter
13
+ };
@@ -0,0 +1,17 @@
1
+ import { F as FormatToken } from './chart-spec-CH0tAkLG.js';
2
+
3
+ /** Formats one value for an axis tick, tooltip row, or direct label. */
4
+ type FormatterFn = (value: unknown) => string;
5
+ /** Builds a formatter from the part after `:` — `'currency:EUR'` calls `factory('EUR', locale)`. */
6
+ type FormatterFactory = (arg: string, locale?: string) => FormatterFn;
7
+ interface Formatters {
8
+ /** The formatter for `token`, falling back to `fallback`, then to `String`. */
9
+ resolve(token: FormatToken | undefined, fallback?: FormatToken): FormatterFn;
10
+ }
11
+ /**
12
+ * Builds the formatters `<Chart>` and the tooltip/legend contents resolve
13
+ * tokens through. Formatters are built once per token and cached.
14
+ */
15
+ declare function createFormatters(locale?: string, custom?: Record<string, FormatterFn | FormatterFactory>): Formatters;
16
+
17
+ export { type FormatterFactory, type FormatterFn, type Formatters, createFormatters };
package/dist/format.js ADDED
@@ -0,0 +1,7 @@
1
+ import {
2
+ createFormatters
3
+ } from "./chunk-7WABBHMT.js";
4
+ import "./chunk-3VGLTPGL.js";
5
+ export {
6
+ createFormatters
7
+ };
@@ -0,0 +1,13 @@
1
+ export { Chart, ChartProps, CustomChartProps, configFromSpec, crossFilterFieldOf, Chart as default } from './chart.js';
2
+ export { AnyChartSpec, ChartRegistry, ChartTypeDef, CustomChartSpec, chartSpecJsonSchema, chartTypeSchema, createChartRegistry, defaultChartRegistry, defaultChartTypes, defineChartType } from './registry.js';
3
+ export { C as ChartConfig, a as ChartFrame, b as ChartFrameProps, c as ChartLabels, d as ChartSeriesConfig, e as defaultChartLabels, f as fillLabel } from './chart-frame-B9fxUxGG.js';
4
+ export { ChartTooltipPanel, ChartTooltipPanelProps } from './chart-tooltip.js';
5
+ export { ChartLegendList, ChartLegendListProps } from './chart-legend.js';
6
+ export { CHART_COLOR_COUNT, DIMMED_OPACITY, cartesianGridDefaults, chartColorVar, seriesColorProperty, seriesColorVar, tooltipCrosshairDefaults, tooltipCursorDefaults, xAxisDefaults, yAxisDefaults } from './chart-defaults.js';
7
+ export { CrossFilterEntry, CrossFilterHighlight, default as CrossFilterProvider, CrossFilterProviderProps, CrossFilterState, UseCrossFilterResult, defaultCrossFilterState, useCrossFilter, useOptionalCrossFilter } from './cross-filter.js';
8
+ export { ColumnFilter, applyFilters, fromColumnFilters, toColumnFilters, toHighlight } from './interop.js';
9
+ export { FormatterFactory, FormatterFn, Formatters, createFormatters } from './format.js';
10
+ export { A as AreaChartSpec, a as AxisSpec, B as BarChartSpec, C as CartesianFrameSpec, b as CartesianSpecCommon, c as ChartMarkEvent, d as ChartRow, e as ChartSpec, f as ChartSpecCommon, g as ComposedChartSpec, F as FormatToken, h as FunnelChartSpec, L as LineChartSpec, P as PieChartSpec, R as RadarChartSpec, i as RadialBarChartSpec, j as ReferenceLineSpec, S as ScatterChartSpec, k as SeriesSpec, T as TreemapChartSpec } from './chart-spec-CH0tAkLG.js';
11
+ import 'react';
12
+ import './authoring.js';
13
+ import 'react/jsx-runtime';
package/dist/index.js ADDED
@@ -0,0 +1,93 @@
1
+ "use client";
2
+ import {
3
+ applyFilters,
4
+ fromColumnFilters,
5
+ toColumnFilters,
6
+ toHighlight
7
+ } from "./chunk-D7K23UFP.js";
8
+ import {
9
+ chart_default,
10
+ configFromSpec,
11
+ crossFilterFieldOf
12
+ } from "./chunk-BFTWWI46.js";
13
+ import {
14
+ chartSpecJsonSchema,
15
+ chartTypeSchema,
16
+ createChartRegistry,
17
+ defaultChartRegistry,
18
+ defaultChartTypes,
19
+ defineChartType
20
+ } from "./chunk-YMPZODMC.js";
21
+ import "./chunk-HNJKYOPE.js";
22
+ import {
23
+ chart_frame_default
24
+ } from "./chunk-G4FXJJ66.js";
25
+ import {
26
+ createFormatters
27
+ } from "./chunk-7WABBHMT.js";
28
+ import "./chunk-3VGLTPGL.js";
29
+ import {
30
+ ChartTooltipPanel
31
+ } from "./chunk-PV27RZSV.js";
32
+ import {
33
+ ChartLegendList
34
+ } from "./chunk-SHQZRND7.js";
35
+ import {
36
+ cross_filter_default,
37
+ defaultCrossFilterState,
38
+ useCrossFilter,
39
+ useOptionalCrossFilter
40
+ } from "./chunk-WVWGHGZE.js";
41
+ import {
42
+ defaultChartLabels,
43
+ fillLabel
44
+ } from "./chunk-UN3XPBZ5.js";
45
+ import "./chunk-IPOBQIYU.js";
46
+ import {
47
+ CHART_COLOR_COUNT,
48
+ DIMMED_OPACITY,
49
+ cartesianGridDefaults,
50
+ chartColorVar,
51
+ seriesColorProperty,
52
+ seriesColorVar,
53
+ tooltipCrosshairDefaults,
54
+ tooltipCursorDefaults,
55
+ xAxisDefaults,
56
+ yAxisDefaults
57
+ } from "./chunk-7WJ26NHR.js";
58
+ export {
59
+ CHART_COLOR_COUNT,
60
+ chart_default as Chart,
61
+ chart_frame_default as ChartFrame,
62
+ ChartLegendList,
63
+ ChartTooltipPanel,
64
+ cross_filter_default as CrossFilterProvider,
65
+ DIMMED_OPACITY,
66
+ applyFilters,
67
+ cartesianGridDefaults,
68
+ chartColorVar,
69
+ chartSpecJsonSchema,
70
+ chartTypeSchema,
71
+ configFromSpec,
72
+ createChartRegistry,
73
+ createFormatters,
74
+ crossFilterFieldOf,
75
+ chart_default as default,
76
+ defaultChartLabels,
77
+ defaultChartRegistry,
78
+ defaultChartTypes,
79
+ defaultCrossFilterState,
80
+ defineChartType,
81
+ fillLabel,
82
+ fromColumnFilters,
83
+ seriesColorProperty,
84
+ seriesColorVar,
85
+ toColumnFilters,
86
+ toHighlight,
87
+ tooltipCrosshairDefaults,
88
+ tooltipCursorDefaults,
89
+ useCrossFilter,
90
+ useOptionalCrossFilter,
91
+ xAxisDefaults,
92
+ yAxisDefaults
93
+ };
@@ -0,0 +1,46 @@
1
+ import { CrossFilterState, CrossFilterEntry, CrossFilterHighlight } from './cross-filter.js';
2
+ import 'react/jsx-runtime';
3
+ import 'react';
4
+
5
+ /**
6
+ * Pure converters between the cross-filter state and the shapes a data
7
+ * table speaks — structurally compatible with `@zuilib/data-grid`
8
+ * (`DataGridState.columnFilters`, selected rows) without importing it, so
9
+ * charts stay standalone. Follows the data-grid `server-adapter` rule:
10
+ * untrusted input never throws.
11
+ */
12
+
13
+ /** A column filter as data-grid / TanStack Table shape it: `{ id, value }`. */
14
+ interface ColumnFilter {
15
+ id: string;
16
+ value: unknown;
17
+ }
18
+ /**
19
+ * The cross-filter entries as data-grid select-filter `columnFilters`
20
+ * (`value` is the kept values array). Empty entries are dropped.
21
+ */
22
+ declare function toColumnFilters(state: CrossFilterState): {
23
+ id: string;
24
+ value: (string | number)[];
25
+ }[];
26
+ /**
27
+ * The inverse: the entries for `fields` found in a grid's `columnFilters`.
28
+ * Non-array and non-scalar values are ignored, never thrown on.
29
+ */
30
+ declare function fromColumnFilters(columnFilters: readonly ColumnFilter[], fields: readonly string[]): CrossFilterEntry[];
31
+ /**
32
+ * Grid-selected rows folded into a highlight on `field` (deduplicated;
33
+ * null/undefined values dropped). Null when nothing usable is selected.
34
+ */
35
+ declare function toHighlight<T extends Record<string, unknown>>(rows: readonly T[], field: string): CrossFilterHighlight | null;
36
+ /**
37
+ * The rows that pass every filter entry — a client-side convenience for
38
+ * feeding a second chart or a summary tile. `except` skips one field's
39
+ * entry: the standard cross-filter rule that a chart ignores its own
40
+ * field's filter so its clicked mark stays visible.
41
+ */
42
+ declare function applyFilters<T extends Record<string, unknown>>(rows: readonly T[], state: CrossFilterState, options?: {
43
+ except?: string;
44
+ }): T[];
45
+
46
+ export { type ColumnFilter, applyFilters, fromColumnFilters, toColumnFilters, toHighlight };
@@ -0,0 +1,12 @@
1
+ import {
2
+ applyFilters,
3
+ fromColumnFilters,
4
+ toColumnFilters,
5
+ toHighlight
6
+ } from "./chunk-D7K23UFP.js";
7
+ export {
8
+ applyFilters,
9
+ fromColumnFilters,
10
+ toColumnFilters,
11
+ toHighlight
12
+ };
@@ -0,0 +1,111 @@
1
+ import { ComponentType } from 'react';
2
+ import { C as ChartConfig } from './chart-frame-B9fxUxGG.js';
3
+ import { RendererProps } from './authoring.js';
4
+ import { e as ChartSpec, f as ChartSpecCommon } from './chart-spec-CH0tAkLG.js';
5
+ import './format.js';
6
+ import './cross-filter.js';
7
+ import 'react/jsx-runtime';
8
+
9
+ /**
10
+ * The open chart-type registry. Every chart type — built-in or
11
+ * app-registered — is one `ChartTypeDef` binding a spec `type` string to
12
+ * its renderer, its cross-filter behavior, and a complete JSON Schema of
13
+ * its spec variant. `<Chart>` dispatches through a registry (the built-in
14
+ * one by default), so an app adds a chart type by listing a def after
15
+ * `defaultChartTypes` — no package edits, and no second dispatch table to
16
+ * keep in step. The same defs are the single source of the ChartSpec JSON
17
+ * Schema (`chartSpecJsonSchema`), so validation and structured generation
18
+ * can never drift from what actually renders.
19
+ */
20
+
21
+ /**
22
+ * A spec handled by an app-registered chart type: the shared options plus
23
+ * whatever fields that type's schema declares. Built-in specs stay the
24
+ * closed `ChartSpec` union — `<Chart>` only accepts this escape hatch
25
+ * together with an explicit `registry`, so a typo in a built-in spec is
26
+ * still a type error.
27
+ */
28
+ interface CustomChartSpec extends ChartSpecCommon {
29
+ type: string;
30
+ [field: string]: unknown;
31
+ }
32
+ /** Any spec a registry can dispatch: a built-in variant or a custom one. */
33
+ type AnyChartSpec = ChartSpec | CustomChartSpec;
34
+ /** One registry entry: a spec `type` bound to a renderer and its contract. */
35
+ interface ChartTypeDef<S extends AnyChartSpec = AnyChartSpec> {
36
+ /** The `type` string specs use. Lower-kebab-case by convention. */
37
+ type: string;
38
+ /**
39
+ * Which field family the spec uses — `'cartesian'` (`xKey` + `series`),
40
+ * `'radar'`, `'scatter'` (`xKey`/`yKey`), `'named'` (`nameKey` +
41
+ * `valueKey`) or `'treemap'` (`nameKey` + `sizeKey`) — so spec-editing
42
+ * UIs can offer the right field pickers without a per-type table of
43
+ * their own. A custom def names the closest family (or its own).
44
+ */
45
+ family?: string;
46
+ /** The component drawn inside `<ChartFrame>` for specs of this type. */
47
+ render: ComponentType<RendererProps<S>>;
48
+ /**
49
+ * The field mark clicks cross-filter on. Left out, `<Chart>` falls back
50
+ * to the spec's `xKey` — declare it for any type whose category lives
51
+ * elsewhere.
52
+ */
53
+ crossFilterField?: (spec: S) => string;
54
+ /**
55
+ * The field whose values the legend lists as clickable categories
56
+ * (colored per row, not per series). Left out, the legend lists series.
57
+ */
58
+ categoryField?: (spec: S) => string | undefined;
59
+ /**
60
+ * The series config (labels, colors, formats) the spec implies. Left
61
+ * out, `<Chart>` derives it from the spec's `series` array — declare it
62
+ * for types whose values live under other fields.
63
+ */
64
+ configFrom?: (spec: S) => ChartConfig;
65
+ /**
66
+ * JSON Schema (draft 2020-12 vocabulary) of this variant's spec —
67
+ * complete, including the shared options, so `chartSpecJsonSchema` can
68
+ * assemble a validating whole from the parts.
69
+ */
70
+ schema: Record<string, unknown>;
71
+ }
72
+ /** A resolved set of chart-type definitions keyed by `type`. */
73
+ interface ChartRegistry {
74
+ types: ReadonlyMap<string, ChartTypeDef>;
75
+ }
76
+ /**
77
+ * Identity helper that checks a definition against its concrete spec type
78
+ * (so `spec` is fully typed inside `render` and the field callbacks), then
79
+ * erases it to the registry-level shape a heterogeneous map can hold.
80
+ */
81
+ declare function defineChartType<S extends AnyChartSpec>(def: ChartTypeDef<S>): ChartTypeDef;
82
+ /**
83
+ * Merges definition lists (and/or existing registries) into one registry.
84
+ * Later sources win on `type` collisions, so apps can override a built-in
85
+ * entry by listing their own definition after `defaultChartTypes`.
86
+ */
87
+ declare function createChartRegistry(...sources: Array<ChartTypeDef[] | ChartRegistry>): ChartRegistry;
88
+ /**
89
+ * A closed object schema for one spec variant: the shared options, the
90
+ * `type` discriminant, and the variant's own fields. `additionalProperties:
91
+ * false` is what makes cross-family mistakes (an `xKey` on a pie) fail
92
+ * validation instead of passing silently.
93
+ */
94
+ declare function chartTypeSchema(type: string, properties: Record<string, unknown>, required: readonly string[]): Record<string, unknown>;
95
+ /**
96
+ * The built-in chart types, one def per `type` string, in the order
97
+ * pickers should offer them. Spread them into `createChartRegistry` ahead
98
+ * of app defs to extend or override the set.
99
+ */
100
+ declare const defaultChartTypes: ChartTypeDef[];
101
+ /** The registry `<Chart>` uses when none is passed: the built-ins only. */
102
+ declare const defaultChartRegistry: ChartRegistry;
103
+ /**
104
+ * The full ChartSpec JSON Schema (draft 2020-12) of a registry: `type` is
105
+ * an enum of the registered types, and per-type `if`/`then` conditionals
106
+ * apply each def's complete variant schema — so a field from the wrong
107
+ * family fails validation instead of flattening into one all-optional bag.
108
+ */
109
+ declare function chartSpecJsonSchema(registry?: ChartRegistry): Record<string, unknown>;
110
+
111
+ export { type AnyChartSpec, type ChartRegistry, type ChartTypeDef, type CustomChartSpec, chartSpecJsonSchema, chartTypeSchema, createChartRegistry, defaultChartRegistry, defaultChartTypes, defineChartType };
@@ -0,0 +1,25 @@
1
+ "use client";
2
+ import {
3
+ chartSpecJsonSchema,
4
+ chartTypeSchema,
5
+ createChartRegistry,
6
+ defaultChartRegistry,
7
+ defaultChartTypes,
8
+ defineChartType
9
+ } from "./chunk-YMPZODMC.js";
10
+ import "./chunk-HNJKYOPE.js";
11
+ import "./chunk-3VGLTPGL.js";
12
+ import "./chunk-PV27RZSV.js";
13
+ import "./chunk-SHQZRND7.js";
14
+ import "./chunk-WVWGHGZE.js";
15
+ import "./chunk-UN3XPBZ5.js";
16
+ import "./chunk-IPOBQIYU.js";
17
+ import "./chunk-7WJ26NHR.js";
18
+ export {
19
+ chartSpecJsonSchema,
20
+ chartTypeSchema,
21
+ createChartRegistry,
22
+ defaultChartRegistry,
23
+ defaultChartTypes,
24
+ defineChartType
25
+ };
package/package.json ADDED
@@ -0,0 +1,98 @@
1
+ {
2
+ "name": "@zuilib/charts",
3
+ "version": "0.3.0",
4
+ "description": "ZUI — enterprise analytics charts on Recharts: a serializable chart spec, styled primitives, and cross-filtering that links charts to data tables",
5
+ "type": "module",
6
+ "sideEffects": false,
7
+ "files": [
8
+ "dist"
9
+ ],
10
+ "exports": {
11
+ ".": {
12
+ "types": "./dist/index.d.ts",
13
+ "import": "./dist/index.js"
14
+ },
15
+ "./chart": {
16
+ "types": "./dist/chart.d.ts",
17
+ "import": "./dist/chart.js"
18
+ },
19
+ "./registry": {
20
+ "types": "./dist/registry.d.ts",
21
+ "import": "./dist/registry.js"
22
+ },
23
+ "./chart-frame": {
24
+ "types": "./dist/chart-frame.d.ts",
25
+ "import": "./dist/chart-frame.js"
26
+ },
27
+ "./authoring": {
28
+ "types": "./dist/authoring.d.ts",
29
+ "import": "./dist/authoring.js"
30
+ },
31
+ "./chart-tooltip": {
32
+ "types": "./dist/chart-tooltip.d.ts",
33
+ "import": "./dist/chart-tooltip.js"
34
+ },
35
+ "./chart-legend": {
36
+ "types": "./dist/chart-legend.d.ts",
37
+ "import": "./dist/chart-legend.js"
38
+ },
39
+ "./chart-defaults": {
40
+ "types": "./dist/chart-defaults.d.ts",
41
+ "import": "./dist/chart-defaults.js"
42
+ },
43
+ "./cross-filter": {
44
+ "types": "./dist/cross-filter.d.ts",
45
+ "import": "./dist/cross-filter.js"
46
+ },
47
+ "./interop": {
48
+ "types": "./dist/interop.d.ts",
49
+ "import": "./dist/interop.js"
50
+ },
51
+ "./format": {
52
+ "types": "./dist/format.d.ts",
53
+ "import": "./dist/format.js"
54
+ },
55
+ "./package.json": "./package.json"
56
+ },
57
+ "peerDependencies": {
58
+ "react": "^18.0.0 || ^19.0.0",
59
+ "react-dom": "^18.0.0 || ^19.0.0",
60
+ "recharts": "^3.0.0",
61
+ "@zuilib/tokens": "^0.2.0"
62
+ },
63
+ "dependencies": {
64
+ "@zuilib/components": "^0.2.0"
65
+ },
66
+ "devDependencies": {
67
+ "@testing-library/dom": "^10.4.1",
68
+ "@testing-library/jest-dom": "^7.0.1",
69
+ "@testing-library/react": "^16.3.3",
70
+ "@testing-library/user-event": "^14.6.6",
71
+ "@types/react": "^18.0.0",
72
+ "@types/react-dom": "^18.0.0",
73
+ "ajv": "^8.17.1",
74
+ "axe-core": "^4.13.0",
75
+ "jsdom": "^30.0.1",
76
+ "react": "^18.2.0",
77
+ "react-dom": "^18.2.0",
78
+ "recharts": "^3.0.0",
79
+ "typescript": "^6.0.2",
80
+ "vitest": "^4.1.11",
81
+ "@zuilib/tokens": "^0.2.0"
82
+ },
83
+ "keywords": [
84
+ "charts",
85
+ "recharts",
86
+ "analytics",
87
+ "dataviz",
88
+ "cross-filter",
89
+ "design-system",
90
+ "react",
91
+ "typescript"
92
+ ],
93
+ "scripts": {
94
+ "build": "tsup",
95
+ "typecheck": "tsc --noEmit -p tsconfig.json",
96
+ "test": "node scripts/check-logical.mjs && vitest run"
97
+ }
98
+ }