I'll create an interactive math learning dashboard for students. Let me start by exploring the project structure.
The project is a clean Vite + React + Tailwind v4 setup. I'll build a full dashboard with custom SVG charts (animated), a data layer with realistic seeded sample data, and dark mode. Starting with the styles and data layer.
Now the animation/measurement hooks that power smooth chart transitions.
Now the three animated SVG chart components with hover tooltips.
Now the shared UI primitives and KPI cards.
Now the sortable/filterable data table and the filter bar.
Now the header/filter shell and the consistency heatmap.
Now the main App that wires everything together with live-updating derived data.
Now updating the HTML shell with a proper title and the Inter font.
Build passes. Let me verify the entry file and clean up a small class typo.
A few polish tweaks: charts should animate in on mount, and the donut needs tighter sizing for narrow columns.
A couple of robustness fixes for chart scaling during transitions (values can briefly exceed the axis while tweening) and for rest-day accuracy gaps.
Let me verify the dark-mode CSS actually compiled into the bundle.
One last data-quality fix: comparisons against a previous period that extends past the start of available history should be normalized.
The build is clean. Here's what I created — MathQuest, a student-facing math practice analytics dashboard:
Data layer (src/lib/data.ts)
- A seeded generator produces 210 days of realistic practice history for one student: 6 topics × 6 skills each, three difficulty levels, four session modes, with a believable improvement curve, weekday/weekend rhythm, exam-week spikes, a two-week slump, and occasional rest days.
- Aggregation helpers: date bucketing (auto-downsamples long ranges), period totals, skill breakdowns, streak calculation, and previous-period comparison (normalized when history runs out).
Charts (hand-built SVG, no chart library)
- Line/area chart — dual axis (chosen metric + accuracy overlay), monotone-cubic curves, crosshair, and a floating tooltip that flips sides near the edge.
- Stacked bar chart — problems by topic (or by skill when a single topic is selected), split by difficulty, with column highlight and a breakdown tooltip.
- Donut chart — time distribution with arc-expand hover, live center readout, and a synced legend.
- Sparklines in each KPI card, plus a 20-week consistency heatmap where days outside the selected range dim out.
- A custom
useTween hook interpolates every array of values with requestAnimationFrame, so charts morph smoothly whenever a filter changes (and respects prefers-reduced-motion).
Interactions
- KPI cards — problems solved, accuracy, practice time, XP, each with counting-up values, trend pills vs. the previous equivalent period, and sparklines.
- Filters — date presets (7D/30D/90D/6M) + custom from/to date pickers, multi-select topic chips, difficulty segmented control, and mode dropdown. Everything recomputes live, including the table, heatmap, insight line, and card titles.
- Practice log table — sortable on every column, text search, pagination, accuracy micro-bars, and CSV export.
- Skill focus card toggles between "Needs work" and "Strengths".
- Dark mode toggle with system preference detection and localStorage persistence, animated sun/moon icon, and a fully themed palette.
Layout is responsive from a single mobile column up to a 3-column desktop grid, with progressively revealed table columns and horizontally scrollable filter chips.
Files built: src/index.css, src/lib/data.ts, src/hooks/useChartHooks.ts, src/components/Tooltip.tsx, src/components/charts/LineChart.tsx, src/components/charts/BarChart.tsx, src/components/charts/DonutChart.tsx, src/components/charts/Sparkline.tsx, src/components/ui.tsx, src/components/KpiCard.tsx, src/components/DataTable.tsx, src/components/Shell.tsx, src/components/Heatmap.tsx, src/App.tsx, index.html