Cartographer User and Technical Documentation
Home
User Docs
Technical Docs
Home
User Docs
Technical Docs
  • User Documentation
    • Introduction
    • Cartographer App
    • User Interface
    • Actions
  • Technical Documentation
    • Components

      • AppFooter Component
      • AppHeader Component
      • AppSidebar Component
      • ContentPreviewMdiv Component
      • Content Preview Measure
      • Content Preview Pane
      • ImageSelection Modal
      • LoadGitModal Component
      • LoadIIIFModal Component
      • LoadXMLModal Component
      • MainMenu Component
      • MeasureModal Component
      • MdivModal Component
      • OsdComponent Component
      • PageImportModal Component
      • PagesListEntry Component
      • PagesModal Component
    • Store
      • Vuex Store (src/store/index.js)
    • Tools
      • IIIF Tools (src/tools/iiif.js)
      • MEI Mapping Tools (src/tools/meimapping.js)

OsdComponent Component

Displays the OpenSeadragon image viewer with annotation support for zones and measures.


Overview

The OsdComponent component:

  • Renders an OpenSeadragon viewer for high-resolution images.
  • Integrates Annotorious for drawing and managing annotation zones.
  • Renders overlays for zones, colored by mdiv.
  • Handles selection, creation, update, and hover of annotation zones.
  • Reacts to Vuex store changes for pages, zones, mode, and selection.

Layout

  • Viewer: Main image viewer (#osdContainer), full width or reduced if measure list is visible.
  • Overlays: Annotation zones rendered as overlays with labels.

Props

None


Data

NameTypeDescription
colorsArrayList of RGBA colors for mdiv overlays
colorIndexNumberCurrent color index for assigning colors
mdivColorsObjectMapping of mdiv indices to assigned colors

Computed Properties

NameDescription
imageArrayReturns the array of images from the store
modeReturns the current annotation mode from the store
measureListVisibleWhether the measure list pane is visible

Methods

NameDescription
getNextColorReturns the next color for mdiv overlays
renderZonesRenders annotation overlays for all zones on the current page
toggleSelectionEnables/disables annotation selection based on mode

Lifecycle Hooks

  • mounted: Initializes OpenSeadragon and Annotorious, sets up event listeners, and Vuex watchers.
  • beforeUnmount: Cleans up Vuex watchers.

Example

<OsdComponent />
Prev
MdivModal Component
Next
PageImportModal Component