81 lines
3.3 KiB
Markdown
81 lines
3.3 KiB
Markdown
## Why
|
|
|
|
The candle annotator currently has basic line drawing functionality (Phase 1-4 complete: color support, visual feedback, selection, and endpoint dragging). Users need more comprehensive annotation management including bulk deletion, label CRUD operations, production deployment capability, and an improved UI theme. These features are essential for efficient annotation workflows and real-world deployment scenarios.
|
|
|
|
## What Changes
|
|
|
|
### Label Management System
|
|
- **Delete All Labels**: Add button to remove all break_up/break_down markers with confirmation
|
|
- **Select Label**: Make label markers (arrows) clickable to select/highlight them
|
|
- **Delete Specific Label**: Delete individual selected label marker (keyboard or UI button)
|
|
- **Label CRUD UI**: Add collapsible section in Toolbox sidebar showing:
|
|
- List of all label annotations (timestamp, type, color-coded)
|
|
- Click to select/highlight on chart
|
|
- Delete button per label
|
|
- Count of each label type
|
|
- Search/filter by type
|
|
|
|
### Docker Deployment
|
|
- **Dockerization**: Create production-ready Docker setup:
|
|
- Multi-stage Dockerfile (build + runtime)
|
|
- docker-compose.yml for easy deployment
|
|
- Volume mounting for persistent SQLite database
|
|
- Environment variable configuration
|
|
- Health check endpoint
|
|
- Production build optimization
|
|
- Documentation in DEPLOYMENT.md
|
|
|
|
### UI Theme Enhancement
|
|
- **Hacker-Style Theme**: Transform interface to minimal, terminal-inspired design:
|
|
- Monospace fonts throughout
|
|
- Matrix-style green (#00ff41) accents on dark background
|
|
- Neon glow effects on active elements
|
|
- Simplified borders with ASCII-style corners
|
|
- Terminal-like command feedback messages
|
|
- Minimalist icons or ASCII art alternatives
|
|
- High contrast for readability
|
|
- Cyber/retro aesthetic without sacrificing usability
|
|
|
|
## Capabilities
|
|
|
|
### New Capabilities
|
|
- `label-management`: Complete CRUD interface for label annotations in sidebar
|
|
- `docker-deployment`: Containerized deployment with docker-compose
|
|
- `hacker-theme`: Terminal-inspired minimal dark theme with neon accents
|
|
|
|
### Modified Capabilities
|
|
- (none - only adding new features, not changing existing requirements)
|
|
|
|
## Impact
|
|
|
|
### Code Changes
|
|
- **Database**: No schema changes needed (existing tables support all operations)
|
|
- **Components**:
|
|
- `Toolbox.tsx`: Add label list UI, delete buttons, collapsible sections, theme styling
|
|
- `CandleChart.tsx`: Add label selection click handlers, highlight logic
|
|
- `page.tsx`: Add state for selected label, pass callbacks
|
|
- **API Routes**:
|
|
- `DELETE /api/annotations`: Add query param for bulk delete (by type or all)
|
|
- `GET /api/health`: New endpoint for Docker health checks
|
|
- **Styling**: Update `globals.css` and Tailwind config for hacker theme
|
|
- **New Files**:
|
|
- `Dockerfile`
|
|
- `docker-compose.yml`
|
|
- `.dockerignore`
|
|
- `.env.example`
|
|
|
|
### Dependencies
|
|
- No new npm packages required (existing stack covers all needs)
|
|
- Docker runtime required for deployment
|
|
|
|
### Deployment
|
|
- Current dev workflow unchanged
|
|
- New production deployment path via Docker
|
|
- Database persistence via volume mounts
|
|
- Environment-based configuration
|
|
|
|
### User Experience
|
|
- More efficient annotation workflows (bulk operations)
|
|
- Better annotation visibility and organization (sidebar list)
|
|
- Easier deployment to servers (docker-compose up)
|
|
- More visually distinctive theme (hacker aesthetic)
|