Skip to content

[00001] Introduce cutoff date for commits and PRs from November to April#16

Open
joshuauaua wants to merge 1 commit into
Ivy-Interactive:mainfrom
joshuauaua:tendril/00001-00001-IntroduceCutoffDateForCommitsAndPRsFromNovemberToApril
Open

[00001] Introduce cutoff date for commits and PRs from November to April#16
joshuauaua wants to merge 1 commit into
Ivy-Interactive:mainfrom
joshuauaua:tendril/00001-00001-IntroduceCutoffDateForCommitsAndPRsFromNovemberToApril

Conversation

@joshuauaua

Copy link
Copy Markdown

Summary

Changes

Added date range filtering to the PR Cost Calculator, allowing users to filter PRs and analysis to a specific time period (November 2025 to April 2026 by default). The feature includes a checkbox to enable filtering and date pickers to customize the range. When enabled, all charts and statistics are recalculated to show only PRs within the selected period.

API Changes

New functions:

  • filterPRsByDateRange(prs: PullRequest[], startDate: Date, endDate: Date): PullRequest[] — filters PRs by creation date within the specified range

Modified function signatures:

  • getMonthlyStats() — added optional startDate?: Date and endDate?: Date parameters
  • getRollingAverages() — added optional customStartDate?: Date and customEndDate?: Date parameters

Files Modified

Backend:

  • src/lib/calculations.ts — added date filtering function and optional date range parameters to calculation functions
  • src/lib/calculations.test.ts — added comprehensive tests for date filtering functionality

Frontend:

  • src/components/ComparisonChart.tsx — added date range state, UI controls (checkbox and date pickers), and integrated filtering into all data calculations

Commits

  • 3ee83f1 [00001] Add date range filtering for PRs (November to April)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant