open-mcp-app-ui 0.0.6 → 0.0.8

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.
@@ -2,6 +2,90 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import { CSSProperties, ReactNode } from 'react';
3
3
  export { Area, Bar, CartesianGrid, Cell, Legend, Line, Pie, PolarAngleAxis, PolarGrid, PolarRadiusAxis, Radar, Tooltip as RechartsTooltip, ReferenceArea, ReferenceLine, ResponsiveContainer, Scatter, XAxis, YAxis } from 'recharts';
4
4
 
5
+ /**
6
+ * Chart Theme — CSS variable mapping for Recharts.
7
+ *
8
+ * Reads MCP Apps spec CSS variables at render time and provides
9
+ * them as style objects for Recharts sub-components (tooltip, grid,
10
+ * axis labels, legend). This is how charts automatically adapt to
11
+ * the host's theme without configuration.
12
+ */
13
+ /**
14
+ * Resolve a CSS variable value at runtime.
15
+ * Falls back to the provided default if the variable is not set.
16
+ *
17
+ * Recharts requires resolved color values for SVG attributes (stroke, fill)
18
+ * because SVG doesn't support var() in most attributes. We check both
19
+ * document.documentElement (inline styles set by the host SDK) and
20
+ * document.body as a fallback, since hosts may inject CSS variables
21
+ * on either element.
22
+ */
23
+ declare const getCSSVar: ({ name, fallback }: {
24
+ name: string;
25
+ fallback: string;
26
+ }) => string;
27
+ /**
28
+ * Themed tooltip style object for Recharts <Tooltip>.
29
+ * Applied via contentStyle, labelStyle, and wrapperStyle props.
30
+ */
31
+ declare const getTooltipStyle: () => {
32
+ contentStyle: {
33
+ backgroundColor: string;
34
+ border: string;
35
+ borderRadius: string;
36
+ color: string;
37
+ fontSize: string;
38
+ fontFamily: string;
39
+ padding: string;
40
+ boxShadow: string;
41
+ };
42
+ labelStyle: {
43
+ color: string;
44
+ fontWeight: number;
45
+ marginBottom: string;
46
+ };
47
+ };
48
+ /**
49
+ * Border variant type shared across chart sub-components.
50
+ * - "default" uses --color-border-primary (stronger)
51
+ * - "secondary" uses --color-border-secondary (subtler)
52
+ */
53
+ type ChartBorderVariant = "default" | "secondary";
54
+ /**
55
+ * Themed grid line color for <CartesianGrid>.
56
+ * Grids default to secondary (subtle background lines).
57
+ */
58
+ declare const getGridColor: ({ variant }?: {
59
+ variant?: ChartBorderVariant;
60
+ }) => string;
61
+ /**
62
+ * Themed axis tick/label style for <XAxis> and <YAxis>.
63
+ * Axis lines default to primary (visible structural lines).
64
+ */
65
+ declare const getAxisStyle: ({ variant }?: {
66
+ variant?: ChartBorderVariant;
67
+ }) => {
68
+ tick: {
69
+ fill: string;
70
+ fontSize: string;
71
+ fontFamily: string;
72
+ };
73
+ axisLine: {
74
+ stroke: string;
75
+ };
76
+ tickLine: {
77
+ stroke: string;
78
+ };
79
+ };
80
+ /**
81
+ * Themed legend style for <Legend>.
82
+ */
83
+ declare const getLegendStyle: () => {
84
+ color: string;
85
+ fontSize: string;
86
+ fontFamily: string;
87
+ };
88
+
5
89
  /**
6
90
  * Shared chart types.
7
91
  * Defines the theme interface and common props used across all chart wrappers.
@@ -35,36 +119,56 @@ interface ThemedLineChartProps extends ChartContainerProps {
35
119
  children: ReactNode;
36
120
  /** Show background grid lines. */
37
121
  grid?: boolean;
