This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Description
Per the IIIF services annex document, there are four ways to include physical dimension metadata:
- embedded in
manifest.json
- as a separate resource, referenced by
manifest.json
- embedded in
info.json
- as a separate resource, referenced by
info.json
The problem is that right now, the ImageView module of Mirador doesn't export the info.json metadata after it is fetched; it just uses the metadata internally to instantiate an instance of OpenSeadragon, and then throws the metadata away. So right now it is impossible to modify this plugin to support options 3) and 4) above without making custom modifications to the Mirador source code.
My solution requires two steps:
- somewhere in that callback function declared on line 540, set a property on
_this (the ImageView object) that exports the value of the infoJson local variable (e.g., _this.currentInfoJson = infoJson;)
- change this line to
var service = _this.currentImg.service || _this.currentInfoJson.service;
I will open a related issue on the Mirador project, and will reference it here.
ProjectMirador/mirador#1378