Commit Graph

7 Commits

Author SHA1 Message Date
1df93bd385 Add local tag server check, archive on delete, and first-run pin reminder
- Local tag is now clickable - checks if document exists on server by ID
  or filename, and re-links if found
- Delete from server now archives the proxy instead of removing it,
  making it a local-only document that can be re-uploaded
- Added first-run pin reminder banner to help users pin the extension
- Added issue report modal with context sections (extension info, browser
  info, document status, recent errors) and copy to clipboard as Markdown
- Added clearServerFields and attachServerDocument functions to pdf-queue
- Improved local tag styling with hover states and visual feedback

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-16 23:39:06 +01:00
e5f3f583d1 Refresh erroneous documents to detect server-side fixes
- Include erroneous server documents in auto-refresh
- Documents can transition from ERRONEOUS to SHIPPABLE when fixed on server
- Clear error message when document status becomes non-erroneous
- Properly handle status transitions in refresh flow

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-16 22:56:39 +01:00
327943bc18 Server sync, erroneous doc handling, and @binect/js v0.1.0 integration
- Add server sync to discover documents uploaded elsewhere (fixes missing
  basket documents issue)
- Handle erroneous uploads: preserve binectDocumentId for delete button
- Add "Delete from server" button for erroneous and canceled documents
- Remove archive button for active documents (in_basket, in_production)
- Auto-restore archived documents that have active status
- Refactor to use @binect/js v0.1.0 features:
  - DocumentStatus enum instead of magic numbers
  - isErroneous(), getErrors() helper functions
  - getStatusDescription() for status text
- Add binect-js improvement requirements document

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-16 22:41:43 +01:00
facae724bf Implement document proxy concept with archive/live views
- Add content hash (MD5) for document deduplication
- Separate local state (archived) from server state (binectStatus)
- Add archive toggle button to switch between live/archived views
- Add archive/restore/delete actions for documents
- Refactor pdf-queue.ts with DocumentProxy interface
- Add hash.ts utility for content hashing

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-16 17:11:15 +01:00
468473f03b Fix state persistence when popup is closed
- Add 'dismissed' status to prevent dismissed PDFs from reappearing
- Persist PDFs discovered from current tab and recent downloads via background
- Add dismissPDF function that marks PDFs as dismissed instead of removing
- Dismissed PDFs are kept for 7 days for duplicate detection, then cleaned up
- Completed items (sent/canceled) can still be fully removed
- Add addPDF message handler to service worker for popup-discovered PDFs

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-16 10:20:28 +01:00
3a48d4f497 Add document lifecycle tracking with order/production status
- Extended PDFStatus with full lifecycle: pending → uploading → in_basket →
  ordering → in_production → sent/canceled
- Added shipDocument() and getDocumentStatus() API methods
- Grouped UI sections: Ready to Upload, In Basket, In Production, Completed
- Order button for documents in basket to place production order
- Refresh button to check current status from Binect server
- Display price and recipient address for uploaded documents
- Status icons and color-coded indicators for each state

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-16 10:17:28 +01:00
3e86bb126b Add PDF list view with upload status tracking
- Show all pending PDFs in a scrollable list instead of single PDF
- Track upload status (pending/uploading/uploaded/failed) per PDF
- Store queue in chrome.storage.local for persistence
- Prevent duplicate uploads by checking URL against uploaded PDFs
- Add Dismiss button to remove PDFs from queue
- Show badge with count of pending PDFs
- Auto-cleanup old entries (uploaded >7 days, failed >24h)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-15 14:55:32 +01:00