feat(ui): manual-first OCR workflow — remove full-page auto-segmentation

Drawing annotations is now the primary workflow. OCR only runs on
manually drawn regions (guided mode always). Full-page layout detection
and the useExistingAnnotations checkbox are removed entirely.

- OcrTrigger: guided-only, disabled with hint when no annotations exist
- TranscriptionEditView: empty state shows draw-regions instruction,
  OCR trigger moved out of collapsible and shown inline after block list
- i18n: add ocr_trigger_no_annotations, ocr_section_heading,
  transcription_empty_draw_hint; remove ocr_use_existing_annotations keys

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Marcel
2026-04-13 22:24:50 +02:00
parent 669f2f8b98
commit 5afdc37653
6 changed files with 29 additions and 73 deletions

View File

@@ -361,21 +361,18 @@ $effect(() => {
</div>
{#if canRunOcr && onTriggerOcr}
<details class="mt-6">
<summary
class="cursor-pointer font-sans text-xs font-medium text-ink-3 transition-colors hover:text-brand-navy"
>
{m.ocr_rerun_label()}
</summary>
<div class="mt-3 max-w-xs">
<div class="mt-6">
<p class="mb-3 font-sans text-xs font-bold tracking-widest text-ink-3 uppercase">
{m.ocr_section_heading()}
</p>
<div class="max-w-xs">
<OcrTrigger
existingBlockCount={blocks.length}
annotationCount={blocks.length}
blockCount={blocks.length}
storedScriptType={storedScriptType}
onTrigger={onTriggerOcr}
/>
</div>
</details>
</div>
{/if}
</div>
</div>
@@ -395,25 +392,9 @@ $effect(() => {
/>
</svg>
{#if canRunOcr && onTriggerOcr}
<p class="mb-6 max-w-xs text-sm leading-relaxed text-ink-3">
{m.transcription_empty_title()}
</p>
<div class="w-full max-w-xs">
<OcrTrigger
existingBlockCount={0}
storedScriptType={storedScriptType}
onTrigger={onTriggerOcr}
/>
</div>
<p class="mt-4 text-xs text-ink-3">
{m.transcription_empty_desc()}
</p>
{:else}
<p class="max-w-xs text-sm leading-relaxed text-ink-3">
{m.transcription_empty_cta()}
</p>
{/if}
<p class="max-w-xs text-sm leading-relaxed text-ink-3">
{m.transcription_empty_draw_hint()}
</p>
</div>
{/if}