Skip to content

[stacked pr]: add local elections view with ballot information#88

Open
ThatXliner wants to merge 13 commits into
feat/civic-data-sourcesfrom
feat/local-elections-view
Open

[stacked pr]: add local elections view with ballot information#88
ThatXliner wants to merge 13 commits into
feat/civic-data-sourcesfrom
feat/local-elections-view

Conversation

@ThatXliner
Copy link
Copy Markdown
Collaborator

Summary

Adds a dedicated Local Elections view to the Expo app with:

  • Election Banner on the Browse tab showing countdown to upcoming elections within 30 days
  • Local Elections Screen (/local-elections) with:
    • My Ballot hero section with address input (persisted via AsyncStorage)
    • Key Dates horizontal scroll cards (registration deadline, early voting, election day)
    • Ballot Measures section from Google Civic API
    • Candidates section grouped by race
    • Local Bills section from Legistar (San Jose + Santa Clara County)

New Files

  • apps/expo/src/utils/dates.ts - Date utilities (daysUntil, formatDate, isWithinDays)
  • apps/expo/src/hooks/useUserAddress.ts - AsyncStorage hook for address persistence
  • apps/expo/src/components/ElectionBanner.tsx - Urgency countdown banner
  • apps/expo/src/components/MyBallotSection.tsx - Hero section with address input
  • apps/expo/src/components/KeyDatesSection.tsx - Horizontal date cards
  • apps/expo/src/components/BallotMeasuresSection.tsx - Propositions list
  • apps/expo/src/components/CandidatesSection.tsx - Candidates by race
  • apps/expo/src/components/LocalBillsSection.tsx - Legistar local legislation
  • apps/expo/src/app/local-elections.tsx - Main screen

Dependencies

  • @react-native-async-storage/async-storage - For persisting user address

Base Branch

This PR stacks on top of fix/civic-data-sources (#85) which adds the civic data APIs (Google Civic, Legistar, etc.).

Test Plan

  • Verify ElectionBanner appears on Browse tab when there is an election within 30 days
  • Tap banner navigates to Local Elections screen
  • Enter address and ballot information loads
  • Key dates calculated correctly from election day
  • Local bills load from San Jose and Santa Clara County

🤖 Generated with Claude Code

ThatXliner and others added 11 commits May 26, 2026 23:00
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Replace sp.md/lg/sm/xs with numeric sp[4]/[6]/[3]/[2] keys
- Add local color constants to components that need them
- Use useQuery with queryOptions pattern instead of .useQuery()
- Add @react-native-async-storage/async-storage dependency
- Fix implicit any types and non-null assertions

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented May 27, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
billion-nextjs Ready Ready Preview, Comment May 27, 2026 4:18pm

@ThatXliner ThatXliner changed the title feat(expo): add local elections view with ballot information [stacked pr]: add local elections view with ballot information May 27, 2026
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