- Add color field to annotations schema with default blue (#3b82f6)
- Add color picker UI with 5 preset colors (red, green, blue, yellow, white)
- Pass selected color through component hierarchy (Page -> Toolbox, CandleChart -> SvgOverlay)
- Store color when creating line annotations
- Render lines with their stored color
- Update database with color column
- Preview lines show selected color during drawing
Phase 1 of LINE_DRAWING_IMPROVEMENTS.md complete
- Add sorting to annotation markers in ascending order by time
- Fixes 'data must be asc ordered by time' error for markers
- Ensures both candle data and markers are properly sorted
- Add sorting by timestamp in ascending order before setting chart data
- Fixes 'data must be asc ordered by time' error from lightweight-charts
- Ensures chart displays correctly even if API returns unsorted data
- Add fixed width to sidebar (w-64) to prevent layout collapse
- Change chart container from flex-1 to w-full h-full for proper sizing
- Chart now properly displays after CSV upload
- Created CandleChart component with lightweight-charts integration
- Implemented SvgOverlay component for line drawing
- Integrated all components in main page
- Fixed TypeScript and Tailwind CSS compatibility issues
- Added comprehensive README.md with project documentation
- Created DEPLOYMENT.md with setup and troubleshooting guide
- Downgraded to stable versions (Tailwind v3, lightweight-charts v4)
- All 59 tasks from OpenSpec completed
- Toolbox component with tool selection (break up/down, line, delete)
- FileUpload component with CSV upload functionality
- Main page layout with sidebar and chart area
- Tool state management and export functionality
- CSV upload with papaparse (handles date strings and Unix timestamps)
- Annotations CRUD (GET, POST, DELETE)
- Candles GET endpoint
- Export annotations as CSV
- Set up Next.js with App Router, TypeScript, Tailwind CSS
- Configure shadcn/ui with dark theme
- Install dependencies: lightweight-charts, papaparse, lucide-react
- Set up Drizzle ORM with better-sqlite3
- Create database schema for candles and annotations tables
- Generate migration SQL