apps/eclipse/src/components/chart-examples/README.md
This directory contains interactive chart examples used in the Eclipse design system documentation.
These examples demonstrate various chart types and configurations using the Chart component from @prisma/eclipse, which is built on top of Recharts.
Import the examples in MDX files:
import { BasicBarChartExample } from "@/components/chart-examples/interactive-examples";
<BasicBarChartExample />
Or import from the index file:
import { BasicBarChartExample, LineChartExample } from "@/components/chart-examples";
chart-examples/
├── README.md # This file
├── index.ts # Barrel export file
└── interactive-examples.tsx # All chart example components
All examples use realistic Prisma-related data scenarios:
Some examples may show TypeScript warnings about missing payload props on ChartLegendContent. These are false positives - Recharts injects the payload prop at runtime through the render prop pattern. The examples will work correctly despite these warnings.
When adding new chart examples:
interactive-examples.tsxindex.ts[ChartType][Feature]Example