npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@projektemacher/tify-plugin-annotorious

v0.2.2

Published

Display-only Annotorious annotations plugin for the TIFY IIIF viewer

Readme

@projektemacher/tify-plugin-annotorious

Note: This code was generated with AI assistance — opencode, powered by GLM (Z.ai).

Display-only Annotorious annotations for the TIFY IIIF viewer: imports xywh annotations from the IIIF manifest and renders them as shapes with a translated list panel.

import { annotoriousPlugin } from '@projektemacher/tify-plugin-annotorious';
import '@projektemacher/tify-plugin-core/style.css';
import '@projektemacher/tify-plugin-annotorious/annotorious.css';

const plugin = await annotoriousPlugin(tify, {
  panelEl: document.querySelector('#panel'),
});

Notes

  • Display-only: drawingEnabled: false plus UserSelectAction.SELECT, so clicks select but never open Annotorious's (English) editor — bodies render in the translated side panel instead.
  • Annotations are imported from the IIIF manifest (xywh fragment targets via W3CImageFormat().parse(), verified: xywh=265,661,1260,1239 → exact rectangle). Whole-canvas targets, SVG selectors and painting annotations are skipped.
  • @annotorious/openseadragon is pinned to ~3.8.10: the 3.9.x line broke canvas-click selection (no clickAnnotation events, so list rows never highlight) — caught by the e2e suite. Re-evaluate on future releases.
  • Shapes are pre-styled for visibility: annotorious paints display shapes on its WebGL canvas (CSS cannot reach them), so the plugin passes a DrawingStyle expression — a resting accent tint per annotation and a heavier accent stroke once selected. See the exported shapeStyle if you want to customize it.
  • Annotorious coordinates are relative to a single base image: in TIFY book view (double-page spread) the second page's annotations are offset into the shared world space (per the page layout), so both facing pages show shapes.

Example

example/ — display-only shapes from IIIF xywh annotations plus a list panel. Run npm run dev at the repo root and open /packages/plugin-annotorious/example/ (defaults to the IIIF cookbook tagging manifest).

Manifest generation

The image side can be any plain image service — generate one with fliiifenleger (generate, --iiif-version V3 recommended):

java -jar cli/target/fliiifenleger-cli.jar generate --iiif-version V3 \
  -o ./my-iiif-images /path/to/image.jpg

The xywh tagging annotations themselves are added afterwards, at the Presentation-manifest level.

Development

npm run build       # dist/ (ESM + declarations)
npm run typecheck
npm run test:i18n   # catalogue coverage for src/ + example/
npm run lint

License: AGPL-3.0-or-later.