Skip to content

feat(history): Persistent Race Session History & Performance Analytics Center #88

Description

@Sanan507

Overview

Persist complete race execution history across browser reloads using localStorage and build a historical performance analytics dashboard where users can filter past races, compare speed trends over time, and clear stored history.

Implementation Details & File Reference

  • History Storage: Create frontend/src/utils/historyStorage.ts to read/write RaceHistoryEntry[] in localStorage.
  • Event Hook: Automatically record race completions in SortingPage.tsx, SearchingPage.tsx, and PathfindingPage.tsx.
  • History Page Update: Refactor frontend/src/pages/HistoryPage.tsx to display real persistent history entries alongside theoretical complexity matrices.
  • Filtering & Clearing: Add filter dropdown (by Arena Type / Winner) and a "Clear History" button wired to localStorage.removeItem().

Definition of Done

  • Refreshing the application preserves past race history logs.
  • History Page displays real race entries with dates, winner badges, and metric summaries.
  • Clear History wipes stored data and updates UI immediately.

Skill Level

Medium — localStorage state management, type definitions, and history page UI integration.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions