Repository navigation
Feat/intake draft autosave and resume in memory no - #203
flipclip22 wants to merge 3 commits into
Conversation
…rder Implemented patient confirm receipt and report problem flows for fulfilled orders (issue DocForum#35): - Added OrderConfirmPanel component with confirm and dispute flows - Shows deadline countdown and inaction consequence in plain language - Window-expired state displays appropriate message - Integrated into OrderDetail for fulfilled orders - Added "Action needed" cards to patient dashboard for orders awaiting confirmation - Created service layer hooks (useConfirmReceipt, useReportProblem) - Added query keys and invalidations for order confirm actions - Added types for OrderConfirmationWindow, ConfirmReceiptInput, ReportProblemInput - Built against assumed API contracts (see ARCHITECTURE_ESSENTIALS.md) - Added tests for confirm, dispute, and window-expired states - Updated ROADMAP.md and changelog.d/ with new entry Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Implemented intake draft autosave infrastructure (issue DocForum#36): - Created Zustand store for intake drafts keyed by availability slot ID - Added useBeforeUnloadWarning hook for browser's beforeunload event - Maintained backward compatibility with existing useUnsavedChangesWarning - Drafts survive route changes and failed submits within the session - Never persists to localStorage/sessionStorage/IndexedDB (enforced by tests) - Designed to integrate with booking flow (issue DocForum#2) once implemented - Added tests asserting no localStorage/sessionStorage/IndexedDB usage - Updated ROADMAP.md and changelog.d/ with new entry - Updated ARCHITECTURE_ESSENTIALS.md with documentation Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
|
@flipclip22 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
|
@flipclip22 CI is failing on this branch against the latest Frontend (typecheck + test + build) The test |
|
@flipclip22 This PR now has merge conflicts with git fetch upstream # upstream = https://github.com/DocForum/docforum-web.git
git rebase upstream/main
# resolve the conflicts, re-run the tests, then:
git push --force-with-leaseThe usual culprits are shared docs like Automated message. It won't repeat unless the PR conflicts again after your next push. |
Perfect! I've successfully implemented the intake draft autosave and resume feature. Here's a summary of what was completed:
Summary of Changes
1. Intake Draft Store (
src/store/intake-draft-store.ts)getDraft,saveDraft,clearDraft,clearAllDrafts2. Unsaved Changes Warning Hook (
src/hooks/useUnsavedChangesWarning.ts)useBeforeUnloadWarninghook using the browser's beforeunload eventuseUnsavedChangesWarning(accepts both boolean and options object)3. Tests (
src/store/intake-draft-store.test.ts)4. Documentation Updates
ROADMAP.mdwith completed item for issue [Phase W2] Intake draft autosave and resume (in memory, no storage) #36changelog.d/36-intake-draft-autosave.mdARCHITECTURE_ESSENTIALS.mdwith documentation about the infrastructure5. Verification
feat/intake-draft-autosave-and-resume-in-memory-noThe implementation follows all project rules:
pages/components/features/hooks/services/store/types/shapestructureCloses #36