Three new export formats, all reusing this pipeline's existing
transactions data with no new extraction logic:
- QBO (QuickBooks Web Connect / Quicken): qbo_service.py writes OFX 1.x
SGML directly, including <INTU.BID>3000 so it actually qualifies as a
real QBO/QFX file (corrected same day from an initial build that
produced plain generic OFX with a .qbo extension slapped on - see
CLAUDE.md for the research trail). Needs a reusable, project-scoped
bankAccountProfiles record (pb_migrations/14) so a user isn't re-typing
routing/account numbers on every export of the same real account.
- Xero (import CSV): xero_csv_service.py, no bank-account concept at all
(Xero's own CSV import has none) - genuinely simpler than QBO.
- A plain, generic transactions CSV (csv_service.py) - distinct from
Xero's import-specific shape, writes every row regardless of a missing
date/amount since a plain dump has no structural requirement to violate.
The three original separate download buttons were consolidated into one
Download trigger + hover dropdown (QuickBooks/Xero/CSV/Excel), reusing
the Results dropdown's own zero-dead-zone hover structure. Excel's and
the new CSV's single/all download logic was generalized behind one
DOWNLOAD_FORMATS lookup rather than duplicated.
Also adds a per-transaction "include in downloads" checkbox - a lighter,
reversible alternative to permanently deleting a row: excludedFromExport
lives on the document's own result, read only at download time, with
zero effect on the live review screen's own data/checks.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
- Compute a fingerprint unconditionally on every successful extraction
(not just the two failure paths), so a "Map" button on an already-
successful document can open the manual mapping screen to CORRECT it
via a real fingerprint, not just the auto-triggered failure flow.
- Extend forced-mapping support to OCR-sourced statements (scanned PDFs
and raw photos): raw_ocr_extract.py gains forced_zones/header_bottom/
date_format/value_patterns support and a new header_candidate_geometry
for OCR-derived fingerprinting; a forced OCR mapping bypasses Docling's
table-structure call entirely.
- Recognize parenthesized negative amounts ("(25.00)") via a shared
_split_sign() helper used by both _parse_money() and
_parse_money_with_patterns() - fixes a real blank-extraction bug on a
single-Amount-column statement using this accounting convention.
- Upscale a low-resolution image before OCR (_MIN_OCR_WIDTH_PX) - a real
480x800px phone photo was barely readable by tesserocr at native size.
- ManualMappingView.vue: no longer requires a Balance column (some real
statements don't print one), and imagePointScale converts a drawn
region's coordinates from an image's natural-pixel space into PDF
points before sending a forced mapping - every image-sourced mapping
before this sent zones in the wrong coordinate space entirely.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
A deliberate scope expansion past this product's original "does not
categorize transactions" boundary: project-scoped categorizationRules
(PocketBase), pure-JS matching (longest-pattern-wins, case-insensitive
substring), a Categorization tab beside Transactions, and an optional
"Categorized Summary" sheet in the Excel export. Categorization is
computed live from current rules and never persisted on the document
itself - only the rules persist.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
New ValueRecognitionRequired, parallel to LayoutMappingRequired, closes
a real silent gap: a statement whose header resolves but whose every
value fails to parse (the CAD bug's own failure mode) previously
returned a plain 200 with transactions:[] and no error at all. Carries
one representative candidate row (table_extract.value_recognition_preview,
built on the existing header_candidate_geometry) for the frontend to
show a user, so they can correct values without drawing a single
column region.
value_patterns threads through extract_pdf/extract_page as a new,
independent forced_mapping field (composes with auto-detection, since
a mapping with only valuePatterns and no columnMap behaves like plain
auto-detection). _money_value() gained an optional `patterns` list
tried at two breadths - discovery (every distinct pattern, used by
clustering/_dominant_money_marker, neither of which knows field
identity yet) vs. classification (just one field's own pattern, once
_classify_money already knows the field) - a first, field-scoped-only
design was caught during plan review as not actually fixing anything,
since clustering runs on raw text before any field is known.
Two more real bugs caught by this stage's own testing: the pattern
strip didn't account for a leading "-" (every negative amount silently
failed to parse even with a correct pattern); the preview's own rough
fallback zone used the wrong padding asymmetry and bled into the next
column's values.
Verified: a synthetic bare-3-letter-currency-code statement (a format
the existing symbol-based fallback genuinely can't recognize) triggers
ValueRecognitionRequired correctly, then extracts all 3 transactions
correctly once valuePatterns are supplied with zero columnMap. The
earlier CA$-fix and USD-regression tests re-run clean. measure.py
byte-identical to baseline.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Replaces the one-off "CA$" regex fix with a general mechanism:
_parse_money()/_money_value() recognize any currency-wrapped amount
(a currency-code prefix, or any real Unicode currency symbol via
category "Sc") rather than needing a new _MONEY_RE branch hardcoded
every time an unseen format shows up. Letters alone (no symbol) still
correctly fail, so a reference code like "REF123.45" is never
misread as money.
This alone reintroduced a real phantom-transaction bug, caught before
shipping by re-testing the already-fixed Equals Money USD fixture:
its own currency-exchange footnotes print a converted foreign-currency
amount (e.g. "£964.58") that's genuinely money-shaped but isn't this
ledger's own currency - and because this bank's narrative continuation
lines span the full page width, that token's x-position coincidentally
fell inside the money column's zone, promoting the whole line into a
phantom 37th transaction with a broken balance chain.
Fixed with a dominant-marker gate: _dominant_money_marker() tallies
every money-shaped word's own currency marker on a page, and the
fallback only accepts whichever marker is most common - a real
statement's own amounts use the same marker dozens of times; a one-off
foreign marker marks itself as an annotation, not the ledger's money.
Verified: 19 direct assertions on _money_value (including the false-
positive guards), the regression reproduced then fixed against the
real USD fixture (37→36 transactions, balance checks restored), the
original CAD case re-verified via a reconstructed synthetic PDF (its
real file's PocketBase record was since deleted), and the full
HSBC/RBC fixture corpus byte-identical to baseline throughout.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
A CAD-denominated Equals Money statement extracted zero transactions -
every amount prints as "CA$386.01" (a currency-code prefix before the
$), which _MONEY_RE only tolerated as a bare "$". Widened the regex to
accept an optional 1-3 letter prefix, but only when immediately
followed by a literal $ - a broader letters-only version was tried and
rejected first since it would also match a plain reference code like
"REF123.45". _classify_money's own numeric parsing now strips any
remaining non-numeric characters generically rather than only "$".
Verified against the user's actual uploaded file (retrieved from
PocketBase/R2): all 3 transactions and the opening/closing balance now
extract correctly, with statement_balance/running_balance/date_sanity/
structure_sanity all passing. measure.py re-run against the full
fixture corpus, byte-identical to baseline.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
New /layouts route (LayoutsView.vue, linked from AppHeader.vue): List (own + shared
mappings with usage/failure stats), Inspect (source document with each column drawn
as a labeled vertical strip), Test (an unsaved dry run against any of the user's own
documents), Version history + Roll back (append-only - a rollback creates a new
version rather than editing history), and Retire. The plan's own "Edit" (reopening
ManualMappingView pre-populated) was deliberately dropped - columnMap never persists
page/vertical position, so there's no real data to re-populate a visual editor with.
Drift detection now runs on every recheck, not just the original extraction -
useRowEditing.js and TransactionRow.vue both call the same recordUsage() useBatchExtraction.js
already used, via a newly shared layoutMappingsService.checksPassed(). Required
threading layoutMappingUsed/layoutMappingVersionUsed onto the in-memory document
object too (extractionStore/useDocuments/useBatchExtraction), not just the PocketBase
record.
Found and fixed two real bugs via this stage's own end-to-end testing, both in the
same "computed correctly this session, never persisted" category as L.6's zone-padding
fix: startPage itself was never saved, so every future auto-apply of a saved mapping
would have silently reset to page 1, reintroducing the cover-page bug L.2 already
fixed once. Worse: startPage alone only skips whole pages - it does nothing about the
real header row text still sitting on the start page itself, which would have
corrupted essentially every real manually-mapped statement. Fixed with two new
persisted fields (startPage, headerBottom) and a new header_bottom parameter in
table_extract.py, using the same zone-padding margin as a safety buffer.
Verified against the real rebuilt container: a 2-page synthetic statement confirmed
both bugs real before their fixes and confirmed both fixed together; a second,
independent upload auto-applies the saved mapping with both fields carried through;
sourceDocument backfill, version history/rollback, retire, and real three-user
promotion all confirmed against the real PocketBase; a separate test confirmed the
recheck-triggered drift detection itself, flipping a real mapping to stale after a
deliberately broken running-balance edit. measure.py byte-identical throughout; npm
run build passes.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
New /map-layout route (ManualMappingView.vue): draw a box over each column on the
source document, assign it a role, set date format/sign convention/ignored rows,
Preview (required before Save) runs the real forced-mapping extraction and shows
the first ten rows plus the balance check outcome, Save Mapping persists the
mapping + an initial version + the document. A real File can't survive a router
navigation, so a new layoutMapperStore holds the one pending file + fingerprint in
memory; ExtractorView.vue shows a banner linking to the mapper while one is set.
Two real bugs found by actually wiring this up and testing it end to end:
useBatchExtraction.js was reading fingerprintHash from the wrong (post-reassignment)
response, which never carries that field - would have silently left
documents.layoutFingerprintHash unset for every mapping-applied extraction. More
consequential: forced-mapping column zones were completely unpadded, so a word
landing a fraction of a point past a raw boundary (or a human's own imprecise drag)
could silently exclude a whole transaction with no error - fixed with a new
_FORCED_ZONE_PADDING in table_extract.py, the same discipline the auto-detected
path's own zones already use.
Verified end to end against a hand-built synthetic statement (unmatchable gibberish
headers, 3 real transaction rows at known coordinates) through the real rebuilt
container: Preview correctly extracts all 3 transactions with a passing balance
check; Save persists correctly (confirmed on the re-fetched document record, not
the create response); a second, independent upload of the identical file then
silently auto-applies the saved mapping with zero further input, producing
byte-identical results to the manual Preview - the actual proof this feature
exists for. measure.py byte-identical throughout; a regression re-run of the
earlier Equals Money forced-mapping test confirmed the zone-padding fix changed
nothing there. npm run build passes.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
useBatchExtraction.js now reacts to a needs_mapping:true response: looks up an
exact or near-match layout mapping (layoutMappingsService.js), applies it silently
on an exact match, asks for confirmation on a stale exact match or a near match via
a real ConfirmModal wired through ExtractorView.vue (not a placeholder), and falls
through to reason:'no_match' when nothing matches (the manual mapping screen's own
entry point, not built yet). A used mapping's usage is recorded for drift detection
and persisted onto the saved document record.
Found and fixed two real bugs in the near-match comparator by testing it against
the spec's own documented example (Debit/Credit renamed to Withdrawals/Deposits):
compute_fingerprint was building header_labels from whole header LINES instead of
per-field label text, making a two-word rename indistinguishable from a totally
different layout; added a field_labels map so the comparison is per-field. Even
after that, the first 70% overlap threshold still failed the documented example
itself (a 4-field rename of 2 fields is exactly 50%) - corrected to 50%, derived
from the example's own real numbers.
Verified: 18 assertions against the real layoutMappingsService/useLayoutMapping
(hard gates, the corrected per-field overlap, real PocketBase ownership/sharing
rules, stale-mapping decline/accept, no-match reporting); the real rebuilt
container's /api/process response now carries the fixed field_labels shape;
measure.py byte-identical throughout; npm run build passes.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Lays the backend groundwork for the layout mapper (no UI/PocketBase yet): when both
the keyword detector and the layout_quirks fallback fail on every page,
extraction_service.run() now raises LayoutMappingRequired with a computed fingerprint
instead of a dead-end error; routes/extraction.py returns this as a 422 with
{needs_mapping, fingerprint, fingerprintHash}. run()/pipeline_service.run() gained a
forced_mapping parameter that extracts directly from given column positions, bypassing
auto-detection entirely - the entry point a future manual mapping screen will use.
Two real gaps surfaced by testing against the actual problem statement, not assumed:
header_candidate_geometry() scans every page for the best candidate rather than just
page 1 (this statement's own page 1 is a pure cover page); a forced mapping had no
page-boundary concept, so a cover page's own letterhead merged into the first real
transaction - fixed with a new start_page field.
Verified: a synthetic unrecognizable PDF correctly triggers the 422 contract through
the real running container; the real problem statement, forced through a hand-built
mapping, now extracts 36/36 transactions with every check passing, matching the
auto-detected L.1 result exactly; measure.py byte-identical on HSBC/RBC throughout.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
L.1 of the layout-mapper plan (docs at /Users/jason/.claude/plans/witty-inventing-walrus.md):
a new backend/services/extraction/layout_quirks.py runs as a zero-friction fallback after
the keyword/geometry header detector fails, fixing mechanical geometric oddities (here, a
header label wrapped across physical lines) without requiring a manual mapping step. Also
generalizes money-token recognition to accept a leading "$" and date recognition to accept
an unambiguous YYYY/MM/DD shape - both real gaps surfaced by the same new statement once its
header was fixed. Relocates table_extract.py's private header-matching helpers into
layout_rules.py as public functions to avoid a circular import with the new module.
Verified: measure.py byte-identical on HSBC/RBC (every change is a provable no-op there);
the real statement that prompted this now extracts 36/36 transactions through the live
container with statement_balance/running_balance/date_sanity/structure_sanity all passing,
every row spot-checked against the source PDF; the existing scanned-statement OCR fixture
re-verified with zero regression.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Completes the R.1-R.5 review screen plan. editLog/acknowledgedFlags/accepted all
live on the existing result JSON blob, no new PocketBase migration needed. Every
row mutation (manual edit, suggested-fix apply, structural edits) now logs a
field-level edit log entry; flags can be individually acknowledged; a document
can be Accepted once Verified or fully acknowledged; exports gain an optional
Edits sheet when edit_log is non-empty.
Verified: measure.py byte-identical to the pre-R.5 baseline, real curl round trip
through the rebuilt container confirming the Edits sheet appears/omits correctly,
extractionStore's new getters/actions run directly against real Pinia, and
useRowEditing's edit-log capture confirmed against a document actually persisted
on the live PocketBase container.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
New backend/services/suggested_fixes_service.py, wired into
pipeline_service.py's run()/recheck() (both now return a suggestions
list alongside status/checks - no new endpoint needed).
Three patterns, tried in order so a row already explained by a sign
flip isn't also offered a digit-level fix: debit/credit swapped,
transposed digits, OCR digit misread. Each is tested empirically -
apply the candidate value to a copy of the real transactions and
re-run the actual check_running_balance - rather than hand-derived
from that check's own bridging/direction math, which is both safer
and simpler than tracing which row a bridged, auto-direction-detected
mismatch is "really" about.
"Date format swapped" was investigated and found not to apply to this
pipeline's data at all, documented directly in the new module's own
docstring rather than silently skipped: by the time a transaction
reaches this module its date is already normalized to "DD Mon YYYY"
(month already a name, not a number), so the raw numeric day/month
ambiguity that pattern addresses was already resolved upstream at
extraction time.
A real bug, found by the first end-to-end test and not by reading the
code: the running-balance check's own bridging logic means a mismatch
recorded at row i can be caused by row i or row i-1's amount - the
backend already tried both as fix candidates, but the frontend matched
a suggestion to a row by the fix target's own index, while the flag
icon only ever appears on the row the mismatch itself is reported
against. Confirmed for real: corrupting row 5 surfaced the mismatch on
row 6, so the correct suggestion (fix row 5) was completely unreachable
from the UI. Fixed by adding flag_index (the row shown flagged)
alongside index (the row the fix applies to) - TransactionRow.vue now
looks up by flag_index and always applies to suggestion.index.
TransactionRow.vue's suggestion UI lives in R.2's same flag-detail
panel; "Apply fix" runs the same save->persist->recheck pipeline a
manual edit already uses. extractionStore.applyCheckResults now
re-applies suggestions on every recheck, not just once, so a stale one
a manual edit already resolved disappears on its own.
Verified: three corruption patterns run through the real container via
curl against a known-good fixture, each detected and correctly
reverse-fixed at the right index. The real HSBC-Aug Cancelled-wire
mismatch (a genuine non-error case) correctly produces zero
suggestions. The full apply->persist->recheck->restore round trip
executed directly against real Pinia plus the real running PocketBase,
confirming the persisted record (not just local state) reflects the
fix. measure.py unaffected.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
R.1 (backend half) of the staged review-screen plan (Phase 2). Every
transaction now carries source_page/source_bbox - purely additive, so
the frontend's upcoming pdf.js viewer can box the exact printed row a
flagged transaction came from.
Traced extraction_service.py first: the canonical transactions list for
a normal text PDF always comes from pdfplumber (table_extract.py);
Docling's own extract_transactions() only feeds the cross-check
confidence signal, never the returned data. So this only needed to
touch table_extract.py and raw_ocr_extract.py (the OCR pixel-position
fallback), zero changes to engine-selection/cross-check logic.
One shared helper, table_extract._line_bbox(), used by both files
(mirrors how raw_ocr_extract.py already reuses _classify_money/_REF_RE
rather than re-implementing them) instead of two separate
implementations that could drift apart. A new _union_bbox() grows a
transaction's box as narrative lines merge into it, both the trailing
direction (HSBC) and leading direction (RBC).
Docling's own OCR-table-structure path doesn't get a real bbox (a
synthetic row-index, not a pixel position) - those transactions get
source_bbox: null, a graceful no-highlight rather than an error.
Verified: measure.py run before/after, byte-identical pass rate and
field accuracy on all three fixtures. A real /api/process call against
both HSBC and RBC fixtures confirmed every existing field unchanged.
Then the check measure.py can't make at all: rendered both fixtures'
pages for real and drew the reported source_bbox on the actual page
image - every box landed on exactly the right printed row, including
HSBC's trailing-narrative merge correctly widening the box.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The actual request was simple (store exports in R2 like source files,
pending a retention-duration decision), but investigating where
exports were written surfaced something worse: /api/process built and
saved a full workbook to disk on EVERY extraction, and nothing in the
frontend ever called /api/download/<filename> to retrieve it (confirmed
by grep - no reference anywhere). Every extraction was silently
orphaning an .xlsx file for no reason; 91 had already accumulated
locally from this session's own testing alone.
Removed the dead work entirely: /api/process no longer builds or saves
a workbook at all. /api/download/<filename>, file_repository.
save_workbook/resolve_output_path, and OUTPUT_FOLDER (env var, volume,
directory) are all gone - confirmed nothing else referenced any of
them before removing. outputs/ deleted, including its 91 accumulated
files.
/api/export (the only path actually used - Download Excel/All) now
builds the workbook into an in-memory BytesIO and streams it straight
from there - never touches disk, not even temporarily. The frontend
persists it long-term instead: documentsService.saveExportFile uploads
the same Blob the browser download already used to a new exportFile
field (pb_migrations/3_add_export_file.js), stored in R2 same as
sourceFile. Overwrites the previous export rather than keeping a
history - no retention policy has been decided yet, and keeping every
version would just relocate the same unbounded-growth problem from the
VPS to R2 instead of fixing it. Best-effort from ResultCard.vue - a
save failure is reported but never blocks the browser download itself.
Verified for real: /api/process's response no longer has `filename`
(title still does); /api/export still streams a valid, correctly-typed
.xlsx; /app/outputs no longer exists in the rebuilt container; the old
/api/download URL now falls through to the ordinary SPA catch-all, not
a leftover route. documentsService.saveExportFile run against the REAL
bytes /api/export produced, fetched back through the R2-backed URL,
confirmed byte-for-byte - and confirmed a second export overwrites
rather than creating a second record. measure.py unaffected; npm run
build passes.
RBC prints "Account Fees: $48.75" directly under "Closing balance" on
the statement's last page - not a money token this module recognizes
("$48.75", not "48.75"), no reference-number prefix, no page-number
pattern, so it fell through to plain narrative text and landed on the
last real transaction's description via the trailing-leftover-buffer
rule (correct behavior for a GENUINE trailing narrative line, wrong
for this one).
Fixed by treating the closing-balance line as a position-based
boundary, the same way the header row already is: once extract_page()
recognizes it, every subsequent line on that page is skipped outright
rather than reaching money/narrative classification at all. A no-op
for HSBC, which never emits a closing_balance row in the first place.
measure.py: RBC field accuracy 0.9977 -> 1.0, HSBC unaffected. RBC's
overall status is still "Failed" after this - a separate, pre-existing
engine_agreement disagreement on page 4, not touched by this fix.
Rebuilds templates/index.html (896 lines of vanilla JS, no framework, no
build step) as frontend/, a Vue 3 app per ENTERPRISE_STANDARDS.md's
frontend layering (views -> components -> composables -> services ->
repositories, Pinia for stores) - same agreed scope as Stage 1 (backend):
structure + commenting, not the full SaaS-shaped doc.
The full original file was read in full before starting (every function
enumerated against the plan, not re-derived from memory) to make sure
nothing documented in CLAUDE.md's "Frontend / UI state" section got
simplified away: sticky side-by-side layout with a draggable resizer,
Hide/Show Source Doc, collapsible Result card, per-row pencil-to-edit,
comma-formatted numbers, localStorage persistence with a restore banner,
image zoom controls, the pencil-icon-color and description-autogrow
fixes from earlier this session.
The original ask that started this whole detour - processing-phase text
with an animated ellipsis during /api/process - lands here as the one
genuinely new feature (useProcessingPhases.js + ProcessingIndicator.vue),
honestly simulated rather than claiming real progress (the backend is
one synchronous request with no streaming signal).
backend/app.py now serves frontend/dist (built via a new Dockerfile
multi-stage build: a node stage runs npm ci && npm run build, the Python
stage copies backend/ + that dist/ output) instead of rendering a Jinja
template - a manual SPA-fallback route serves a real static asset if one
exists at the requested path, else index.html. One real bug caught and
fixed before this ever ran: the first version also left Flask's own
automatic static route enabled, registering a duplicate/conflicting rule
against the same /<path:...> pattern as the manual catch-all - fixed by
disabling Flask's own static handling (static_folder=None) entirely.
Verified without a browser (the extension could not connect, tried
repeatedly): npm run build succeeds, formatService.js's pure functions
tested directly in Node, every prop/emit/store reference cross-checked
by hand across all ~20 new files, and full regression through the real
Docker container (SPA serving, static assets, /health, /api/* routing,
dual-engine extraction, measure.py - all unaffected or identical to
baseline). Actual interactive behavior - upload, drag/drop, the
processing-phase animation, editing, zoom, the resizer, persistence/
restore, download - was verified by the user in their own browser, not
by Claude. templates/index.html was kept in place as a fallback until
that confirmation came back, then deleted.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
ocr_only detection only matched page_reports status "ocr_only", not
"ocr_raw_words" - if every page of a recheck needed the per-page
raw-OCR-words fallback (Docling failed on all of them), this incorrectly
treated the recheck as non-OCR-sourced, letting it reach "Verified" when
there was no second engine to earn that on. Now checks membership in
("ocr_only", "ocr_raw_words").
Verified directly (not just via measure.py, which never exercises
recheck()): an all-ocr_raw_words page_reports now correctly surfaces the
ocr_source check and stays below Verified; a mixed ocr_only/ocr_raw_words
case does the same; a normal dual-engine case is unaffected - confirmed
both as a direct function call and through /api/recheck on the real
running app. measure.py confirms zero regression elsewhere.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Three small UI fixes from earlier testing, never committed:
- Pencil edit icon now uses the same blue accent token the Save button
already does (.row-btn.edit), instead of the default muted gray.
- Description textarea boxes left stale blank space after hiding the
Source Document panel - the drag-resizer already re-measures box
height on resize (autoGrowAll()), but the Hide/Show toggle never did,
so widening the transactions column left every description box at its
old height until something else happened to trigger a re-measure.
Added the missing call.
- Images shown in the Source Document panel had no zoom controls at all
(unlike PDFs, which get the browser's native viewer toolbar for free).
Added a dedicated zoomable/scrollable image panel with -/+/Fit
controls, width-based zoom (not CSS transform, so the panel's
overflow:auto actually produces real scrollbars when zoomed in),
opening at fit-width by default.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>