122
+ /**
123
+ * Border variant for axis lines and tick marks.
124
+ * - "default" — uses --color-border-primary (stronger)
125
+ * - "secondary" — uses --color-border-secondary (subtler)
126
+ */
127
+ borderVariant?: ChartBorderVariant;
38
128
  }
39
129
  /**
40
130
  * Themed LineChart.
41
- * Automatically assigns palette colors to Line children that
42
- * don't have an explicit stroke prop.
131
+ * Automatically assigns palette colors to Line children and
132
+ * applies themed axis styles to XAxis/YAxis children.
43
133
  */
44
- declare const LineChart: ({ data, height, colorPalette, className, style, grid, children, }: ThemedLineChartProps) => react_jsx_runtime.JSX.Element;
134
+ declare const LineChart: ({ data, height, colorPalette, className, style, grid, borderVariant, children, }: ThemedLineChartProps) => react_jsx_runtime.JSX.Element;
45
135
 
46
136
  interface ThemedBarChartProps extends ChartContainerProps {
47
137
  /** Chart data array. */
48
138
  data: Record<string, unknown>[];
49
139
  children: ReactNode;
50
140
  grid?: boolean;
141
+ /**
142
+ * Border variant for axis lines and tick marks.
143
+ * - "default" — uses --color-border-primary (stronger)
144
+ * - "secondary" — uses --color-border-secondary (subtler)
145
+ */
146
+ borderVariant?: ChartBorderVariant;
51
147
  }
52
148
  /**
53
149
  * Themed BarChart.
54
- * Automatically assigns palette colors to Bar children.
150
+ * Automatically assigns palette colors to Bar children and
151
+ * applies themed axis styles to XAxis/YAxis children.
55
152
  */
56
- declare const BarChart: ({ data, height, colorPalette, className, style, grid, children, }: ThemedBarChartProps) => react_jsx_runtime.JSX.Element;
153
+ declare const BarChart: ({ data, height, colorPalette, className, style, grid, borderVariant, children, }: ThemedBarChartProps) => react_jsx_runtime.JSX.Element;
57
154
 
58
155
  interface ThemedAreaChartProps extends ChartContainerProps {
59
156
  data: Record<string, unknown>[];
60
157
  children: ReactNode;
61
158
  grid?: boolean;
159
+ /**
160
+ * Border variant for axis lines and tick marks.
161
+ * - "default" — uses --color-border-primary (stronger)
162
+ * - "secondary" — uses --color-border-secondary (subtler)
163
+ */
164
+ borderVariant?: ChartBorderVariant;
62
165
  }
63
166
  /**
64
167
  * Themed AreaChart.
65
- * Auto-assigns palette colors with gradient fill to Area children.
168
+ * Auto-assigns palette colors with gradient fill to Area children and
169
+ * applies themed axis styles to XAxis/YAxis children.
66
170
  */
67
- declare const AreaChart: ({ data, height, colorPalette, className, style, grid, children, }: ThemedAreaChartProps) => react_jsx_runtime.JSX.Element;
171
+ declare const AreaChart: ({ data, height, colorPalette, className, style, grid, borderVariant, children, }: ThemedAreaChartProps) => react_jsx_runtime.JSX.Element;
68
172
 
