Summary
Guided-navigation cues for comics can carry a panel box, e.g. imgref: "image0001.jpg#xywh=pixel:44,113,757,226". Web reads it and pans/zooms to the panel while the audio plays. iOS and Android ignore it, so they turn the page but always show the whole page.
Where it stands today
| Platform |
Page turn on cue |
Pan/zoom to panel |
| Web |
✅ |
✅ comicRegion → FlutterDivinaNavigator.panToRegion |
| iOS |
✅ |
❌ no xywh parsing anywhere |
| Android |
✅ (after #234) |
❌ no xywh parsing anywhere |
Related defect on iOS
iOS passes the raw imgref through as the item's text reference:
// GuidedNavigationDocument.swift
if let audio = obj.audioref, let text = obj.textref ?? obj.imgref {
FlutterMediaOverlayItem then splits on # and publishes the fragment as a CSS selector:
locator.locations.otherLocations["cssSelector"] = .string("#\(frag!)")
For a panel cue that yields cssSelector: "#xywh=pixel:44,113,757,226" — not a DOM id, and not a valid selector. It reaches Dart on every comic cue. Android avoids this (#234 drops the fragment); iOS still needs it handled, ideally by parsing the box instead of discarding it.
Suggested work
- Parse
#xywh=pixel:x,y,w,h in the iOS and Android guided-navigation item models.
- Carry the box on the cue locator, the way web puts
comicRegion in otherLocations.
- Pan/zoom the native comic navigators to the box, with the same auto-pan and manual-override gating web uses.
- Stop publishing the box as a
cssSelector on iOS.
Web reference: flutter_readium/web/src/mediaoverlay/syncNarration.ts (parseImgField, textLocatorForItem) and _syncDivinaToMediaOverlayLocator in ReadiumReader.ts.
Summary
Guided-navigation cues for comics can carry a panel box, e.g.
imgref: "image0001.jpg#xywh=pixel:44,113,757,226". Web reads it and pans/zooms to the panel while the audio plays. iOS and Android ignore it, so they turn the page but always show the whole page.Where it stands today
comicRegion→FlutterDivinaNavigator.panToRegionxywhparsing anywherexywhparsing anywhereRelated defect on iOS
iOS passes the raw
imgrefthrough as the item's text reference:FlutterMediaOverlayItemthen splits on#and publishes the fragment as a CSS selector:For a panel cue that yields
cssSelector: "#xywh=pixel:44,113,757,226"— not a DOM id, and not a valid selector. It reaches Dart on every comic cue. Android avoids this (#234 drops the fragment); iOS still needs it handled, ideally by parsing the box instead of discarding it.Suggested work
#xywh=pixel:x,y,w,hin the iOS and Android guided-navigation item models.comicRegioninotherLocations.cssSelectoron iOS.Web reference:
flutter_readium/web/src/mediaoverlay/syncNarration.ts(parseImgField,textLocatorForItem) and_syncDivinaToMediaOverlayLocatorinReadiumReader.ts.