Skip to content

feat: document receipt scanning and up to five files per expense - #13

Merged
musa-kal merged 3 commits into
mainfrom
docs/receipts
Nov 14, 2026
Merged

musa-kal merged 3 commits into
mainfrom
docs/receipts

Conversation

@musa-kal

Copy link
Copy Markdown
Member

Intent

Guide pages for receipt scanning and several attachments per expense (potluck PR #33, ADR 21): up to five photos or PDFs per expense, the photo viewer, Scan a receipt (on-device reading, what it reads, the review sheet where prices can be corrected and merchant and date ticked, the mismatch warning and the worked-out total notice, Fill in the expense), the by-item split filled from a scan, privacy (scanning on the device, files private to the group, daily cleanup of unused uploads), troubleshooting and FAQ. Every claim must match the app at potluck origin/feat/receipts f82d0fb. The app's help anchors #scan-a-receipt and #who-can-see-a-receipt must exist and no existing anchor may break.

What Changed

  • Rewrote expenses/receipts.mdx for up to five photos or PDFs per expense, covering which files work, the photo viewer, and a new Scan a receipt section (#scan-a-receipt): what it reads, the review sheet, what Fill in the expense does, getting a good read, and the first scan. Updated the Receipts topic menu blurb.
  • Added links to scanning and multi-file receipts from the add-expense steps, by-item splits, edit history (attachment count entries), repeating expenses, backup notes, and the FAQ (two new questions, plus offline scanning).
  • Added a Receipts and scanning section to Privacy and security (on-device reading, files private to the group, photo shrinking, daily cleanup of unused uploads, deleted groups). Updated the visibility table, backup exclusions and "What leaves the app". Expanded troubleshooting with the new upload errors and a new "A receipt will not scan" section.

Risk Assessment

✅ Low: Docs-only change. Both round-1 rewordings now match the app at f82d0fb: parse-receipt.ts drops tax, tip or discount only when a fallback combination sums, and fillFromScan takes the amount from itemsTotal whenever items are ticked, with Total gating only the Everything else line. The required anchors #scan-a-receipt and #who-can-see-a-receipt exist, and the existing #a-receipt-will-not-upload anchor is kept.

Testing

  • ⏭️ Test - skipped

Pipeline

Updates from git push no-mistakes

✅ **Intent** - passed

✅ No issues found.

✅ **Rebase** - passed

✅ No issues found.

🔧 **Review** - 2 issues found → auto-fixed ✅
  • ⚠️ src/content/docs/expenses/receipts.mdx:73 - Claim does not match the parser at f82d0fb. "Tax, tip and discount, but only when they make the receipt add up" is only partly true. In packages/core/src/receipts/parse-receipt.ts:545-555, when the full set does not sum to the total, the parser drops tax, tip or discount only if one of the listed fallback combinations does sum. If none of them sum (for example, a misread item line on a receipt with a tax line: items 38.00, tax 3.20, total 44.80), the parser keeps all three. The review sheet then shows them, and fillFromScan copies them into the by-item split. That is exactly the case where the guide says they are left out, which conflicts with the intent's 'every claim must match the app'. Fix: reword, e.g. 'Tax, tip and discount. When some of them would stop the receipt adding up and leaving them out makes it add up, they are left out', or simply drop 'only'.
  • ℹ️ src/content/docs/expenses/receipts.mdx:81 - "Untick a part and the form keeps what you already had for it" does not hold for the Total box. In apps/web/src/features/expenses/receipts/scan-fill.ts (fillFromScan), when items stay ticked and Total is unticked, the amount is still replaced by itemsTotal(next), the split switches to by-item, and the currency switches if the receipt's differs. Unticking Total only stops the 'Everything else' line from being added. The intent requires claims to match the app. Fix: qualify the sentence, e.g. 'With the items ticked, the amount always comes from the items; unticking Total only leaves out the Everything else line.'

🔧 Fix applied.
✅ Re-checked - no issues remain.

⏭️ **Test** - skipped

Step was skipped.

✅ **Document** - passed

✅ No issues found.

✅ **Lint** - passed

✅ No issues found.

✅ **Push** - passed

✅ No issues found.

musa-kal and others added 3 commits November 13, 2026 23:55
Rewrites the receipts page for up to five photos or PDFs per expense, the
photo viewer and on-device receipt scanning, and brings splits, the expense
form, edit history, privacy, troubleshooting and the FAQ in line with it.

Co-authored-by: Ferrin <177692050+Ferrin-Y@users.noreply.github.com>
Co-authored-by: noorelmosrati <182049385+noorelmosrati@users.noreply.github.com>
@musa-kal
musa-kal merged commit d41835c into main Nov 14, 2026
2 checks passed
@musa-kal
musa-kal deleted the docs/receipts branch November 14, 2026 05:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant