Commit Graph

2301 Commits

Author SHA1 Message Date
Marcel
52ac6b874e test(person): cover PersonTypeahead branches
Label + asterisk per required, placeholder prop, initialName seeding,
hidden value input, large/compact class branches, listbox initial
hidden, focus opens listbox with restrictToCorrespondentsOf, ARIA
expanded toggle, Escape keypress safe, fetch error/non-ok branches,
FieldLabelBadge presence, autofocus prop.

17 tests covering ~30 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
16f5410c6f test(transcription): cover TranscriptionEditView branches
Empty-state coach, review progress counter, mark-all-reviewed
button visibility/disabled state, OcrTrigger conditional, training
labels visible/hidden by canWrite, label toggle callback, blocks
sorted by sortOrder.

12 tests covering ~30 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
9837d3b502 test(document): cover WhoWhenSection date and location branches
Date invalid state, error visibility before/after input, hidden ISO
output, location with initialLocation, location hidden in editMode,
FieldLabelBadge in editMode, required indicator.

7 tests covering ~10 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
0d3b5cda7e test(routes): expand documents page coverage
Adds bulk-edit-all click → backend error code branch, fetch throw
fallback message, data.error pass-through to DocumentList, sort/dir
defaults, OR tag operator branch, zoom range pass-through.

7 new tests targeting ~14 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
7206439cec test(admin): expand EntityNav coverage
Active-section icon coloring, flyout trigger click, Escape key
handler on document, user/invite count badge rendering.

5 new tests covering ~10 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
99ca003f66 test(viewer): expand usePdfRenderer state coverage
Adds renderCurrentPage no-op when pdfjsLib uninitialized, prerender
no-op when pdfDoc null, destroy safe without document, setElements
no-throw, isLoaded false initially, accumulating zoomIn calls.

7 new tests covering ~10 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
0f9ffc4c39 test(admin): expand admin/system page coverage
Adds backfill-versions and backfill-file-hashes click handlers,
verifies initial fetch hits import-status and thumbnail-status.

3 new tests targeting ~10 branches in the page component.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
a93034a8d7 test(discussion): expand CommentThread coverage
Adds onCountChange-after-reload (loadOnMount=true), null currentUserId
isOwn behavior, replies flattened in display.

3 new tests covering ~10 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
c9a14b6e90 test(genealogy): cover StammbaumSidePanel branches
Heading from displayName, birth/death years rendering with all
branch combinations, close button, Escape keypress closing,
non-Escape ignored, person detail link, empty placeholder, error
banner on fetch failure, AddRelationshipForm visibility toggle.

12 tests covering ~25 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
f9b62982f6 test(viewer): cover PdfViewer empty and loaded state branches
Empty state when url is empty (no controls, placeholder shown),
loaded state with controls, annotationsDimmed branch, transcribeMode
flag, documentFileHash filtering branch.

6 tests covering ~10 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
8a22eeaa16 test(annotation): add full pointer-drag cycles for AnnotationEditOverlay
Adds full drag cycles (down + move + up) for all 8 handles, full
move-area cycle, non-primary pointermove and pointerup ignored,
no-movement pointerup early-return path.

12 new tests covering ~24 additional branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
dc4169fb90 test(documents): expand documents/[id] page coverage
Adds doc.title in document title, originalFilename fallback,
'Dokument' default fallback, canWrite=true render, geschichten +
inferredRelationship rendering, doc.id empty handling, task=transcribe
URL parameter render.

7 new tests targeting ~25 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
fd83a62a1c test(routes): expand documents page coverage
Adds canWrite=false hides bulk-edit and new-doc CTAs, no-results
empty state, populated document list, q from server, render-without-
throwing for date / tag / sender filters preselected.

7 new tests targeting ~15 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
6d45aaadf8 test(persons): expand persons/[id] page coverage
Co-correspondents derived from received-document senders, self-skip
branch when sender == current person, GeschichtenCard rendered when
geschichten array is non-empty, 5-entry cap on co-correspondents.

4 new tests covering ~10 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
87c7b2f58d test(routes): expand AppNav coverage for active links and mobile overlay
Active-link styling per pathname (documents, persons, stammbaum,
geschichten, admin), mobile backdrop click closes nav, Escape
keypress on overlay closes nav.

7 new tests targeting ~14 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
a25408d4d7 test(routes): expand aktivitaeten page coverage
loadError branches (FuerDichBox skipped vs shown), first-run vs
filter-empty empty-state variants, timeline rendering when feed
has items, FilterPills + FuerDichBox conditional render.

7 tests covering ~12 branches in the page file.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
0926545fc4 test(routes): expand home page coverage
Adds reader stats rendering and reader grid layout when isReader=true.

2 new tests targeting reader-mode branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
70c2dc22cf test(briefwechsel): cover ConversationFilterBar branches
Two persontypeaheads + two date inputs, swap button visible/invisible
based on both persons set, sort label DESC vs ASC, chevron rotation,
onapplyFilters / ontoggleSort / onswapPersons callbacks fire.

11 tests covering ~20 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
78c01d4561 test(genealogy): expand StammbaumCard coverage
Adds direct-relationship sorting, yearRange formatting (both years,
only fromYear), inferred-relationships disclosure rendering, 5-item
cap on derived relationships.

5 new tests targeting ~15 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
6bb520f822 test(routes): expand register coverage for password and form branches
Adds password show/hide toggle (independent for both fields), pwHint
visible after typing, pwValid green hint for 8+ chars, pwMismatch
red hint, pwMatch green hint, form.error rendering, notifyOnMention
checkbox toggle.

7 new tests targeting ~25 branches in the register flow.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
d1aa0dc9f0 test(discussion): cover CommentThread branches
Empty hint, populated comment list, singular vs plural label,
canComment toggle, showCompose flag with empty/non-empty messages,
quotedText pre-fills textarea, onCountChange on mount, URL routing
for annotation/block/document comment endpoints.

12 tests covering ~25 branches in CommentThread.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
6b4a5ba0da test(discussion): cover MentionEditor branches
Textarea props (placeholder, rows, disabled), popup not shown
initially, popup opens on @ + query, empty results from API,
HTTP error → empty popup, Enter submits when popup closed,
Shift+Enter does not submit, Escape closes popup, Arrow{Up,Down}
navigation, Enter with no results.

12 tests covering ~30 branches in MentionEditor.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
7fae13ff4e test(annotation): expand AnnotationLayer coverage
Container style branches (cursor with/without canDraw, touch-action),
drawing pointer flow (canDraw=false skips, pointerdown on existing
annotation skips, no preview when not drawing, pointermove without
draw, pointerup without draw).

7 new tests, +14 covered branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
1bcce359e1 test(routes): expand DropZone coverage for drag/drop branches
Adds drag-over and drag-leave styling, drop with no files, multiple
invalid files, mixed valid+invalid files, non-Enter keydown ignore,
window-level dragenter/dragleave with and without 'Files' types,
counter underflow guard.

16 tests, +9 covered branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
41a42c77bb test(annotation): expand AnnotationEditOverlay coverage
Adds keyboard navigation (Arrow{Up,Down,Left,Right}, shiftKey step,
non-arrow no-op, edge clamping at all four sides), pointer drag
flows (move-area + each of the 8 handles), early-return branches
for non-primary pointers and pointer events without active drag.

28 tests, +20 covered branches over previous 7-test version.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
ac43ef2243 test(activity): cover ChronikEmptyState branches
Three variants (first-run, filter-empty, inbox-zero), title vs body
visibility, data-variant attribute, accent vs ink-3 icon coloring.

5 tests, ~15 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
23bae62248 test(activity): cover DashboardActivityFeed branches
Caption + show-all link, empty/non-empty conditional, actor avatar
vs question-mark fallback, rollup count badge presence, youMentioned
badge, verbMap entries (TEXT_SAVED, FILE_UPLOADED), unknown-kind
fallback, rollup time range, actor name vs initials fallback,
document href construction.

13 tests, ~50 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
c0d0638f2b test(activity): cover ChronikFuerDichBox branches
Inbox-zero state, count badge, MENTION vs REPLY glyphs and verbs,
onMarkRead callback per dismiss, onMarkAllRead callback, comment
deep-link href construction.

8 tests, ~30 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
22e4b98229 test(activity): cover ChronikFilterPills branches
Radiogroup with label, all five filter pills, aria-checked for active
filter, tabindex matrix (0 active vs -1 inactive), onChange callback
when clicked.

5 tests, ~15 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
a8577fabc4 test(activity): cover ChronikErrorCard and ChronikTimeline
ChronikErrorCard: default vs supplied message, retry callback wiring,
role=alert.

ChronikTimeline: empty render, today bucket grouping, older bucket
grouping, multi-bucket grouping when items span time ranges.

8 tests, ~20 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
cd26296969 test(dashboard): cover DashboardResumeStrip branches
Empty card vs populated strip, title rendering, thumbnail image vs
fallback icon, progress bar aria-valuenow, document detail link,
collaborators stack rendering, safeColor fallback to default when hex
invalid.

9 tests covering ~25 of DashboardResumeStrip's branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
c42585d5d8 test(dashboard): cover ReaderDraftsModule branches
Heading, empty placeholder, per-draft row rendering, draft edit link
href, meta line with relative time.

5 tests, ~10 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
84c9cdab2f test(dashboard): cover ReaderRecentDocs branches
Heading + all-docs link, New badge gated on createdAt == updatedAt,
sender displayName vs lastName fallback vs em-dash, document detail
link.

8 tests covering ~16 of the recent-docs section's branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
2f700f80f7 test(dashboard): cover ReaderHeaderBar and ReaderRecentStories
ReaderHeaderBar: time-of-day greeting matrix (Morgen/Mittag/Abend),
welcome with name, stats counts, em-dash for null counts, three
section links.

ReaderRecentStories: empty early return, populated story rows, all-
stories link, story-detail link, body excerpt visibility.

12 tests, ~30 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
8e6bce7d01 test(transcription): cover TranscriptionColumn branches
Empty placeholder, heading + per-doc rendering, weekly-pulse visibility
gated on weeklyCount > 0, block-progress label vs em-dash branch,
task=transcribe link, missing-documentDate handling.

8 tests, ~20 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
2beead7b71 test(routes): cover DocumentList branches
Empty state (default + term-specific), error banner, year groups
default sort, sender-group sort, undated/unknown-sender labels, total
count display. Mocks $app/navigation since the empty-state CTA calls
goto.

8 tests covering ~30 of DocumentList's branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
37726a8585 test(ocr): cover TrainingHistory branches
Empty placeholder, all four status pill branches (QUEUED/DONE/FAILED/
RUNNING), error-detail disclosure on FAILED, Personalisiert vs Basis
type label, COLLAPSED_COUNT visible runs, person columns visibility
toggle, em-dash CER fallback.

11 tests covering ~25 of TrainingHistory's branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
a08d537fd6 test(dashboard): cover ReaderPersonChips branches
Section landmark with aria-label, empty placeholder, per-person chip
with link to detail, document-count chip visibility branch, displayName
vs lastName fallback, all-persons footer link.

7 tests, ~16 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
63f1155966 test(dashboard): cover DashboardRecentDocuments branches
Empty list early return, heading + per-doc row rendering, title link
href, date visibility tied to updatedAt, stats footnote presence
toggled by stats.totalDocuments.

7 tests covering ~16 of the dashboard section's branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
a47fe9fbce test(discussion): cover CommentMessage branches
Author + initials, comment body, edited label gated on updatedAt vs
createdAt, edit-mode textarea, delete button gated on isOwn, onDelete
callback wiring.

8 tests covering ~16 of CommentMessage's branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
5564d397e7 test(geschichte): cover GeschichtenCard branches
Empty list early return, populated section, write-action link gated on
canWrite, visible-cap of 3, footer show-all link visibility based on
overflow, author name vs email fallback.

9 tests covering ~25 of GeschichtenCard's branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
36c08fed61 test(shared/primitives): cover Pagination branches
Hidden when totalPages <= 1, prev/next disabled state matrix at
boundaries, link form when in range, aria-current for active page,
mobile page label, left ellipsis / right ellipsis branches based on
window position, custom ariaLabel.

11 tests covering ~30 of Pagination's branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
1f63267193 test(activity): cover ChronikRow variant + kind branches
Avatar with initials vs question-mark fallback, for-you marker
visibility, data-variant matrix (simple/for-you/rollup/comment),
count badge for rollup, comment preview rendering with fallback,
document title link, default vs comment-deep-link href, time-range
label for rollup with happenedAtUntil.

11 tests covering ~40 of ChronikRow's high-uncovered branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
b1ea7d0916 test(document): cover DocumentRow branches
Title rendering with originalFilename fallback, sender vs unknown
placeholder, tag buttons per document tag, bulk-select checkbox gated
on canWrite, archive chips visibility, snippet/summary visibility,
em-dash for missing date.

11 tests covering ~30 of the row's branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
15a3f41765 test(person/relationship): cover AddRelationshipForm branches
Toggle button, form open on click, all relationship type options,
year-error alert when toYear < fromYear, no-error path when equal,
cancel button closes form, onSubmit prop wiring.

7 tests covering ~20 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
d1e07d376f test(person/genealogy): cover StammbaumCard branches
Heading, family-member toggle visibility tied to canWrite, aria-checked
matrix, in-tree banner gating, relationship-error alert, empty
placeholder, no-derived-relationships path, AddRelationshipForm
mounting tied to canWrite.

10 tests covering ~25 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
103b907f2a test(document): cover FileSwitcherStrip branches
Prev/next nav buttons, chip count per file, aria-current matrix for
active id, error-state data attribute, onSelect callback, onRemove
callback, sr-only announcer for active title.

7 tests covering ~25 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
f2192806cd test(routes): cover DropZone branches
Drop hint + accepted types render, default no-progress state, invalid
MIME-type rejection, valid PDF acceptance, no-files early return,
click + Enter open the file input, multi-file accept whitelist
attributes.

8 tests covering ~25 of DropZone's 46 branches.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
4b223df330 test(admin/tags): cover the tag-edit page branches
Heading with tag name, name input hydration, color picker visible only
for top-level tags, color swatch grid (10 entries), aria-pressed for
active color, success banner branch, error banner branch, merge-success
banner branch.

8 tests covering ~30 branches in the tag-edit page.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00
Marcel
f684ba3a61 test(documents): smoke-cover the new document page
Renders BulkDocumentEditLayout with prop pass-through and an
empty-values branch.

Refs #496.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:50:28 +02:00