69
173
  interface ThemedPieChartProps extends Omit<ChartContainerProps, "height"> {
70
174
  /** Chart height (also used for approximate width in responsive container). */
@@ -81,12 +185,19 @@ declare const PieChart: ({ height, colorPalette, className, style, children, }:
81
185
  interface ThemedScatterChartProps extends ChartContainerProps {
82
186
  children: ReactNode;
83
187
  grid?: boolean;
188
+ /**
189
+ * Border variant for axis lines and tick marks.
190
+ * - "default" — uses --color-border-primary (stronger)
191
+ * - "secondary" — uses --color-border-secondary (subtler)
192
+ */
193
+ borderVariant?: ChartBorderVariant;
84
194
  }
85
195
  /**
86
196
  * Themed ScatterChart.
87
- * Auto-assigns palette fill colors to Scatter children.
197
+ * Auto-assigns palette fill colors to Scatter children and
198
+ * applies themed axis styles to XAxis/YAxis children.
88
199
  */
89
- declare const ScatterChart: ({ height, colorPalette, className, style, grid, children, }: ThemedScatterChartProps) => react_jsx_runtime.JSX.Element;
200
+ declare const ScatterChart: ({ height, colorPalette, className, style, grid, borderVariant, children, }: ThemedScatterChartProps) => react_jsx_runtime.JSX.Element;
90
201
 
91
202
  interface ThemedRadarChartProps extends ChartContainerProps {
92
203
  data: Record<string, unknown>[];
@@ -102,12 +213,19 @@ interface ThemedComposedChartProps extends ChartContainerProps {
102
213
  data: Record<string, unknown>[];
103
214
  children: ReactNode;
104
215
  grid?: boolean;
216
+ /**
217
+ * Border variant for axis lines and tick marks.
218
+ * - "default" — uses --color-border-primary (stronger)
219
+ * - "secondary" — uses --color-border-secondary (subtler)
220
+ */
221
+ borderVariant?: ChartBorderVariant;
105
222
  }
106
223
  /**
107
224
  * Themed ComposedChart.
108
- * Auto-assigns palette colors to Line, Bar, and Area children.
225
+ * Auto-assigns palette colors to Line, Bar, and Area children and
226
+ * applies themed axis styles to XAxis/YAxis children.
109
227
  */
110
- declare const ComposedChart: ({ data, height, colorPalette, className, style, grid, children, }: ThemedComposedChartProps) => react_jsx_runtime.JSX.Element;
228
+ declare const ComposedChart: ({ data, height, colorPalette, className, style, grid, borderVariant, children, }: ThemedComposedChartProps) => react_jsx_runtime.JSX.Element;
111
229
 
112
230
  /**
113
231
  * ThemedTooltip — Pre-themed tooltip using MCP Apps spec CSS variables.
@@ -121,4 +239,4 @@ declare const ComposedChart: ({ data, height, colorPalette, className, style, gr
121
239
  */
122
240
  declare const ThemedTooltip: (props: any) => react_jsx_runtime.JSX.Element;
123
241
 
124
- export { AreaChart, BarChart, type ChartContainerProps, ComposedChart, DEFAULT_PALETTE, LineChart, PieChart, RadarChart, ScatterChart, ThemedTooltip as Tooltip };
242
+ export { AreaChart, BarChart, type ChartBorderVariant, type ChartContainerProps, ComposedChart, DEFAULT_PALETTE, LineChart, PieChart, RadarChart, ScatterChart, ThemedTooltip as Tooltip, getAxisStyle, getCSSVar, getGridColor, getLegendStyle, getTooltipStyle };
@@ -3,6 +3,8 @@ import { Children, cloneElement, isValidElement } from "react";
3
3
  import {
4
4
  LineChart as RechartsLineChart,
5
5
  Line as RechartsLine,
6
+ XAxis as RechartsXAxis,
7
+ YAxis as RechartsYAxis,
6
8
  CartesianGrid
7
9
  } from "recharts";
8
10
 
@@ -26,15 +28,19 @@ var ChartContainer = ({
26
28
  height = 300,
27
29
  className = "",
28
30
  style,
31
+ borderVariant = "default",
29
32
  children
30
- }) => /* @__PURE__ */ jsx(
31
- "div",
32
- {
33
- className: `omu-chart w-full ${className}`,
34
- style: { height: `${height}px`, ...style },
35
- children: /* @__PURE__ */ jsx(ResponsiveContainer, { width: "100%", height: "100%", children })
36
- }
37
- );
33
+ }) => {
34
+ const baseClass = borderVariant === "secondary" ? "omu-chart-secondary" : "omu-chart";
35
+ return /* @__PURE__ */ jsx(
36
+ "div",
37
+ {
38
+ className: `${baseClass} w-full ${className}`,
39
+ style: { height: `${height}px`, ...style },
40
+ children: /* @__PURE__ */ jsx(ResponsiveContainer, { width: "100%", height: "100%", children })
41
+ }
42
+ );
43
+ };
38
44
  var getSeriesColor = ({
39
45
  index,
40
46
  palette
@@ -44,9 +50,20 @@ var getSeriesColor = ({
44
50
  };
45
51
 
46
52
  // src/charts/theme.ts
53
+ import React from "react";
47
54
  var getCSSVar = ({ name, fallback }) => {
48
55
  if (typeof window === "undefined") return fallback;
49
- const value = getComputedStyle(document.documentElement).getPropertyValue(name).trim();
56
+ const root = document.documentElement;
57
+ let value = root.style.getPropertyValue(name).trim();
58
+ if (!value) {
59
+ value = getComputedStyle(root).getPropertyValue(name).trim();
60
+ }
61
+ if (!value && document.body) {
62
+ value = document.body.style.getPropertyValue(name).trim();
63
+ if (!value) {
64
+ value = getComputedStyle(document.body).getPropertyValue(name).trim();
65
+ }
66
+ }
50
67
  return value || fallback;
51
68
  };
52
69
  var getTooltipStyle = () => ({
@@ -66,7 +83,53 @@ var getTooltipStyle = () => ({
66
83
  marginBottom: "4px"
67
84
  }
68
85
  });
69
- var getGridColor = () => getCSSVar({ name: "--color-border-secondary", fallback: "#e5e7eb" });
86
+ var getBorderColor = ({ variant = "default" } = {}) => variant === "secondary" ? getCSSVar({ name: "--color-border-secondary", fallback: "#e5e7eb" }) : getCSSVar({ name: "--color-border-primary", fallback: "#d1d5db" });
87
+ var getGridColor = ({ variant = "secondary" } = {}) => getBorderColor({ variant });
88
+ var getAxisStyle = ({ variant = "default" } = {}) => ({
89
+ tick: {
90
+ fill: getCSSVar({ name: "--color-text-secondary", fallback: "#6b7280" }),
91
+ fontSize: getCSSVar({ name: "--font-text-xs-size", fallback: "11px" }),
92
+ fontFamily: getCSSVar({ name: "--font-sans", fallback: "ui-sans-serif, system-ui, sans-serif" })
93
+ },
94
+ axisLine: {
95
+ stroke: getBorderColor({ variant })
96
+ },
97
+ tickLine: {
98
+ stroke: getBorderColor({ variant })
99
+ }
100
+ });
101
+ var themeAxisChild = ({
102
+ child,
103
+ variant = "default",
104
+ XAxis: XAxis2,
105
+ YAxis: YAxis2,
106
+ CartesianGrid: CartesianGrid7
107
+ }) => {
108
+ const t = child.type;
109
+ const dn = t?.displayName;
110
+ if (t === XAxis2 || t === YAxis2 || dn === "XAxis" || dn === "YAxis") {
111
+ const style = getAxisStyle({ variant });
112
+ const props = child.props;
113
+ return React.cloneElement(child, {
114
+ tick: props.tick === false ? false : { ...style.tick, ...typeof props.tick === "object" && props.tick ? props.tick : {} },
115
+ axisLine: props.axisLine === false ? false : { ...style.axisLine, ...typeof props.axisLine === "object" && props.axisLine ? props.axisLine : {} },
116
+ tickLine: props.tickLine === false ? false : { ...style.tickLine, ...typeof props.tickLine === "object" && props.tickLine ? props.tickLine : {} }
117
+ });
118
+ }
119
+ if (CartesianGrid7 && (t === CartesianGrid7 || dn === "CartesianGrid")) {
120
+ const props = child.props;
121
+ return React.cloneElement(child, {
122
+ stroke: props.stroke ?? getGridColor({ variant }),
123
+ opacity: props.opacity ?? 0.5
124
+ });
125
+ }
126
+ return null;
127
+ };
128
+ var getLegendStyle = () => ({
129
+ color: getCSSVar({ name: "--color-text-secondary", fallback: "#6b7280" }),
130
+ fontSize: getCSSVar({ name: "--font-text-sm-size", fallback: "13px" }),
131
+ fontFamily: getCSSVar({ name: "--font-sans", fallback: "ui-sans-serif, system-ui, sans-serif" })
132
+ });
70
133
 
71
134
  // src/charts/LineChart.tsx
72
135
  import { jsx as jsx2, jsxs } from "react/jsx-runtime";
@@ -77,11 +140,14 @@ var LineChart = ({
77
140
  className,
78
141
  style,
79
142
  grid = true,
143
+ borderVariant = "default",
80
144
  children
81
145
  }) => {
82
146
  let seriesIndex = 0;
83
147
  const themedChildren = Children.map(children, (child) => {
84
148
  if (!isValidElement(child)) return child;
149
+ const themedAxis = themeAxisChild({ child, variant: borderVariant, XAxis: RechartsXAxis, YAxis: RechartsYAxis, CartesianGrid });
150
+ if (themedAxis) return themedAxis;
85
151
  if (child.type === RechartsLine || child.type?.displayName === "Line") {
86
152
  const idx = seriesIndex++;
87
153
  const existing = child.props.stroke;
@@ -94,8 +160,8 @@ var LineChart = ({
94
160
  }
95
161
  return child;
96
162
  });
97
- return /* @__PURE__ */ jsx2(ChartContainer, { height, className, style, children: /* @__PURE__ */ jsxs(RechartsLineChart, { data, margin: { top: 5, right: 20, bottom: 5, left: 0 }, children: [
98
- grid && /* @__PURE__ */ jsx2(CartesianGrid, { strokeDasharray: "3 3", stroke: getGridColor(), opacity: 0.5 }),
163
+ return /* @__PURE__ */ jsx2(ChartContainer, { height, className, style, borderVariant, children: /* @__PURE__ */ jsxs(RechartsLineChart, { data, margin: { top: 5, right: 20, bottom: 5, left: 0 }, children: [
164
+ grid && /* @__PURE__ */ jsx2(CartesianGrid, { strokeDasharray: "3 3" }),
99
165
  themedChildren
100
166
  ] }) });
101
167
  };
@@ -105,6 +171,8 @@ import { Children as Children2, cloneElement as cloneElement2, isValidElement as
105
171
  import {
106
172
  BarChart as RechartsBarChart,
107
173
  Bar as RechartsBar,
174
+ XAxis as RechartsXAxis2,
175
+ YAxis as RechartsYAxis2,
108
176
  CartesianGrid as CartesianGrid2
109
177
  } from "recharts";
110
178
  import { jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
@@ -115,11 +183,14 @@ var BarChart = ({
115
183
  className,
116
184
  style,
117
185
  grid = true,
186
+ borderVariant = "default",
118
187
  children
119
188
  }) => {
120
189
  let seriesIndex = 0;
121
190
  const themedChildren = Children2.map(children, (child) => {
122
191
  if (!isValidElement2(child)) return child;
192
+ const themedAxis = themeAxisChild({ child, variant: borderVariant, XAxis: RechartsXAxis2, YAxis: RechartsYAxis2, CartesianGrid: CartesianGrid2 });
193
+ if (themedAxis) return themedAxis;
123
194
  if (child.type === RechartsBar || child.type?.displayName === "Bar") {
124
195
  const idx = seriesIndex++;
125
196
  const existing = child.props.fill;
@@ -130,8 +201,8 @@ var BarChart = ({
130
201
  }
131
202
  return child;
132
203
  });
133
- return /* @__PURE__ */ jsx3(ChartContainer, { height, className, style, children: /* @__PURE__ */ jsxs2(RechartsBarChart, { data, margin: { top: 5, right: 20, bottom: 5, left: 0 }, children: [
134
- grid && /* @__PURE__ */ jsx3(CartesianGrid2, { strokeDasharray: "3 3", stroke: getGridColor(), opacity: 0.5, vertical: false }),
204
+ return /* @__PURE__ */ jsx3(ChartContainer, { height, className, style, borderVariant, children: /* @__PURE__ */ jsxs2(RechartsBarChart, { data, margin: { top: 5, right: 20, bottom: 5, left: 0 }, children: [
205
+ grid && /* @__PURE__ */ jsx3(CartesianGrid2, { strokeDasharray: "3 3", vertical: false }),
135
206
  themedChildren
136
207
  ] }) });
137
208
  };
@@ -141,6 +212,8 @@ import { Children as Children3, cloneElement as cloneElement3, isValidElement as
141
212
  import {
142
213
  AreaChart as RechartsAreaChart,
143
214
  Area as RechartsArea,
215
+ XAxis as RechartsXAxis3,
216
+ YAxis as RechartsYAxis3,
144
217
  CartesianGrid as CartesianGrid3
145
218
  } from "recharts";
146
219
  import { jsx as jsx4, jsxs as jsxs3 } from "react/jsx-runtime";
@@ -151,11 +224,14 @@ var AreaChart = ({
151
224
  className,
152
225
  style,
153
226
  grid = true,
227
+ borderVariant = "default",
154
228
  children
155
229
  }) => {
156
230
  let seriesIndex = 0;
157
231
  const themedChildren = Children3.map(children, (child) => {
158
232
  if (!isValidElement3(child)) return child;
233
+ const themedAxis = themeAxisChild({ child, variant: borderVariant, XAxis: RechartsXAxis3, YAxis: RechartsYAxis3, CartesianGrid: CartesianGrid3 });
234
+ if (themedAxis) return themedAxis;
159
235
  if (child.type === RechartsArea || child.type?.displayName === "Area") {
160
236
  const idx = seriesIndex++;
161
237
  const color = child.props.stroke || getSeriesColor({ index: idx, palette: colorPalette });
@@ -168,8 +244,8 @@ var AreaChart = ({
168
244
  }
169
245
  return child;
170
246
  });
171
- return /* @__PURE__ */ jsx4(ChartContainer, { height, className, style, children: /* @__PURE__ */ jsxs3(RechartsAreaChart, { data, margin: { top: 5, right: 20, bottom: 5, left: 0 }, children: [
172
- grid && /* @__PURE__ */ jsx4(CartesianGrid3, { strokeDasharray: "3 3", stroke: getGridColor(), opacity: 0.5 }),
247
+ return /* @__PURE__ */ jsx4(ChartContainer, { height, className, style, borderVariant, children: /* @__PURE__ */ jsxs3(RechartsAreaChart, { data, margin: { top: 5, right: 20, bottom: 5, left: 0 }, children: [
248
+ grid && /* @__PURE__ */ jsx4(CartesianGrid3, { strokeDasharray: "3 3" }),
173
249
  themedChildren
174
250
  ] }) });
175
251
  };
@@ -213,6 +289,8 @@ import { Children as Children5, cloneElement as cloneElement5, isValidElement as
213
289
  import {
214
290
  ScatterChart as RechartsScatterChart,
215
291
  Scatter as RechartsScatter,
292
+ XAxis as RechartsXAxis4,
293
+ YAxis as RechartsYAxis4,
216
294
  CartesianGrid as CartesianGrid4
217
295
  } from "recharts";
218
296
  import { jsx as jsx6, jsxs as jsxs4 } from "react/jsx-runtime";
@@ -222,11 +300,14 @@ var ScatterChart = ({
222
300
  className,
223
301
  style,
224
302
  grid = true,
303
+ borderVariant = "default",
225
304
  children
226
305
  }) => {
227
306
  let seriesIndex = 0;
228
307
  const themedChildren = Children5.map(children, (child) => {
229
308
  if (!isValidElement5(child)) return child;
309
+ const themedAxis = themeAxisChild({ child, variant: borderVariant, XAxis: RechartsXAxis4, YAxis: RechartsYAxis4, CartesianGrid: CartesianGrid4 });
310
+ if (themedAxis) return themedAxis;
230
311
  if (child.type === RechartsScatter || child.type?.displayName === "Scatter") {
231
312
  const idx = seriesIndex++;
232
313
  const existing = child.props.fill;
@@ -236,8 +317,8 @@ var ScatterChart = ({
236
317
  }
237
318
  return child;
238
319
  });
239
- return /* @__PURE__ */ jsx6(ChartContainer, { height, className, style, children: /* @__PURE__ */ jsxs4(RechartsScatterChart, { margin: { top: 5, right: 20, bottom: 5, left: 0 }, children: [
240
- grid && /* @__PURE__ */ jsx6(CartesianGrid4, { strokeDasharray: "3 3", stroke: getGridColor(), opacity: 0.5 }),
320
+ return /* @__PURE__ */ jsx6(ChartContainer, { height, className, style, borderVariant, children: /* @__PURE__ */ jsxs4(RechartsScatterChart, { margin: { top: 5, right: 20, bottom: 5, left: 0 }, children: [
321
+ grid && /* @__PURE__ */ jsx6(CartesianGrid4, { strokeDasharray: "3 3" }),
241
322
  themedChildren
242
323
  ] }) });
243
324
  };
@@ -281,6 +362,8 @@ import {
281
362
  Line as RechartsLine2,
282
363
  Bar as RechartsBar2,
283
364
  Area as RechartsArea2,
365
+ XAxis as RechartsXAxis5,
366
+ YAxis as RechartsYAxis5,
284
367
  CartesianGrid as CartesianGrid5
285
368
  } from "recharts";
286
369
  import { jsx as jsx8, jsxs as jsxs5 } from "react/jsx-runtime";
@@ -291,11 +374,14 @@ var ComposedChart = ({
291
374
  className,
292
375
  style,
293
376
  grid = true,
377
+ borderVariant = "default",
294
378
  children
295
379
  }) => {
296
380
  let seriesIndex = 0;
297
381
  const themedChildren = Children7.map(children, (child) => {
298
382
  if (!isValidElement7(child)) return child;
383
+ const themedAxis = themeAxisChild({ child, variant: borderVariant, XAxis: RechartsXAxis5, YAxis: RechartsYAxis5, CartesianGrid: CartesianGrid5 });
384
+ if (themedAxis) return themedAxis;
299
385
  const t = child.type;
300
386
  const dn = t?.displayName;
301
387
  if (t === RechartsLine2 || dn === "Line") {
@@ -325,8 +411,8 @@ var ComposedChart = ({
325
411
  }
326
412
  return child;
327
413
  });
328
- return /* @__PURE__ */ jsx8(ChartContainer, { height, className, style, children: /* @__PURE__ */ jsxs5(RechartsComposedChart, { data, margin: { top: 5, right: 20, bottom: 5, left: 0 }, children: [
329
- grid && /* @__PURE__ */ jsx8(CartesianGrid5, { strokeDasharray: "3 3", stroke: getGridColor(), opacity: 0.5 }),
414
+ return /* @__PURE__ */ jsx8(ChartContainer, { height, className, style, borderVariant, children: /* @__PURE__ */ jsxs5(RechartsComposedChart, { data, margin: { top: 5, right: 20, bottom: 5, left: 0 }, children: [
415
+ grid && /* @__PURE__ */ jsx8(CartesianGrid5, { strokeDasharray: "3 3" }),
330
416
  themedChildren
331
417
  ] }) });
332
418
  };
@@ -396,6 +482,11 @@ export {
396
482
  ScatterChart,
397
483
  ThemedTooltip as Tooltip,
398
484
  XAxis,
399
- YAxis
485
+ YAxis,
486
+ getAxisStyle,
487
+ getCSSVar,
488
+ getGridColor,
489
+ getLegendStyle,
490
+ getTooltipStyle
400
491
  };
401
492
  //# sourceMappingURL=index.js.map