DEV Community

guo deqing
guo deqing

Posted on

MangaInlay: In-Place AI Manga & Webtoon Translator Without Ugly White Boxes

If you read raw Japanese manga or Korean webtoons in Chrome, most translation extensions slap opaque rectangular boxes over the speech bubbles—covering up sound effects, starburst spikes, and background artwork.

I built MangaInlay (hub.guuguo.top/mangainlay) to handle erasure and typesetting locally on an offscreen HTML5 Canvas, so the translated text blends directly into the original comic page.

MangaInlay Before vs After

How It Works

Instead of sending full-resolution pages back and forth or overlaying clunky DOM boxes:

  1. Compact JSON Only: The backend returns only normalized bubble bounding boxes ([ymin, xmin, ymax, xmax]), orientation (horizontal / vertical), category (dialogue / sfx / sign), and translated text.
  2. Local Offscreen Canvas Inpainting: The Chrome extension samples surrounding bubble colors in-browser, erases only the original lettering inside each bubble lobe, and wraps translated lines to fit the actual bubble contour.
  3. Artwork & SFX Protection:
    • Radial Starbursts: Preserves spiky shout-bubble borders instead of clipping them with rectangles.
    • Tilted Signs & Handwritten SFX: Keeps the original artwork intact and places a perspective-matched parallel note right next to the sign.

Radial Burst and Tilted Sign Protection

  1. Long-Strip Webtoon Streaming: Slices tall webtoons into chunks, runs concurrent translation requests, and streams bubbles onto the page as each slice arrives—with a subtle border pulse instead of a dark blocking overlay.
  2. Scroll & Carousel Sync: Re-tracks image bounds via requestAnimationFrame when readers use horizontal page-turn transitions or scroll through chapters.

Non-Blocking Workflow

Try MangaInlay

You can check out the live demo and grab the extension package directly from the official page:

Top comments (0)