Files
myworkspace/LinkSyncExtension/TODOs.txt
DavidSaylor 09d30427f4 Complete LinkSyncServer and LinkSyncExtension implementation
LinkSyncServer:
- Fix app.py imports, add CORS middleware, lifespan events
- Create api/routes.py router aggregator
- Create config/settings.py for centralized configuration
- Rewrite models/base.py with proper relationships and serialization
- Rewrite all API endpoints with real DB integration (auth, links, collections, sync, queries, tags)
- Add admin endpoints (user management, stats, audit log)
- Complete query parser with recursive descent and proper precedence
- Complete query executor with set operations and field filters
- Set up Alembic migrations with initial schema
- Create web interface (templates, CSS, JS)
- Add 42 passing tests (auth, links, collections, queries)
- Add deploy.ps1 and deploy.sh scripts
- Update README with deployment workflow

LinkSyncExtension:
- Create utils/api.js (REST client with retries, auth, error handling)
- Create utils/sync.js (3 sync modes + conflict detection)
- Create utils/collection.js (collection management)
- Create utils/query-engine.js (client-side query parser)
- Rewrite background.js (sync loop, bookmark events, message routing)
- Rewrite popup.js (tabs, settings modal, notifications, CRUD)
- Update popup.html (tabbed interface, query builder, modal)
- Update popup.css (full redesign)
- Create content/content.js (page metadata extraction)
- Create options.html/js (dedicated settings page)
- Generate icons (48x48, 96x96)
- Update manifest.json (host permissions, content scripts, options)
- Create AGENTS.md
2026-05-19 13:21:26 -05:00

133 lines
4.1 KiB
Plaintext

# LinkSyncExtension - Task List
## Project Setup
- [x] Create project directory structure
- [x] Write README.md
- [x] Write TODOs.txt
- [x] Write design.md
- [x] Write tasks.md
- [x] Write AGENTS.md
- [x] Create manifest.json (with all permissions, content scripts, options page)
- [x] Add icon files (48x48, 96x96)
## Core Development
### Extension Manifest
- [x] Create manifest.json with Firefox-specific settings
- [x] Add icon files (48x48, 96x96)
- [x] Configure permissions (bookmarks, storage, activeTab, tabs, <all_urls>)
- [x] Set browser ID (linksync@example.com)
- [x] Add content scripts registration
- [x] Add options page registration
### Background Script
- [x] Create background.js service worker
- [x] Implement init() on install/update
- [x] Implement sync loop with interval (5 min)
- [x] Add event handlers (message, bookmark changes)
- [x] Implement sync mode switching
- [x] Manage collection mapping
- [x] Auto-sync timer
- [x] Error handling
### Popup Script
- [x] Create popup.html with tabs (Bookmarks, Collections, Query)
- [x] Create popup.css with full styling
- [x] Create popup.js with all functionality
- [x] Bookmark form UI with auto-fill
- [x] Bookmark list view with search
- [x] Collections panel
- [x] Query builder with parse/execute
- [x] Settings modal
- [x] Sync button handler
- [x] Toast notifications
### Utility Modules
- [x] utils/bookmark.js - Bookmark manipulation (parse, merge, format)
- [x] utils/collection.js - Collection management (CRUD, query execution)
- [x] utils/query-engine.js - Query parsing (tokenizer, recursive descent parser)
- [x] utils/sync.js - Sync logic (3 modes, conflict detection)
- [x] utils/api.js - API client (auth, retries, error handling, all endpoints)
### Content Script
- [x] content/content.js - Extract page title, description, favicon
- [x] Handle browser.runtime.onMessage for getPageData
### API Integration
- [x] /api/auth/login - Authentication
- [x] /api/links/ - Bookmark CRUD (GET, POST, PUT, DELETE)
- [x] /api/collections/ - Collection CRUD
- [x] /api/queries/parse/ - Query parsing
- [x] /api/queries/execute/ - Query execution
- [x] /api/sync/ - Sync endpoint
- [x] /api/admin/stats - Admin stats
- [x] /health - Connection test
### Sync Logic
- [x] Implement bi-directional sync
- [x] Implement browser-authoritative sync
- [x] Implement server-authoritative sync
- [x] Handle deletions checkbox
- [x] Conflict detection (title mismatches)
### UI Components
- [x] Tabbed interface (Bookmarks, Collections, Query)
- [x] Bookmark list view with search filter
- [x] Collection list
- [x] Query builder with syntax help
- [x] Sync status indicator (syncing/synced/error)
- [x] Settings modal
- [x] Toast notifications
- [x] Options page (dedicated settings)
### Storage Management
- [x] Store API key in browser.storage.local
- [x] Store server URL
- [x] Store sync settings (mode, deletions, auto-sync)
- [x] Sync timestamp tracking
- [x] Pending changes tracking
- [x] Syncing state flag
## Options Page
- [x] Create options.html
- [x] Create options.js
- [x] Server URL configuration
- [x] API key input (password field)
- [x] Sync mode dropdown
- [x] Deletions checkbox
- [x] Auto-sync checkbox
- [x] Test connection button
- [x] Sync now button
- [x] Last sync display
## Security
- [x] API key stored in browser.storage.local (not localStorage)
- [x] Bearer token authentication
- [x] Input sanitization (escapeHtml)
- [x] Request timeout handling
- [x] Rate limit handling (429 retry)
## Testing
- [x] Manual testing checklist (tests/README.md)
- [ ] Test sync modes (manual)
- [ ] Test conflict resolution (manual)
- [ ] Test query execution (manual)
- [ ] Test offline handling (manual)
- [ ] Test error handling (manual)
## Documentation
- [x] API reference (README.md)
- [x] User guide (README.md)
- [x] Troubleshooting guide (README.md)
- [x] Query syntax guide (README.md)
- [x] Architecture docs (AGENTS.md, design.md)
## Future Enhancements
- [ ] Background sync notifications
- [ ] Keyboard shortcuts
- [ ] Dark theme toggle
- [ ] Bookmark edit/delete from popup
- [ ] Batch operations
- [ ] Conflict resolution UI
- [ ] Offline queue for pending changes