feat(ui): contribution graph with daily activity heatmap
Add /v1/activity/daily endpoint returning per-day event counts via generate_series + LEFT JOIN. Frontend renders an SVG contribution graph with circles colored by quantile-based thresholds. Clicking a day navigates to /activity/YYYY-MM-DD showing that day's events. New /activity/:timespan route parses single dates (YYYY-MM-DD) and ranges (YYYY-MM-DD..YYYY-MM-DD) from the URL to initialize the activity timeline filter. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -4,6 +4,7 @@ import Col from 'react-bootstrap/Col';
|
||||
import Row from 'react-bootstrap/Row';
|
||||
|
||||
import { fetchProjects, fetchLanguages, type ProjectSummary, type Source } from '../api/client';
|
||||
import { ContributionGraph } from '../components/ContributionGraph';
|
||||
|
||||
export function DashPage() {
|
||||
const projectsQ = useQuery({
|
||||
@@ -25,6 +26,7 @@ export function DashPage() {
|
||||
</p>
|
||||
</Col>
|
||||
</Row>
|
||||
<ContributionGraph />
|
||||
{projectsQ.isLoading && <p>loading...</p>}
|
||||
{projectsQ.isError && (
|
||||
<p>error: {(projectsQ.error as Error).message}</p>
|
||||
|
||||
Reference in New Issue
Block a user