@nulib/clover 4.5.6 → 4.5.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (243) hide show
  1. package/dist/components/Items/Items.mjs +10 -3
  2. package/dist/styles/default.css +1 -1
  3. package/dist/styles/items.css +1 -1
  4. package/dist/styles.css +1 -1
  5. package/dist/templates/default/Default.mjs +62 -15
  6. package/dist/templates/index.d.mts +3 -1
  7. package/dist/ui/useRovingFocus.mjs +6 -3
  8. package/dist/ui/useScrollTrack.mjs +9 -9
  9. package/dist/web-components/{About-C-o1MARK.mjs → About-CVX3WjIM.mjs} +1 -1
  10. package/dist/web-components/{AnnotationItems-BtX1-AkD.mjs → AnnotationItems-DKP8AOB9.mjs} +1 -1
  11. package/dist/web-components/{AnnotationMenu-eXo5QJ9p.mjs → AnnotationMenu-DS8hpHt_.mjs} +1 -1
  12. package/dist/web-components/{AnnotationState-B4-vsjYK.mjs → AnnotationState-C6XuLyjK.mjs} +1 -1
  13. package/dist/web-components/{Annotations-KJI1g3JX.mjs → Annotations-C6jdThgl.mjs} +1 -1
  14. package/dist/web-components/{Annotations-BMMp4TzW.mjs → Annotations-DZ0uCsSA.mjs} +1 -1
  15. package/dist/web-components/{Body-Bx9aZhz_.mjs → Body-BSgaX-3F.mjs} +1 -1
  16. package/dist/web-components/{BodyAlert-01XtjU91.mjs → BodyAlert-B4aQaIUq.mjs} +1 -1
  17. package/dist/web-components/{Button-DmqdooHe.mjs → Button-DjjrKoEn.mjs} +1 -1
  18. package/dist/web-components/{Camera-ZgGejDUV.mjs → Camera-BEeXRxzV.mjs} +1 -1
  19. package/dist/web-components/{Canvas2DBackend-B1YLZdY_.mjs → Canvas2DBackend-nJRJutaS.mjs} +1 -1
  20. package/dist/web-components/{CanvasView-BRtiqo9o.mjs → CanvasView-DK0lfyWR.mjs} +2 -2
  21. package/dist/web-components/{CaptionDetails-JtN_s8Vd.mjs → CaptionDetails-ljenvCyI.mjs} +1 -1
  22. package/dist/web-components/{ChaptersMenu-nW6su_V2.mjs → ChaptersMenu-DDgnLAtO.mjs} +1 -1
  23. package/dist/web-components/{Chevron-C6B1ERz3.mjs → Chevron-JoTeVk7K.mjs} +1 -1
  24. package/dist/web-components/{ChoiceMenu-Ep3PVmNU.mjs → ChoiceMenu-82jUcgr6.mjs} +1 -1
  25. package/dist/web-components/{Collection-IHIeRtAZ.mjs → Collection-JI80uk-a.mjs} +1 -1
  26. package/dist/web-components/{CollectionSelect-CFak4aY5.mjs → CollectionSelect-CxOlBjmO.mjs} +1 -1
  27. package/dist/web-components/Connected-Bur9iAGb.mjs +1 -0
  28. package/dist/web-components/{Connected-DBFLtGSX.mjs → Connected-CC10s8oE.mjs} +1 -1
  29. package/dist/web-components/Connected-DTYB8ubW.mjs +1 -0
  30. package/dist/web-components/{Contents-H1p0ziCX.mjs → Contents-cwsn0zpJ.mjs} +1 -1
  31. package/dist/web-components/{ControlMenu-Dzc3r70f.mjs → ControlMenu-BBBRHutV.mjs} +1 -1
  32. package/dist/web-components/ControlsFade-DNHDI2WA.mjs +1 -0
  33. package/dist/web-components/{CountMenu-CVXxogQn.mjs → CountMenu-DFOUdzB0.mjs} +1 -1
  34. package/dist/web-components/Cue-C2a4Pvi3.mjs +1 -0
  35. package/dist/web-components/{Document-Bq69tdp9.mjs → Document-CKJYtix1.mjs} +1 -1
  36. package/dist/web-components/{DomLayers-BNFCWPIf.mjs → DomLayers-vrvJUN5_.mjs} +1 -1
  37. package/dist/web-components/{Download-8s_1j0hn.mjs → Download-CQX7fDub.mjs} +1 -1
  38. package/dist/web-components/{EntryBodies-CuH57Wdm.mjs → EntryBodies-BvHccb-L.mjs} +1 -1
  39. package/dist/web-components/{EntryThumbnail-BBn3c02-.mjs → EntryThumbnail-YuRsScmh.mjs} +1 -1
  40. package/dist/web-components/{FieldPill-CDDBQn83.mjs → FieldPill-D8JBm03i.mjs} +1 -1
  41. package/dist/web-components/{FrameAnimation-OBaRI-rP.mjs → FrameAnimation-DJRLNImC.mjs} +1 -1
  42. package/dist/web-components/{Gallery-BY4cH76P.mjs → Gallery-BH4b0bkJ.mjs} +1 -1
  43. package/dist/web-components/{GlobeGlyph-DgNI--BA.mjs → GlobeGlyph-DU4HgIlU.mjs} +1 -1
  44. package/dist/web-components/{HideToggle-CQcp5w_t.mjs → HideToggle-C5GjtOeD.mjs} +1 -1
  45. package/dist/web-components/{ImageControls-DREK-1SC.mjs → ImageControls-D4NriMaR.mjs} +1 -1
  46. package/dist/web-components/Items-V4WBXxYO.mjs +1 -0
  47. package/dist/web-components/{Label-Cur5KZAJ.mjs → Label-AzCladKz.mjs} +1 -1
  48. package/dist/web-components/{LanguageChoice-BWmkORxS.mjs → LanguageChoice-BjOVXoTc.mjs} +1 -1
  49. package/dist/web-components/{LanguageMenu-CW1_hI1x.mjs → LanguageMenu-DYKPJWTQ.mjs} +1 -1
  50. package/dist/web-components/{LightboxView-Cd92FAYV.mjs → LightboxView-BTtyMjPN.mjs} +1 -1
  51. package/dist/web-components/{ListEnd-CefIIerg.mjs → ListEnd-Dp2ZLTtS.mjs} +1 -1
  52. package/dist/web-components/{Loaded-DtzpCxju.mjs → Loaded-B_afJf30.mjs} +1 -1
  53. package/dist/web-components/{LoadedCanvas-CUrQv2k_.mjs → LoadedCanvas-DisvEU6k.mjs} +1 -1
  54. package/dist/web-components/LoadedMap-DCMWMk1e.mjs +1 -0
  55. package/dist/web-components/{Loading-DhTFaFBg.mjs → Loading-BXzghLiL.mjs} +1 -1
  56. package/dist/web-components/{Map-eb1aK0Z9.mjs → Map-Sr8lEkIx.mjs} +1 -1
  57. package/dist/web-components/{MapView-3j8gkLYi.mjs → MapView-Cyuq8ZjK.mjs} +2 -2
  58. package/dist/web-components/{Markup-Dy6leTBV.mjs → Markup-D_j5vPvk.mjs} +1 -1
  59. package/dist/web-components/{MediaBody-Dg0-LWYL.mjs → MediaBody-BFkIoL-g.mjs} +1 -1
  60. package/dist/web-components/{MediaBody-DMrJQG34.mjs → MediaBody-DRkphCAw.mjs} +1 -1
  61. package/dist/web-components/{NavDate-Ck30M1Ve.mjs → NavDate-DWIV5F6P.mjs} +1 -1
  62. package/dist/web-components/{Navigator-B9rs7wKo.mjs → Navigator-R3SCVscB.mjs} +1 -1
  63. package/dist/web-components/{Pager-BV2GC__-.mjs → Pager-D6slnuet.mjs} +1 -1
  64. package/dist/web-components/{PagerLayout-Cd08Alpt.mjs → PagerLayout-B-a-Bj7s.mjs} +1 -1
  65. package/dist/web-components/{Panel-DR6ycHyX.mjs → Panel-CuGSpuMG.mjs} +1 -1
  66. package/dist/web-components/PanelPart-C5T9XPgt.mjs +1 -0
  67. package/dist/web-components/{PanelToggle-gAffLvlc.mjs → PanelToggle-DGi2sN1Y.mjs} +1 -1
  68. package/dist/web-components/{PartOfManifest-nziNto_q.mjs → PartOfManifest-dHMlHOeZ.mjs} +1 -1
  69. package/dist/web-components/{Pending-D1rYOP_R.mjs → Pending-DqTfvy6z.mjs} +1 -1
  70. package/dist/web-components/{PlaceBox-C2JMFQV0.mjs → PlaceBox-DW79A9P1.mjs} +1 -1
  71. package/dist/web-components/{Placeholder-BDMLULRp.mjs → Placeholder-D2xzRHzw.mjs} +1 -1
  72. package/dist/web-components/{Position-IRJVIQdA.mjs → Position-CZxedOcV.mjs} +1 -1
  73. package/dist/web-components/{Primitives-DqRNtE60.mjs → Primitives-DjUlp4ln.mjs} +1 -1
  74. package/dist/web-components/{Provider-DPSj538n.mjs → Provider-BhDLDrIb.mjs} +1 -1
  75. package/dist/web-components/{ReadMore-B2DB6MuP.mjs → ReadMore-l-ljjCbA.mjs} +1 -1
  76. package/dist/web-components/{Root-DCA1d0D7.mjs → Root-DdfxetNr.mjs} +1 -1
  77. package/dist/web-components/Scene-CoKy2-jQ.mjs +1 -0
  78. package/dist/web-components/{SceneView-YtkAJ2zP.mjs → SceneView-C-5ZBOMj.mjs} +1 -1
  79. package/dist/web-components/{Search-FWPa5UNO.mjs → Search-DvSuOWsf.mjs} +1 -1
  80. package/dist/web-components/{Sections-73lsQFnt.mjs → Sections-WeQ6ifoH.mjs} +1 -1
  81. package/dist/web-components/{SeekMarks-DLT93mL0.mjs → SeekMarks-CnV7psCC.mjs} +1 -1
  82. package/dist/web-components/{StandaloneItems-5d_3l6hK.mjs → StandaloneItems-BrGYircX.mjs} +1 -1
  83. package/dist/web-components/{Status-6tfWoLV_.mjs → Status-CjAX4ZcY.mjs} +1 -1
  84. package/dist/web-components/{Steps-DINk164Y.mjs → Steps-WGighDCr.mjs} +1 -1
  85. package/dist/web-components/{TargetItems-CouPOIsE.mjs → TargetItems-CHK11XsC.mjs} +1 -1
  86. package/dist/web-components/Timeline-CylMxHCg.mjs +1 -0
  87. package/dist/web-components/{Tip-CmrY2ZoP.mjs → Tip-MXBlEQhp.mjs} +1 -1
  88. package/dist/web-components/{Transcript-D-J5T_7K.mjs → Transcript-BdmTrR_U.mjs} +1 -1
  89. package/dist/web-components/{Transport-Cy7wwjA5.mjs → Transport-B4jS-QyR.mjs} +1 -1
  90. package/dist/web-components/{Transport-BBGTe9TR.mjs → Transport-DkJkLd_9.mjs} +1 -1
  91. package/dist/web-components/{annotation-collection-OX2RwxfU.mjs → annotation-collection-DgDTaqZJ.mjs} +1 -1
  92. package/dist/web-components/{annotation-name-Cqw8uzpW.mjs → annotation-name-BQPsnye0.mjs} +1 -1
  93. package/dist/web-components/{annotations-content-D8U3ZjMP.mjs → annotations-content-C2Ard-Wu.mjs} +1 -1
  94. package/dist/web-components/{body-B7mRbGgu.mjs → body-CsDqGyS1.mjs} +1 -1
  95. package/dist/web-components/{canvas-BNnp_JHf.mjs → canvas-DYIiw-An.mjs} +1 -1
  96. package/dist/web-components/{cloverEngine-9q7PRtb-.mjs → cloverEngine-BjfUbU7f.mjs} +1 -1
  97. package/dist/web-components/{content-state-reader-DKXoVOui.mjs → content-state-reader-W2X5SbX2.mjs} +1 -1
  98. package/dist/web-components/{controlGlyphs-Bsm42pMw.mjs → controlGlyphs-DO8zuBuP.mjs} +1 -1
  99. package/dist/web-components/{controls-DO27swab.mjs → controls-B-kceETo.mjs} +1 -1
  100. package/dist/web-components/{downloads-BTKk4gk-.mjs → downloads-b2ula2rS.mjs} +1 -1
  101. package/dist/web-components/{dragToClose-Dno8cLqV.mjs → dragToClose-CyySNxZo.mjs} +1 -1
  102. package/dist/web-components/{engine-yxhv49UX.mjs → engine-BO2NyZbt.mjs} +1 -1
  103. package/dist/web-components/{engines-BT170pvZ.mjs → engines-ByJdQYM6.mjs} +1 -1
  104. package/dist/web-components/{fetchManifest-CV61siyX.mjs → fetchManifest-BJPcndui.mjs} +1 -1
  105. package/dist/web-components/{follow-content-1bNP_6Yi.mjs → follow-content-Bta7Cphz.mjs} +1 -1
  106. package/dist/web-components/{fromManifest-ypX5N9bQ.mjs → fromManifest-toVz2G-X.mjs} +1 -1
  107. package/dist/web-components/{glyphs-1YNgPYCb.mjs → glyphs-C9dkvLmy.mjs} +1 -1
  108. package/dist/web-components/{hooks-Bj5sYuBM.mjs → hooks-C1S0JZNP.mjs} +1 -1
  109. package/dist/web-components/{image-layers-CdogbVZE.mjs → image-layers-hf965hJE.mjs} +1 -1
  110. package/dist/web-components/{image-service-content-j8IL6mb0.mjs → image-service-content-kG5TIiB7.mjs} +1 -1
  111. package/dist/web-components/{imageService-D4p3HE1q.mjs → imageService-DVoE9khh.mjs} +1 -1
  112. package/dist/web-components/{index-D13DzX3i.mjs → index-BqgqqnqN.mjs} +1 -1
  113. package/dist/web-components/index.mjs +1 -1
  114. package/dist/web-components/{items-XHM03spJ.mjs → items-DNfIV4vN.mjs} +1 -1
  115. package/dist/web-components/items-Di34gCGN.mjs +1 -0
  116. package/dist/web-components/label-Dt_ns3jW.mjs +1 -0
  117. package/dist/web-components/{layout-D6H3uuwu.mjs → layout--P98JuFG.mjs} +1 -1
  118. package/dist/web-components/{link-D9hsGxQp.mjs → link-p71HL3dn.mjs} +1 -1
  119. package/dist/web-components/logo-QsMwaY8M.mjs +1 -0
  120. package/dist/web-components/{models-DaDtM_UM.mjs → models-BnyeBKu_.mjs} +1 -1
  121. package/dist/web-components/{nodes-B-e9mbx0.mjs → nodes-DZbVJvjk.mjs} +1 -1
  122. package/dist/web-components/{overlayImage-CSW7jSWt.mjs → overlayImage-D6TfbX70.mjs} +1 -1
  123. package/dist/web-components/{panel-C5jcVkr6.mjs → panel-COA5_tL_.mjs} +1 -1
  124. package/dist/web-components/part-DgEyWjer.mjs +1 -0
  125. package/dist/web-components/{playerSurface-pHccePJd.mjs → playerSurface-Uc4JAuxZ.mjs} +1 -1
  126. package/dist/web-components/{pointer-rqjpl5E4.mjs → pointer-BPJduQ1u.mjs} +1 -1
  127. package/dist/web-components/{provider-B9QvZ_Y9.mjs → provider-B4tq-84F.mjs} +1 -1
  128. package/dist/web-components/{range-regions-BQ8bqNTs.mjs → range-regions-92kmJCAy.mjs} +1 -1
  129. package/dist/web-components/{read-more-BT_3kkHZ.mjs → read-more-BnhdOE8Y.mjs} +1 -1
  130. package/dist/web-components/{readingLanguages-B_k-QfX6.mjs → readingLanguages-Bf_HW2UJ.mjs} +1 -1
  131. package/dist/web-components/{rendererSurface-CLbNE-t_.mjs → rendererSurface-BZa3x_Xh.mjs} +2 -2
  132. package/dist/web-components/{renderers-DHgTVdtM.mjs → renderers-CX9SrgrB.mjs} +1 -1
  133. package/dist/web-components/{resource-xQiWQSb9.mjs → resource-DF5HkAfv.mjs} +1 -1
  134. package/dist/web-components/{save-file-Dp3LOhHi.mjs → save-file-oScSwFhH.mjs} +1 -1
  135. package/dist/web-components/{search-DRZzJ0qo.mjs → search-BvpD-NWY.mjs} +1 -1
  136. package/dist/web-components/{shared-BTZk52xk.mjs → shared-w6hjs-L1.mjs} +1 -1
  137. package/dist/web-components/{show-link-CljTxYbA.mjs → show-link-DRCdG8ae.mjs} +1 -1
  138. package/dist/web-components/{sizedImage-Cv3QSASL.mjs → sizedImage-BtyysLax.mjs} +1 -1
  139. package/dist/web-components/{split-CrTZjLVF.mjs → split-DFthztSD.mjs} +1 -1
  140. package/dist/web-components/{status-DCmJGFlF.mjs → status-BZuOJ0UE.mjs} +1 -1
  141. package/dist/web-components/{styles-BdBFz9SS.mjs → styles-BeCG47FS.mjs} +1 -1
  142. package/dist/web-components/three.mjs +1 -1
  143. package/dist/web-components/{thumbnail-BezXZOSj.mjs → thumbnail-DhVhVkd8.mjs} +1 -1
  144. package/dist/web-components/{tip-3wRL05_i.mjs → tip-ukHtKmqe.mjs} +1 -1
  145. package/dist/web-components/{toggle-CyRtVTRf.mjs → toggle-DX4vFKqT.mjs} +1 -1
  146. package/dist/web-components/{useContainerName-Dcg9-lIU.mjs → useContainerName-CM_MIZu9.mjs} +1 -1
  147. package/dist/web-components/{useControlsVisibility-DJGzcs6D.mjs → useControlsVisibility-DZFyrqAJ.mjs} +1 -1
  148. package/dist/web-components/{useNearViewport-C8lmKYws.mjs → useNearViewport-DHvgWl-0.mjs} +1 -1
  149. package/dist/web-components/useScrollTrack-B0Nx9ZZ7.mjs +1 -0
  150. package/dist/web-components/viewer/{AnnotationItems-DJVaxdsI.mjs → AnnotationItems-CLssRyMA.mjs} +1 -1
  151. package/dist/web-components/viewer/{AnnotationMenu-C0d0lTcC.mjs → AnnotationMenu-i4ieWtOL.mjs} +1 -1
  152. package/dist/web-components/viewer/{AnnotationState-B4T0TkvH.mjs → AnnotationState-BmDac4UI.mjs} +1 -1
  153. package/dist/web-components/viewer/{Annotations-WWqn_FbM.mjs → Annotations-C-zxQ4wJ.mjs} +1 -1
  154. package/dist/web-components/viewer/{Annotations-CcvLU7jz.mjs → Annotations-CEwycZ2M.mjs} +1 -1
  155. package/dist/web-components/viewer/{Canvas2DBackend-B5QR4dhT.mjs → Canvas2DBackend-BFb2tuhl.mjs} +1 -1
  156. package/dist/web-components/viewer/{CaptionDetails-B_fCdkw6.mjs → CaptionDetails-Et5z9c7X.mjs} +1 -1
  157. package/dist/web-components/viewer/{ChaptersMenu-BB97eRTx.mjs → ChaptersMenu-CSFNWKY2.mjs} +1 -1
  158. package/dist/web-components/viewer/{ChoiceMenu-BtDTvEbQ.mjs → ChoiceMenu-Ccv0BI0G.mjs} +1 -1
  159. package/dist/web-components/viewer/{Collection-Bz89v2FT.mjs → Collection-86-r4tY9.mjs} +1 -1
  160. package/dist/web-components/viewer/{Connected-Dt8bLgZK.mjs → Connected-D_7Zs7Hq.mjs} +1 -1
  161. package/dist/web-components/viewer/{Connected-CjKNxIxy.mjs → Connected-DbLzPNdX.mjs} +1 -1
  162. package/dist/web-components/viewer/{Contents-jBpCiUSe.mjs → Contents-DUjhQjnI.mjs} +1 -1
  163. package/dist/web-components/viewer/{ControlMenu-l4F81Jg8.mjs → ControlMenu-CKcTiPrh.mjs} +1 -1
  164. package/dist/web-components/viewer/ControlsFade-Bo9VWCLG.mjs +1 -0
  165. package/dist/web-components/viewer/{CountMenu-DU_EJGFs.mjs → CountMenu-B1_cvbuR.mjs} +1 -1
  166. package/dist/web-components/viewer/Cue-DzOw4BLm.mjs +1 -0
  167. package/dist/web-components/viewer/{Document-BldAeNoK.mjs → Document-BGRVcflJ.mjs} +1 -1
  168. package/dist/web-components/viewer/{DomLayers-Bo7DQUIZ.mjs → DomLayers-wxV3sHPY.mjs} +1 -1
  169. package/dist/web-components/viewer/{Download-HDlM1brf.mjs → Download-Cyfhran6.mjs} +1 -1
  170. package/dist/web-components/viewer/{EntryBodies-k9Kf71ll.mjs → EntryBodies-B2WCkj8y.mjs} +1 -1
  171. package/dist/web-components/viewer/{EntryThumbnail-DEXlu64w.mjs → EntryThumbnail-dUTxyqTj.mjs} +1 -1
  172. package/dist/web-components/viewer/{FieldPill-BTuiYb55.mjs → FieldPill-D8gW-r_p.mjs} +1 -1
  173. package/dist/web-components/viewer/{FrameAnimation-DXJvvX_O.mjs → FrameAnimation-ChG6Louz.mjs} +1 -1
  174. package/dist/web-components/viewer/{Gallery-BR4uUPRO.mjs → Gallery-OZ5ZiwmB.mjs} +1 -1
  175. package/dist/web-components/viewer/{GlobeGlyph-BFChlnAW.mjs → GlobeGlyph-CXycpMBJ.mjs} +1 -1
  176. package/dist/web-components/viewer/{HideToggle-Cl2mlgJh.mjs → HideToggle-BMddH3GA.mjs} +1 -1
  177. package/dist/web-components/viewer/{ImageControls-rNkvWCA9.mjs → ImageControls-Bu_6VlDO.mjs} +1 -1
  178. package/dist/web-components/viewer/{LanguageChoice-Bel5VdoV.mjs → LanguageChoice-BUTtsHEi.mjs} +1 -1
  179. package/dist/web-components/viewer/{LanguageMenu-Bj0g79QR.mjs → LanguageMenu-DOYyHpdr.mjs} +1 -1
  180. package/dist/web-components/viewer/{LightboxView-DO8edg2H.mjs → LightboxView-DP4_ElsL.mjs} +1 -1
  181. package/dist/web-components/viewer/{ListEnd-D63rV7LR.mjs → ListEnd-CEdhO0md.mjs} +1 -1
  182. package/dist/web-components/viewer/{MapView-ahuj5gKJ.mjs → MapView-qaaRmnM-.mjs} +2 -2
  183. package/dist/web-components/viewer/{MediaBody-DhSdnEui.mjs → MediaBody-Cjl76Spk.mjs} +1 -1
  184. package/dist/web-components/viewer/{MediaBody-DJE41Ggr.mjs → MediaBody-CvXptO7l.mjs} +1 -1
  185. package/dist/web-components/viewer/{NavDate-C5fftA6E.mjs → NavDate-OJND1QQD.mjs} +1 -1
  186. package/dist/web-components/viewer/{Navigator-BVkHzfLs.mjs → Navigator-DRwnm5an.mjs} +1 -1
  187. package/dist/web-components/viewer/{PagerLayout-CKN0Llkn.mjs → PagerLayout-DN7ZEktF.mjs} +1 -1
  188. package/dist/web-components/viewer/PanelPart-CF2Fw2b4.mjs +1 -0
  189. package/dist/web-components/viewer/{PartOfManifest-Brc4z7df.mjs → PartOfManifest-3cK5il9_.mjs} +1 -1
  190. package/dist/web-components/viewer/{PlaceBox-ByWy7e9J.mjs → PlaceBox-C9qj6wIy.mjs} +1 -1
  191. package/dist/web-components/viewer/{Placeholder-CmKEgeqP.mjs → Placeholder-DmX-oTRS.mjs} +1 -1
  192. package/dist/web-components/viewer/{Search-COUo-BuO.mjs → Search-DLRmliHy.mjs} +1 -1
  193. package/dist/web-components/viewer/{SeekMarks-BWHqY1g-.mjs → SeekMarks-BsAVx2o9.mjs} +1 -1
  194. package/dist/web-components/viewer/{StandaloneItems-87W1Mih3.mjs → StandaloneItems-BOXI-FO-.mjs} +1 -1
  195. package/dist/web-components/viewer/{Steps-CUzjymlQ.mjs → Steps-Dl85Vj2l.mjs} +1 -1
  196. package/dist/web-components/viewer/{TargetItems-Bms6M3cB.mjs → TargetItems-BVT2_Bey.mjs} +1 -1
  197. package/dist/web-components/viewer/{Transcript-DigEuuAR.mjs → Transcript-fRjfw6kB.mjs} +1 -1
  198. package/dist/web-components/viewer/{Transport-BZcrgDpa.mjs → Transport-Bu1B2DCX.mjs} +1 -1
  199. package/dist/web-components/viewer/{Transport-DFpiEGiY.mjs → Transport-DKUQM7Hn.mjs} +1 -1
  200. package/dist/web-components/viewer/{annotation-collection-JyxEZk8B.mjs → annotation-collection-B7DNaCRe.mjs} +1 -1
  201. package/dist/web-components/viewer/{annotation-name-BJTap0Us.mjs → annotation-name-DCAh29x5.mjs} +1 -1
  202. package/dist/web-components/viewer/{annotations-content-yT8J4zoX.mjs → annotations-content-BG992gjT.mjs} +1 -1
  203. package/dist/web-components/viewer/{cloverEngine-DZDKElxt.mjs → cloverEngine-SxAYyRtz.mjs} +1 -1
  204. package/dist/web-components/viewer/{content-state-reader-RmqJu8gE.mjs → content-state-reader-CRGjvYpM.mjs} +1 -1
  205. package/dist/web-components/viewer/{dragToClose-C995dPad.mjs → dragToClose-Di8WUOHC.mjs} +1 -1
  206. package/dist/web-components/viewer/{fetchManifest-CS577eE5.mjs → fetchManifest-B3gCtveO.mjs} +1 -1
  207. package/dist/web-components/viewer/{follow-content-DLMLz7-u.mjs → follow-content-2RmNmRMy.mjs} +1 -1
  208. package/dist/web-components/viewer/{host-C79mYkpB.mjs → host-CM3zmrKp.mjs} +1 -1
  209. package/dist/web-components/viewer/{image-layers-zMvi4pmw.mjs → image-layers-CmimeZYQ.mjs} +1 -1
  210. package/dist/web-components/viewer/{image-service-content-CjRd-2iP.mjs → image-service-content-DNYciFvo.mjs} +1 -1
  211. package/dist/web-components/viewer/index.mjs +1 -1
  212. package/dist/web-components/viewer/{link-DaJErMnE.mjs → link-CrW4CND2.mjs} +1 -1
  213. package/dist/web-components/viewer/{overlayImage-DCBpb4lw.mjs → overlayImage-Bgl_ar2I.mjs} +1 -1
  214. package/dist/web-components/viewer/{range-regions-BY9UB0kS.mjs → range-regions-DwMexshz.mjs} +1 -1
  215. package/dist/web-components/viewer/{renderers-BsrSfP28.mjs → renderers-Cs9Wbr3d.mjs} +1 -1
  216. package/dist/web-components/viewer/{save-file-CwXaCAyi.mjs → save-file-CpREFWq3.mjs} +1 -1
  217. package/dist/web-components/viewer/{search-CmWgigDq.mjs → search-CI1xScP1.mjs} +1 -1
  218. package/dist/web-components/viewer/{styles-ihp-vncb.mjs → styles-nU97HodU.mjs} +1 -1
  219. package/dist/web-components/viewer/{useControlsVisibility-DbCeSjAK.mjs → useControlsVisibility-CCTZH1aT.mjs} +1 -1
  220. package/dist/web-components/viewer/viewer-BDXZbbZI.mjs +29 -0
  221. package/dist/web-components/viewer/{vtt-CkDv-L8Y.mjs → vtt-DJjsoNz1.mjs} +1 -1
  222. package/dist/web-components/viewer-DD2bGSYe.mjs +1 -0
  223. package/dist/web-components/{vtt-CylghmBS.mjs → vtt-D30pzLou.mjs} +1 -1
  224. package/package.json +1 -1
  225. package/dist/web-components/Connected-CNWHy7Nf.mjs +0 -1
  226. package/dist/web-components/Connected-CVQI5ppY.mjs +0 -1
  227. package/dist/web-components/ControlsFade-COi8-AZI.mjs +0 -1
  228. package/dist/web-components/Cue-CQFnHV1R.mjs +0 -1
  229. package/dist/web-components/Items-eaCz7ufI.mjs +0 -1
  230. package/dist/web-components/LoadedMap-BVkNlBeH.mjs +0 -1
  231. package/dist/web-components/PanelPart-BJwA1Z3f.mjs +0 -1
  232. package/dist/web-components/Scene-CS2xqRNL.mjs +0 -1
  233. package/dist/web-components/Timeline-j4BWRpk4.mjs +0 -1
  234. package/dist/web-components/items-CLwd-kOq.mjs +0 -1
  235. package/dist/web-components/label-DOqlHvhq.mjs +0 -1
  236. package/dist/web-components/logo-DpAvbwvh.mjs +0 -1
  237. package/dist/web-components/part-Du5hBwFZ.mjs +0 -1
  238. package/dist/web-components/useScrollTrack-D6TRdz7f.mjs +0 -1
  239. package/dist/web-components/viewer/ControlsFade-BPFSCV0a.mjs +0 -1
  240. package/dist/web-components/viewer/Cue-D4-as926.mjs +0 -1
  241. package/dist/web-components/viewer/PanelPart-Z12fMdZh.mjs +0 -1
  242. package/dist/web-components/viewer/viewer-Ds1v3IFN.mjs +0 -29
  243. package/dist/web-components/viewer-B2HVSNC2.mjs +0 -1
@@ -1 +1 @@
1
- import{az as l,bv as g}from"./viewer-Ds1v3IFN.mjs";function b(t){const e=t.replace(/-/g,"+").replace(/_/g,"/"),n=e+"=".repeat((4-e.length%4)%4),a=atob(n);try{return decodeURIComponent(a)}catch{const c=Uint8Array.from(a,s=>s.charCodeAt(0));return new TextDecoder().decode(c)}}function I(t){const e=t.trim();for(const n of[()=>JSON.parse(e),()=>JSON.parse(b(e))])try{const a=n();if(a&&typeof a=="object")return a}catch{}return null}function v(t){if(!t)return;const e=Number(t.split(",")[0]);return Number.isFinite(e)?e:void 0}const u=t=>l(t==null?void 0:t.partOf).find(e=>(e==null?void 0:e.id)&&e.type==="Collection");function A(t){const e=t.type==="Annotation"?l(t.target):[t],n=e[0]?m(e[0],t):null;if(!n||e.length<2)return n;const a=typeof t.id=="string"?t.id:"content-state",c=e.flatMap((s,d)=>{var y,p,f;const i=d===0?n:m(s,t),r=(i==null?void 0:i.type)==="Manifest"?i.id:i==null?void 0:i.manifestId;return!i||!r?[]:[{id:`${a}#target-${d+1}`,manifestId:r,...((y=i.target)==null?void 0:y.canvasId)&&{canvasId:i.target.canvasId},...((p=i.target)==null?void 0:p.region)&&{region:i.target.region},...((f=i.target)==null?void 0:f.time)!==void 0&&{time:i.target.time}}]});return c.length>1?{...n,targets:{id:a,...t.label&&typeof t.label=="object"?{label:t.label}:{},items:c}}:n}function m(t,e){const n=g(t),a=typeof t=="string"?{id:n.id}:t.type==="SpecificResource"?typeof t.source=="string"?{id:t.source}:t.source??{}:t,c=a.type;if(c==="Manifest"||c==="Collection"){const o=c==="Manifest"?u(a):void 0;return o?{id:o.id,type:"Collection",manifestId:n.id}:{id:n.id,type:c}}const s=l(t.selector).find(o=>(o==null?void 0:o.type)==="PointSelector"&&o.t!=null),d={canvasId:n.id};n.rect&&(d.region=n.rect);const i=(s==null?void 0:s.t)??v(n.t);i!==void 0&&(d.time=Number(i));const r=[a,t].flatMap(o=>l(o==null?void 0:o.partOf)).find(o=>(o==null?void 0:o.id)&&(!o.type||o.type==="Manifest")),y=u(r),p=e.type==="Annotation"&&l(e.body).length?{id:e.id??`${n.id}#content-state`,type:"Annotation",motivation:l(e.motivation),body:e.body,target:t}:void 0,f=p?{annotation:p}:{};return y&&r?{id:y.id,type:"Collection",manifestId:r.id,target:d,...f}:r?{id:r.id,type:"Manifest",target:d,...f}:{id:n.id,type:c??"Canvas",target:d,...f}}export{I as decodeContentState,A as resolveContentState};
1
+ import{az as l,bv as g}from"./viewer-BDXZbbZI.mjs";function b(t){const e=t.replace(/-/g,"+").replace(/_/g,"/"),n=e+"=".repeat((4-e.length%4)%4),a=atob(n);try{return decodeURIComponent(a)}catch{const c=Uint8Array.from(a,s=>s.charCodeAt(0));return new TextDecoder().decode(c)}}function I(t){const e=t.trim();for(const n of[()=>JSON.parse(e),()=>JSON.parse(b(e))])try{const a=n();if(a&&typeof a=="object")return a}catch{}return null}function v(t){if(!t)return;const e=Number(t.split(",")[0]);return Number.isFinite(e)?e:void 0}const u=t=>l(t==null?void 0:t.partOf).find(e=>(e==null?void 0:e.id)&&e.type==="Collection");function A(t){const e=t.type==="Annotation"?l(t.target):[t],n=e[0]?m(e[0],t):null;if(!n||e.length<2)return n;const a=typeof t.id=="string"?t.id:"content-state",c=e.flatMap((s,d)=>{var y,p,f;const i=d===0?n:m(s,t),r=(i==null?void 0:i.type)==="Manifest"?i.id:i==null?void 0:i.manifestId;return!i||!r?[]:[{id:`${a}#target-${d+1}`,manifestId:r,...((y=i.target)==null?void 0:y.canvasId)&&{canvasId:i.target.canvasId},...((p=i.target)==null?void 0:p.region)&&{region:i.target.region},...((f=i.target)==null?void 0:f.time)!==void 0&&{time:i.target.time}}]});return c.length>1?{...n,targets:{id:a,...t.label&&typeof t.label=="object"?{label:t.label}:{},items:c}}:n}function m(t,e){const n=g(t),a=typeof t=="string"?{id:n.id}:t.type==="SpecificResource"?typeof t.source=="string"?{id:t.source}:t.source??{}:t,c=a.type;if(c==="Manifest"||c==="Collection"){const o=c==="Manifest"?u(a):void 0;return o?{id:o.id,type:"Collection",manifestId:n.id}:{id:n.id,type:c}}const s=l(t.selector).find(o=>(o==null?void 0:o.type)==="PointSelector"&&o.t!=null),d={canvasId:n.id};n.rect&&(d.region=n.rect);const i=(s==null?void 0:s.t)??v(n.t);i!==void 0&&(d.time=Number(i));const r=[a,t].flatMap(o=>l(o==null?void 0:o.partOf)).find(o=>(o==null?void 0:o.id)&&(!o.type||o.type==="Manifest")),y=u(r),p=e.type==="Annotation"&&l(e.body).length?{id:e.id??`${n.id}#content-state`,type:"Annotation",motivation:l(e.motivation),body:e.body,target:t}:void 0,f=p?{annotation:p}:{};return y&&r?{id:y.id,type:"Collection",manifestId:r.id,target:d,...f}:r?{id:r.id,type:"Manifest",target:d,...f}:{id:n.id,type:c??"Canvas",target:d,...f}}export{I as decodeContentState,A as resolveContentState};
@@ -1 +1 @@
1
- import{bx as _}from"./viewer-Ds1v3IFN.mjs";const k=1/3,Y=.5,P=8,z="translate 240ms cubic-bezier(0.16, 1, 0.3, 1)",D=[120,_],A="cubic-bezier(0.33, 0.67, 0.67, 1)",E=new WeakMap;function O(t,n){let o=null,i="idle",a=0,S=0,s=0,d=1,e=1,c=[];const f=()=>{var r;return[t,(r=n.current.alongside)==null?void 0:r.current]},M=r=>{if(r.pointerType==="mouse"||!r.isPrimary||!n.current.enabled)return;o=r.pointerId,i="pending",a=r.clientX,S=r.clientY,s=0,d=t.getBoundingClientRect().width||1;const p=getComputedStyle(t).direction==="rtl";e=n.current.side==="end"!==p?1:-1,c=[[r.timeStamp,0]]},$=r=>{var g,v;if(r.pointerId!==o||i==="idle"||i==="scroll")return;const p=(r.clientX-a)*e,y=r.clientY-S;if(i==="pending"){if(Math.abs(y)>P&&Math.abs(y)>Math.abs(p)){i="scroll";return}if(p<P)return;i="drag",a=r.clientX,c=[[r.timeStamp,0]];try{(g=t.setPointerCapture)==null||g.call(t,r.pointerId)}catch{}u(f(),void 0,"none")}s=Math.max(0,(r.clientX-a)*e),u(f(),`${s*e}px 0`);const h=(v=n.current.scrim)==null?void 0:v.current;h&&(h.style.transition="none",h.style.opacity=String(1-s/d)),c.push([r.timeStamp,s]),c.length>5&&c.shift(),r.preventDefault()},m=r=>{var X,C,T;if(r.pointerId!==o)return;const p=i==="drag";if(i="idle",o=null,!p)return;t.addEventListener("click",b,{capture:true,once:true}),setTimeout(()=>t.removeEventListener("click",b,true),0);const[y,h]=c[0],[g,v]=c[c.length-1],I=g>y?(v-h)/(g-y):0,l=(X=n.current.scrim)==null?void 0:X.current,x=(C=window.matchMedia)==null?void 0:C.call(window,"(prefers-reduced-motion: reduce)").matches;if(s>d*k||I>Y){const L=x?0:Math.min(D[1],Math.max(D[0],2*(d-s)/Math.max(I,.001))),w=`${L}ms ${A}`;if(l&&(l.style.transition=`opacity ${w}`,l.style.opacity="0"),n.current.exits){u(f(),`${d*e}px 0`,`translate ${w}`),setTimeout(()=>n.current.onClose(),L);return}t.style.transition="none",t.style.translate="",t.style.transform=`translateX(${s*e}px)`,t.getBoundingClientRect(),t.style.transition=`transform ${w}`,t.style.transform=`var(--clover-template-out, translateX(${e*100}%))`,u([(T=n.current.alongside)==null?void 0:T.current],`${d*e}px 0`,`translate ${w}`),E.set(t,setTimeout(()=>R(t,n),L)),n.current.onClose();return}u(f(),"",x?"none":z),l&&(l.style.transition=x?"none":"opacity 240ms ease",l.style.opacity=""),setTimeout(()=>{i==="idle"&&!E.has(t)&&u(f(),void 0,"")},240)},b=r=>{r.stopPropagation(),r.preventDefault()};return t.addEventListener("pointerdown",M),t.addEventListener("pointermove",$,{passive:false}),t.addEventListener("pointerup",m),t.addEventListener("pointercancel",m),()=>{t.removeEventListener("pointerdown",M),t.removeEventListener("pointermove",$),t.removeEventListener("pointerup",m),t.removeEventListener("pointercancel",m)}}function F(t,n){E.has(t)&&!n.current.enabled||R(t,n)}function R(t,n){var i,a;clearTimeout(E.get(t)),E.delete(t),u([t,(i=n.current.alongside)==null?void 0:i.current],"",""),t.style.transform="";const o=(a=n.current.scrim)==null?void 0:a.current;o&&(o.style.opacity="",o.style.transition="")}function u(t,n,o){for(const i of t)i&&(o!==void 0&&(i.style.transition=o),n!==void 0&&(i.style.translate=n))}export{O as attach,F as reset};
1
+ import{bx as _}from"./viewer-BDXZbbZI.mjs";const k=1/3,Y=.5,P=8,z="translate 240ms cubic-bezier(0.16, 1, 0.3, 1)",D=[120,_],A="cubic-bezier(0.33, 0.67, 0.67, 1)",E=new WeakMap;function O(t,n){let o=null,i="idle",a=0,S=0,s=0,d=1,e=1,c=[];const f=()=>{var r;return[t,(r=n.current.alongside)==null?void 0:r.current]},M=r=>{if(r.pointerType==="mouse"||!r.isPrimary||!n.current.enabled)return;o=r.pointerId,i="pending",a=r.clientX,S=r.clientY,s=0,d=t.getBoundingClientRect().width||1;const p=getComputedStyle(t).direction==="rtl";e=n.current.side==="end"!==p?1:-1,c=[[r.timeStamp,0]]},$=r=>{var g,v;if(r.pointerId!==o||i==="idle"||i==="scroll")return;const p=(r.clientX-a)*e,y=r.clientY-S;if(i==="pending"){if(Math.abs(y)>P&&Math.abs(y)>Math.abs(p)){i="scroll";return}if(p<P)return;i="drag",a=r.clientX,c=[[r.timeStamp,0]];try{(g=t.setPointerCapture)==null||g.call(t,r.pointerId)}catch{}u(f(),void 0,"none")}s=Math.max(0,(r.clientX-a)*e),u(f(),`${s*e}px 0`);const h=(v=n.current.scrim)==null?void 0:v.current;h&&(h.style.transition="none",h.style.opacity=String(1-s/d)),c.push([r.timeStamp,s]),c.length>5&&c.shift(),r.preventDefault()},m=r=>{var X,C,T;if(r.pointerId!==o)return;const p=i==="drag";if(i="idle",o=null,!p)return;t.addEventListener("click",b,{capture:true,once:true}),setTimeout(()=>t.removeEventListener("click",b,true),0);const[y,h]=c[0],[g,v]=c[c.length-1],I=g>y?(v-h)/(g-y):0,l=(X=n.current.scrim)==null?void 0:X.current,x=(C=window.matchMedia)==null?void 0:C.call(window,"(prefers-reduced-motion: reduce)").matches;if(s>d*k||I>Y){const L=x?0:Math.min(D[1],Math.max(D[0],2*(d-s)/Math.max(I,.001))),w=`${L}ms ${A}`;if(l&&(l.style.transition=`opacity ${w}`,l.style.opacity="0"),n.current.exits){u(f(),`${d*e}px 0`,`translate ${w}`),setTimeout(()=>n.current.onClose(),L);return}t.style.transition="none",t.style.translate="",t.style.transform=`translateX(${s*e}px)`,t.getBoundingClientRect(),t.style.transition=`transform ${w}`,t.style.transform=`var(--clover-template-out, translateX(${e*100}%))`,u([(T=n.current.alongside)==null?void 0:T.current],`${d*e}px 0`,`translate ${w}`),E.set(t,setTimeout(()=>R(t,n),L)),n.current.onClose();return}u(f(),"",x?"none":z),l&&(l.style.transition=x?"none":"opacity 240ms ease",l.style.opacity=""),setTimeout(()=>{i==="idle"&&!E.has(t)&&u(f(),void 0,"")},240)},b=r=>{r.stopPropagation(),r.preventDefault()};return t.addEventListener("pointerdown",M),t.addEventListener("pointermove",$,{passive:false}),t.addEventListener("pointerup",m),t.addEventListener("pointercancel",m),()=>{t.removeEventListener("pointerdown",M),t.removeEventListener("pointermove",$),t.removeEventListener("pointerup",m),t.removeEventListener("pointercancel",m)}}function F(t,n){E.has(t)&&!n.current.enabled||R(t,n)}function R(t,n){var i,a;clearTimeout(E.get(t)),E.delete(t),u([t,(i=n.current.alongside)==null?void 0:i.current],"",""),t.style.transform="";const o=(a=n.current.scrim)==null?void 0:a.current;o&&(o.style.opacity="",o.style.transition="")}function u(t,n,o){for(const i of t)i&&(o!==void 0&&(i.style.transition=o),n!==void 0&&(i.style.translate=n))}export{O as attach,F as reset};
@@ -1 +1 @@
1
- import{az as h,ax as x,bu as m,bv as I,bw as q}from"./viewer-Ds1v3IFN.mjs";function S(e,i,n){for(const s of h(e==null?void 0:e.items))for(const o of h(s==null?void 0:s.items)){if(!x(o))continue;const l=h(o==null?void 0:o.body).flatMap(t=>(t==null?void 0:t.type)==="Choice"?h(t.items).filter((r,f)=>n?(r==null?void 0:r.id)===n:f===0):n&&(t==null?void 0:t.id)!==n?[]:[t]);for(const t of l){if((t==null?void 0:t.type)!=="Image"||!t.width||!t.height)continue;const r=m(t.service);if(!r)continue;const f=I(h(o.target)[0]).rect??{x:0,y:0,w:e.width,h:e.height},a=(i.x-f.x)/f.w,c=(i.y-f.y)/f.h,u=Math.max(0,a),w=Math.max(0,c),M=Math.min(1,a+i.w/f.w)-u,g=Math.min(1,c+i.h/f.h)-w;if(M>0&&g>0)return{service:r,region:{x:u,y:w,width:M,height:g}}}}return null}const p=new WeakMap;function k(e,i){let n=p.get(e);n||p.set(e,n=new Map);let s=n.get(i);return s||(s=q({id:i,type:"Manifest"},{request:e.request}).catch(()=>null),n.set(i,s)),s}export{k as f,S as r};
1
+ import{az as h,ax as x,bu as m,bv as I,bw as q}from"./viewer-BDXZbbZI.mjs";function S(e,i,n){for(const s of h(e==null?void 0:e.items))for(const o of h(s==null?void 0:s.items)){if(!x(o))continue;const l=h(o==null?void 0:o.body).flatMap(t=>(t==null?void 0:t.type)==="Choice"?h(t.items).filter((r,f)=>n?(r==null?void 0:r.id)===n:f===0):n&&(t==null?void 0:t.id)!==n?[]:[t]);for(const t of l){if((t==null?void 0:t.type)!=="Image"||!t.width||!t.height)continue;const r=m(t.service);if(!r)continue;const f=I(h(o.target)[0]).rect??{x:0,y:0,w:e.width,h:e.height},a=(i.x-f.x)/f.w,c=(i.y-f.y)/f.h,u=Math.max(0,a),w=Math.max(0,c),M=Math.min(1,a+i.w/f.w)-u,g=Math.min(1,c+i.h/f.h)-w;if(M>0&&g>0)return{service:r,region:{x:u,y:w,width:M,height:g}}}}return null}const p=new WeakMap;function k(e,i){let n=p.get(e);n||p.set(e,n=new Map);let s=n.get(i);return s||(s=q({id:i,type:"Manifest"},{request:e.request}).catch(()=>null),n.set(i,s)),s}export{k as f,S as r};
@@ -1 +1 @@
1
- import{bG as w,az as f,bv as l}from"./viewer-Ds1v3IFN.mjs";import{resolveContentState as b}from"./content-state-reader-RmqJu8gE.mjs";import{readSvgShape as S}from"./svg-shape-CTjogIds.mjs";const m="http://iiif.io/api/presentation/2/context.json",x=t=>(t==null?void 0:t["@type"])==="oa:Annotation"||(t==null?void 0:t["@id"])!==void 0&&f(t==null?void 0:t["@context"]).includes(m),y=t=>typeof t=="string"?t:(t==null?void 0:t["@id"])??(t==null?void 0:t.id);async function I(t){if(!x(t))return t;const{convertPresentation2:n}=await import("../presentation-2-C-U79S_T.mjs"),r=n({"@context":m,...JSON.parse(JSON.stringify(t))}),a=f(t.on).map(e=>y(f(e==null?void 0:e.within)[0])),s=f(r.target).map((e,c)=>{const o=a[c];if(!o)return e;const d=[{id:o,type:"Manifest"}],g=(e==null?void 0:e.type)==="SpecificResource",u=y(g?e.source:e);return u?g?{...e,source:{id:u,type:"Canvas",partOf:d}}:{id:u,type:"Canvas",partOf:d}:e}),i=f(r.body).map(e=>typeof(e==null?void 0:e.chars)=="string"?{type:"TextualBody",value:e.chars,...e.format?{format:e.format}:{},...e.language?{language:e.language}:{}}:e);return{...r,"@context":void 0,type:"Annotation",target:s.length===1?s[0]:s,...i.length?{body:i.length===1?i[0]:i}:{}}}async function $(t,n,r){const a=await A(t);if(!a)throw new w("Unreadable content state");const s=await r(a.id,{...n,manifestId:n.manifestId??a.manifestId,follows:(n.follows??0)+1}),{target:i}=a;return O({...s,target:i&&(!s.target||s.target.canvasId===i.canvasId)?{...s.target,...i}:s.target??i,annotation:s.annotation??a.annotation,targets:s.targets??a.targets})}async function A(t){const n=await I(t),r=b(n);if(!r)return null;const a=n.type==="Annotation"?f(n.target)[0]:n,s=C(l(a).svg),i=r.annotation;return{...r,...r.target&&!r.target.region&&s?{target:{...r.target,region:s}}:{},...i?{annotation:{...i,motivation:f(i.motivation).filter(e=>e!=="painting"),...n.label?{label:n.label}:{}}}:{}}}function N(t){const n=t?Number(t.split(",")[0]):NaN;return Number.isFinite(n)?n:void 0}function C(t){var r;const n=t?(r=S(t))==null?void 0:r.box:void 0;return n&&n.width>0&&n.height>0?{x:n.x,y:n.y,w:n.width,h:n.height}:void 0}function R(t,n){const r=new Set,a=e=>{for(const c of e){if(!c||r.has(c))continue;if(r.add(c),c.type==="Range"&&c.id===n)return c;const o=a(f(c.items));if(o)return o}},s=(e,c=0)=>{for(const o of f(e.items)){if((o==null?void 0:o.type)==="Range"){const p=c<16?s(o,c+1):null;if(p)return p;continue}const d=typeof o=="string"?o:o==null?void 0:o.id,g=l((o==null?void 0:o.type)==="SpecificResource"?o:String(d??"").replace(/\/((?:t|xywh)=[^/#]*)$/,"#$1"));if(!g.id)continue;const u=N(g.t);return{canvasId:g.id,...g.rect?{region:g.rect}:{},...u!==void 0?{time:u}:{}}}return null},i=a(f(t.structures));return i?s(i):null}function v(t,n){if(typeof t=="string"){const a=t.indexOf("#");return a<0?n:n+t.slice(a)}const r=t;return(r==null?void 0:r.type)==="SpecificResource"?{...r,source:typeof r.source=="object"?{...r.source,id:n,type:"Canvas"}:{id:n,type:"Canvas"}}:v(String((r==null?void 0:r.id)??""),n)}function O(t){var c;const{manifest:n,target:r}=t;if(!r)return t;const a=f(n.items);if(a.some(o=>(o==null?void 0:o.id)===r.canvasId))return t;const i=(a.length===1&&((c=a[0])==null?void 0:c.id)===`${n.id}/canvas`?{canvasId:a[0].id}:null)??R(n,r.canvasId);if(!i)return t;const e=t.annotation&&{...t.annotation,target:v(t.annotation.target,i.canvasId)};return{...t,target:{...r,canvasId:i.canvasId,...r.region?{}:i.region?{region:i.region}:{},...r.time!==void 0?{}:i.time!==void 0?{time:i.time}:{}},...e?{annotation:e}:{}}}export{$ as follow,O as placeTarget,I as readAnnotation,A as resolve};
1
+ import{bG as w,az as f,bv as l}from"./viewer-BDXZbbZI.mjs";import{resolveContentState as b}from"./content-state-reader-CRGjvYpM.mjs";import{readSvgShape as S}from"./svg-shape-CTjogIds.mjs";const m="http://iiif.io/api/presentation/2/context.json",x=t=>(t==null?void 0:t["@type"])==="oa:Annotation"||(t==null?void 0:t["@id"])!==void 0&&f(t==null?void 0:t["@context"]).includes(m),y=t=>typeof t=="string"?t:(t==null?void 0:t["@id"])??(t==null?void 0:t.id);async function I(t){if(!x(t))return t;const{convertPresentation2:n}=await import("../presentation-2-C-U79S_T.mjs"),r=n({"@context":m,...JSON.parse(JSON.stringify(t))}),a=f(t.on).map(e=>y(f(e==null?void 0:e.within)[0])),s=f(r.target).map((e,c)=>{const o=a[c];if(!o)return e;const d=[{id:o,type:"Manifest"}],g=(e==null?void 0:e.type)==="SpecificResource",u=y(g?e.source:e);return u?g?{...e,source:{id:u,type:"Canvas",partOf:d}}:{id:u,type:"Canvas",partOf:d}:e}),i=f(r.body).map(e=>typeof(e==null?void 0:e.chars)=="string"?{type:"TextualBody",value:e.chars,...e.format?{format:e.format}:{},...e.language?{language:e.language}:{}}:e);return{...r,"@context":void 0,type:"Annotation",target:s.length===1?s[0]:s,...i.length?{body:i.length===1?i[0]:i}:{}}}async function $(t,n,r){const a=await A(t);if(!a)throw new w("Unreadable content state");const s=await r(a.id,{...n,manifestId:n.manifestId??a.manifestId,follows:(n.follows??0)+1}),{target:i}=a;return O({...s,target:i&&(!s.target||s.target.canvasId===i.canvasId)?{...s.target,...i}:s.target??i,annotation:s.annotation??a.annotation,targets:s.targets??a.targets})}async function A(t){const n=await I(t),r=b(n);if(!r)return null;const a=n.type==="Annotation"?f(n.target)[0]:n,s=C(l(a).svg),i=r.annotation;return{...r,...r.target&&!r.target.region&&s?{target:{...r.target,region:s}}:{},...i?{annotation:{...i,motivation:f(i.motivation).filter(e=>e!=="painting"),...n.label?{label:n.label}:{}}}:{}}}function N(t){const n=t?Number(t.split(",")[0]):NaN;return Number.isFinite(n)?n:void 0}function C(t){var r;const n=t?(r=S(t))==null?void 0:r.box:void 0;return n&&n.width>0&&n.height>0?{x:n.x,y:n.y,w:n.width,h:n.height}:void 0}function R(t,n){const r=new Set,a=e=>{for(const c of e){if(!c||r.has(c))continue;if(r.add(c),c.type==="Range"&&c.id===n)return c;const o=a(f(c.items));if(o)return o}},s=(e,c=0)=>{for(const o of f(e.items)){if((o==null?void 0:o.type)==="Range"){const p=c<16?s(o,c+1):null;if(p)return p;continue}const d=typeof o=="string"?o:o==null?void 0:o.id,g=l((o==null?void 0:o.type)==="SpecificResource"?o:String(d??"").replace(/\/((?:t|xywh)=[^/#]*)$/,"#$1"));if(!g.id)continue;const u=N(g.t);return{canvasId:g.id,...g.rect?{region:g.rect}:{},...u!==void 0?{time:u}:{}}}return null},i=a(f(t.structures));return i?s(i):null}function v(t,n){if(typeof t=="string"){const a=t.indexOf("#");return a<0?n:n+t.slice(a)}const r=t;return(r==null?void 0:r.type)==="SpecificResource"?{...r,source:typeof r.source=="object"?{...r.source,id:n,type:"Canvas"}:{id:n,type:"Canvas"}}:v(String((r==null?void 0:r.id)??""),n)}function O(t){var c;const{manifest:n,target:r}=t;if(!r)return t;const a=f(n.items);if(a.some(o=>(o==null?void 0:o.id)===r.canvasId))return t;const i=(a.length===1&&((c=a[0])==null?void 0:c.id)===`${n.id}/canvas`?{canvasId:a[0].id}:null)??R(n,r.canvasId);if(!i)return t;const e=t.annotation&&{...t.annotation,target:v(t.annotation.target,i.canvasId)};return{...t,target:{...r,canvasId:i.canvasId,...r.region?{}:i.region?{region:i.region}:{},...r.time!==void 0?{}:i.time!==void 0?{time:i.time}:{}},...e?{annotation:e}:{}}}export{$ as follow,O as placeTarget,I as readAnnotation,A as resolve};
@@ -1 +1 @@
1
- var R=Object.defineProperty;var k=(s,t,e)=>t in s?R(s,t,{enumerable:true,configurable:true,writable:true,value:e}):s[t]=e;var l=(s,t,e)=>k(s,typeof t!="symbol"?t+"":t,e);import{b as x,n as E,u as r,M as p,k as O,q as M,C as m,I as g,$ as C,x as D}from"./viewer-Ds1v3IFN.mjs";import"./styles-ihp-vncb.mjs";function N(s){return{render:function(t){E(t,s)},unmount:function(){x(s)}}}const $="clover-root",b=Symbol("roots"),A=[];class F{constructor(t){l(this,"entries",new Map);l(this,"lists",new Map);l(this,"listeners",new Map);l(this,"languages",new I(t2=>this.entries.has(t2)));this.count=t}list(t){return this.lists.get(t)??A}subscribe(t,e){let n=this.listeners.get(t);return n||this.listeners.set(t,n=new Set),n.add(e),()=>{n.delete(e)}}connect(t){var i;const e=t.kind==="part"?((i=t.element.parentElement)==null?void 0:i.closest($))??null:null,n=this.entries.get(t.element);if(n&&n.root===e)return;const o={hosted:t,key:(n==null?void 0:n.key)??++this.count.made,root:e};this.entries.set(t.element,o),n&&this.change(h(n),a=>a.filter(c=>c!==n)),this.change(h(o),a=>[...a,o]),t.needsRoot&&!e&&console.warn(`<${t.element.localName}> shows a <clover-root>'s state: put it inside one.`),t.kind!=="root"&&this.languages.draws(t.element.localName),(t.kind!=="part"||!e)&&this.languages.watch(t.element)}disconnect(t){const e=this.entries.get(t);e&&(this.entries.delete(t),this.change(h(e),n=>n.filter(o=>o!==e)))}change(t,e){var n;this.lists.set(t,e(this.list(t))),(n=this.listeners.get(t))==null||n.forEach(o=>o())}}const h=s=>s.hosted.kind==="root"?b:s.root;class I{constructor(t){l(this,"observer",null);l(this,"tags",new Set);this.isElement=t}draws(t){this.tags.add(t)}watch(t){this.observer??(this.observer=new MutationObserver(e=>{const n=[...this.tags,".clover-announcer"].join(",");for(const{target:o}of e){const i=o;i.getAttribute("lang")!==""||this.isElement(i)||i.closest(n)&&i.removeAttribute("lang")}})),this.observer.observe(t,{subtree:true,attributes:true,attributeFilter:["lang"]})}}function d(s,t){const e=M(o=>s.subscribe(t,o),[s,t]);return m(e,()=>s.list(t))}function w(s){return m(s.subscribe,s.getProps,s.getProps)}function L({registry:s}){const t=d(s,b),e=d(s,null);return r(O,{children:[t.map(n=>r(W,{entry:n,registry:s},n.key)),e.map(n=>r(S,{entry:n},n.key))]})}const v=s=>`clover-${s.key}-`,W=p(function({entry:t,registry:e}){const{hosted:n}=t,o=d(e,n.element),i=w(n),a=n.Component;return r(P,{hosted:n,props:i,children:r(g.Provider,{value:v(t),children:r(a,{hosted:n,props:i,children:o.map(c=>r(S,{entry:c},c.key))})})})}),S=p(function({entry:t}){const{hosted:e}=t,n=w(e);if(e.needsRoot&&!t.root)return null;const o=e.Component;return C(r(P,{hosted:e,props:n,children:r(g.Provider,{value:v(t),children:r(o,{hosted:e,props:n})})}),e.element)});class P extends D{constructor(){super(...arguments);l(this,"state",{failed:false})}static getDerivedStateFromError(){return{failed:true}}componentDidCatch(e,n){console.error(`<${this.props.hosted.element.localName}>:`,e)}componentDidUpdate(e){this.state.failed&&e.props!==this.props.props&&this.setState({failed:false})}render(){return this.state.failed?null:this.props.children}}const f=new WeakMap,u=Symbol.for("clover.elements");function H(s){let t=f.get(s);if(!t){const e=s;e[u]&&console.warn("Clover is loaded twice on this page: load one entry."),t=new F(e[u]??(e[u]={made:0})),f.set(s,t),N(s.createElement("div")).render(r(L,{registry:t}))}return t}export{F as Registry,H as hostOf};
1
+ var R=Object.defineProperty;var k=(s,t,e)=>t in s?R(s,t,{enumerable:true,configurable:true,writable:true,value:e}):s[t]=e;var l=(s,t,e)=>k(s,typeof t!="symbol"?t+"":t,e);import{b as x,n as E,u as r,M as p,k as O,q as M,C as m,I as g,$ as C,x as D}from"./viewer-BDXZbbZI.mjs";import"./styles-nU97HodU.mjs";function N(s){return{render:function(t){E(t,s)},unmount:function(){x(s)}}}const $="clover-root",b=Symbol("roots"),A=[];class F{constructor(t){l(this,"entries",new Map);l(this,"lists",new Map);l(this,"listeners",new Map);l(this,"languages",new I(t2=>this.entries.has(t2)));this.count=t}list(t){return this.lists.get(t)??A}subscribe(t,e){let n=this.listeners.get(t);return n||this.listeners.set(t,n=new Set),n.add(e),()=>{n.delete(e)}}connect(t){var i;const e=t.kind==="part"?((i=t.element.parentElement)==null?void 0:i.closest($))??null:null,n=this.entries.get(t.element);if(n&&n.root===e)return;const o={hosted:t,key:(n==null?void 0:n.key)??++this.count.made,root:e};this.entries.set(t.element,o),n&&this.change(h(n),a=>a.filter(c=>c!==n)),this.change(h(o),a=>[...a,o]),t.needsRoot&&!e&&console.warn(`<${t.element.localName}> shows a <clover-root>'s state: put it inside one.`),t.kind!=="root"&&this.languages.draws(t.element.localName),(t.kind!=="part"||!e)&&this.languages.watch(t.element)}disconnect(t){const e=this.entries.get(t);e&&(this.entries.delete(t),this.change(h(e),n=>n.filter(o=>o!==e)))}change(t,e){var n;this.lists.set(t,e(this.list(t))),(n=this.listeners.get(t))==null||n.forEach(o=>o())}}const h=s=>s.hosted.kind==="root"?b:s.root;class I{constructor(t){l(this,"observer",null);l(this,"tags",new Set);this.isElement=t}draws(t){this.tags.add(t)}watch(t){this.observer??(this.observer=new MutationObserver(e=>{const n=[...this.tags,".clover-announcer"].join(",");for(const{target:o}of e){const i=o;i.getAttribute("lang")!==""||this.isElement(i)||i.closest(n)&&i.removeAttribute("lang")}})),this.observer.observe(t,{subtree:true,attributes:true,attributeFilter:["lang"]})}}function d(s,t){const e=M(o=>s.subscribe(t,o),[s,t]);return m(e,()=>s.list(t))}function w(s){return m(s.subscribe,s.getProps,s.getProps)}function L({registry:s}){const t=d(s,b),e=d(s,null);return r(O,{children:[t.map(n=>r(W,{entry:n,registry:s},n.key)),e.map(n=>r(S,{entry:n},n.key))]})}const v=s=>`clover-${s.key}-`,W=p(function({entry:t,registry:e}){const{hosted:n}=t,o=d(e,n.element),i=w(n),a=n.Component;return r(P,{hosted:n,props:i,children:r(g.Provider,{value:v(t),children:r(a,{hosted:n,props:i,children:o.map(c=>r(S,{entry:c},c.key))})})})}),S=p(function({entry:t}){const{hosted:e}=t,n=w(e);if(e.needsRoot&&!t.root)return null;const o=e.Component;return C(r(P,{hosted:e,props:n,children:r(g.Provider,{value:v(t),children:r(o,{hosted:e,props:n})})}),e.element)});class P extends D{constructor(){super(...arguments);l(this,"state",{failed:false})}static getDerivedStateFromError(){return{failed:true}}componentDidCatch(e,n){console.error(`<${this.props.hosted.element.localName}>:`,e)}componentDidUpdate(e){this.state.failed&&e.props!==this.props.props&&this.setState({failed:false})}render(){return this.state.failed?null:this.props.children}}const f=new WeakMap,u=Symbol.for("clover.elements");function H(s){let t=f.get(s);if(!t){const e=s;e[u]&&console.warn("Clover is loaded twice on this page: load one entry."),t=new F(e[u]??(e[u]={made:0})),f.set(s,t),N(s.createElement("div")).render(r(L,{registry:t}))}return t}export{F as Registry,H as hostOf};
@@ -1 +1 @@
1
- import{ac as C,az as u,ax as I,bv as $,bC as L,bD as P}from"./viewer-Ds1v3IFN.mjs";function q(t){const c=new Map;for(const e of C(t).canvases)S(e,c);return[...c.values()]}function S(t,c){u(t.items).forEach((e,r)=>u(e==null?void 0:e.items).forEach((d,f)=>{if(!I(d))return;const a=$(u(d.target)[0]).rect??{x:0,y:0,w:Number(t.width)||0,h:Number(t.height)||0};u(d.body).forEach((s,y)=>{const w=(s==null?void 0:s.type)==="Choice";(w?u(s.items):[s]).forEach((o,x)=>{for(const n of u(o==null?void 0:o.annotations)){if(!Array.isArray(n==null?void 0:n.items)||typeof(o==null?void 0:o.id)!="string")continue;const l=n.id??`${o.id}#annotations`,p=w?{key:L(t.id,d.id,r,f,y),item:x,image:o.id}:void 0,A=P(n,l,t.id).map(b=>{const h=j(b.annotation,o),N=Math.round(a.x+h.x*(a.w/h.width)),E=Math.round(a.y+h.y*(a.h/h.height)),g=Math.round(h.w*(a.w/h.width)),v=Math.round(h.h*(a.h/h.height)),M=`${t.id}#xywh=${N},${E},${g},${v}`;return{...b,canvasId:t.id,target:$(M),annotation:{...b.annotation,target:M},...p?{layer:p}:{}}});if(!A.length)continue;let m=c.get(l);m||(m={id:l,label:n.label??o.label,source:"manifest",entries:[]},c.set(l,m)),m.entries.push(...A)}})})}))}function j(t,c){const e=Number(c.width)||1,r=Number(c.height)||1,d={x:0,y:0,w:e,h:r,width:e,height:r},f=u(t==null?void 0:t.target)[0],s=(typeof f=="object"?u(f==null?void 0:f.selector):[]).find(i=>(i==null?void 0:i.type)==="ImageApiSelector"),y=typeof(s==null?void 0:s.region)=="string"?s.region:void 0;if(y){const i=/^(pct:)?([\d.]+),([\d.]+),([\d.]+),([\d.]+)$/.exec(y);if(!i)return d;const[o,x,n,l]=i.slice(2).map(Number);return i[1]?{x:o/100*e,y:x/100*r,w:n/100*e,h:l/100*r,width:e,height:r}:{x:o,y:x,w:n,h:l,width:e,height:r}}const w=$(f).rect;return w?{...w,width:e,height:r}:d}export{q as imageLayers};
1
+ import{ac as C,az as u,ax as I,bv as $,bC as L,bD as P}from"./viewer-BDXZbbZI.mjs";function q(t){const c=new Map;for(const e of C(t).canvases)S(e,c);return[...c.values()]}function S(t,c){u(t.items).forEach((e,r)=>u(e==null?void 0:e.items).forEach((d,f)=>{if(!I(d))return;const a=$(u(d.target)[0]).rect??{x:0,y:0,w:Number(t.width)||0,h:Number(t.height)||0};u(d.body).forEach((s,y)=>{const w=(s==null?void 0:s.type)==="Choice";(w?u(s.items):[s]).forEach((o,x)=>{for(const n of u(o==null?void 0:o.annotations)){if(!Array.isArray(n==null?void 0:n.items)||typeof(o==null?void 0:o.id)!="string")continue;const l=n.id??`${o.id}#annotations`,p=w?{key:L(t.id,d.id,r,f,y),item:x,image:o.id}:void 0,A=P(n,l,t.id).map(b=>{const h=j(b.annotation,o),N=Math.round(a.x+h.x*(a.w/h.width)),E=Math.round(a.y+h.y*(a.h/h.height)),g=Math.round(h.w*(a.w/h.width)),v=Math.round(h.h*(a.h/h.height)),M=`${t.id}#xywh=${N},${E},${g},${v}`;return{...b,canvasId:t.id,target:$(M),annotation:{...b.annotation,target:M},...p?{layer:p}:{}}});if(!A.length)continue;let m=c.get(l);m||(m={id:l,label:n.label??o.label,source:"manifest",entries:[]},c.set(l,m)),m.entries.push(...A)}})})}))}function j(t,c){const e=Number(c.width)||1,r=Number(c.height)||1,d={x:0,y:0,w:e,h:r,width:e,height:r},f=u(t==null?void 0:t.target)[0],s=(typeof f=="object"?u(f==null?void 0:f.selector):[]).find(i=>(i==null?void 0:i.type)==="ImageApiSelector"),y=typeof(s==null?void 0:s.region)=="string"?s.region:void 0;if(y){const i=/^(pct:)?([\d.]+),([\d.]+),([\d.]+),([\d.]+)$/.exec(y);if(!i)return d;const[o,x,n,l]=i.slice(2).map(Number);return i[1]?{x:o/100*e,y:x/100*r,w:n/100*e,h:l/100*r,width:e,height:r}:{x:o,y:x,w:n,h:l,width:e,height:r}}const w=$(f).rect;return w?{...w,width:e,height:r}:d}export{q as imageLayers};
@@ -1 +1 @@
1
- import{bZ as c,b_ as d,b$ as l}from"./viewer-Ds1v3IFN.mjs";function m(i){const{width:e,height:t,maxWidth:n,maxHeight:r,maxArea:o}=i,g=(s,p)=>(!n||s<=n)&&(!r||p<=r)&&(!o||s*p<=o);if(g(e,t))return{width:e,height:t};const h=i.sizes.filter(s=>g(s.width,s.height));if(h.length)return h[h.length-1];if(!i.sizeByW)return{width:e,height:t};const a=Math.min(n?n/e:1,r?r/t:1,o?Math.sqrt(o/(e*t)):1);return{width:Math.max(1,Math.floor(e*a)),height:Math.max(1,Math.floor(t*a))}}function u(i,e=200){return i.sizes.find(t=>Math.max(t.width,t.height)>=e)??m(i)}const y={jpg:"image/jpeg",png:"image/png",webp:"image/webp",gif:"image/gif"};function f(i,e,t){const n={x:0,y:0,width:i.width,height:i.height};return{id:l(i,n,t.width,t.height),type:"Image",format:y[i.format]??"image/jpeg",width:t.width,height:t.height,service:[e]}}function w(i,e){if(e.version===3)return{id:e.id,type:"ImageService3",profile:typeof i.profile=="string"?i.profile:"level0"};const t=[].concat(i.profile??[]).find(n=>typeof n=="string");return{"@id":e.id,"@type":"ImageService2",profile:t??"http://iiif.io/api/image/2/level0.json"}}async function x(i,e){const t=c(i,e),n=w(i,t),r=`${t.id}/canvas`,o=[i.rights,i.license].flat().find(a=>typeof a=="string"),g=i.attribution,h={"@context":"http://iiif.io/api/presentation/3/context.json",id:t.id,type:"Manifest",label:{none:[""]},thumbnail:[f(t,n,u(t))],items:[{id:r,type:"Canvas",width:t.width,height:t.height,items:[{id:`${r}/page`,type:"AnnotationPage",items:[{id:`${r}/page/image`,type:"Annotation",motivation:"painting",body:f(t,n,m(t)),target:r}]}]}]};return o&&(h.rights=o),g&&(h.requiredStatement={label:{en:["Attribution"]},value:{none:[].concat(g).map(a=>typeof a=="string"?a:String((a==null?void 0:a["@value"])??"")).filter(Boolean)}}),{manifest:await d(h)}}export{m as fittedSize,x as imageServiceContent};
1
+ import{bZ as c,b_ as d,b$ as l}from"./viewer-BDXZbbZI.mjs";function m(i){const{width:e,height:t,maxWidth:n,maxHeight:r,maxArea:o}=i,g=(s,p)=>(!n||s<=n)&&(!r||p<=r)&&(!o||s*p<=o);if(g(e,t))return{width:e,height:t};const h=i.sizes.filter(s=>g(s.width,s.height));if(h.length)return h[h.length-1];if(!i.sizeByW)return{width:e,height:t};const a=Math.min(n?n/e:1,r?r/t:1,o?Math.sqrt(o/(e*t)):1);return{width:Math.max(1,Math.floor(e*a)),height:Math.max(1,Math.floor(t*a))}}function u(i,e=200){return i.sizes.find(t=>Math.max(t.width,t.height)>=e)??m(i)}const y={jpg:"image/jpeg",png:"image/png",webp:"image/webp",gif:"image/gif"};function f(i,e,t){const n={x:0,y:0,width:i.width,height:i.height};return{id:l(i,n,t.width,t.height),type:"Image",format:y[i.format]??"image/jpeg",width:t.width,height:t.height,service:[e]}}function w(i,e){if(e.version===3)return{id:e.id,type:"ImageService3",profile:typeof i.profile=="string"?i.profile:"level0"};const t=[].concat(i.profile??[]).find(n=>typeof n=="string");return{"@id":e.id,"@type":"ImageService2",profile:t??"http://iiif.io/api/image/2/level0.json"}}async function x(i,e){const t=c(i,e),n=w(i,t),r=`${t.id}/canvas`,o=[i.rights,i.license].flat().find(a=>typeof a=="string"),g=i.attribution,h={"@context":"http://iiif.io/api/presentation/3/context.json",id:t.id,type:"Manifest",label:{none:[""]},thumbnail:[f(t,n,u(t))],items:[{id:r,type:"Canvas",width:t.width,height:t.height,items:[{id:`${r}/page`,type:"AnnotationPage",items:[{id:`${r}/page/image`,type:"Annotation",motivation:"painting",body:f(t,n,m(t)),target:r}]}]}]};return o&&(h.rights=o),g&&(h.requiredStatement={label:{en:["Attribution"]},value:{none:[].concat(g).map(a=>typeof a=="string"?a:String((a==null?void 0:a["@value"])??"")).filter(Boolean)}}),{manifest:await d(h)}}export{m as fittedSize,x as imageServiceContent};
@@ -1 +1 @@
1
- import{cv as e}from"./viewer-Ds1v3IFN.mjs";export{e as initCloverI18n};
1
+ import{cv as e}from"./viewer-BDXZbbZI.mjs";export{e as initCloverI18n};
@@ -1 +1 @@
1
- import{az as d,ay as o,bv as c}from"./viewer-Ds1v3IFN.mjs";function g(i){if(d(i==null?void 0:i.motivation).includes("linking"))for(const t of o(i)){const f=u(t);if(!f)continue;const{id:r,source:e}=f;if((e==null?void 0:e.type)==="Canvas"){const n=d(e.partOf).find(s=>(s==null?void 0:s.id)&&(!s.type||s.type==="Manifest")),p=c(r).id;return{id:r,canvasId:p,...n?{manifestId:n.id}:{}}}if((e==null?void 0:e.type)==="Manifest"||(e==null?void 0:e.type)==="Collection")return{id:r,manifestId:r};if(/^https?:\/\//i.test(r))return{id:r}}}function y(i){const t=d(i==null?void 0:i.motivation);if(!(!t.includes("tagging")&&!t.includes("identifying")))for(const f of o(i)){const r=u(f);if(r&&/^https?:\/\//i.test(r.id))return{id:r.id}}}function u(i){if((i==null?void 0:i.type)!=="SpecificResource")return;const t=i.source;if(typeof t=="string")return t?{id:t,source:void 0}:void 0;const f=t==null?void 0:t.id;return typeof f=="string"&&f?{id:f,source:t}:void 0}export{y as a,g as r};
1
+ import{az as d,ay as o,bv as c}from"./viewer-BDXZbbZI.mjs";function g(i){if(d(i==null?void 0:i.motivation).includes("linking"))for(const t of o(i)){const f=u(t);if(!f)continue;const{id:r,source:e}=f;if((e==null?void 0:e.type)==="Canvas"){const n=d(e.partOf).find(s=>(s==null?void 0:s.id)&&(!s.type||s.type==="Manifest")),p=c(r).id;return{id:r,canvasId:p,...n?{manifestId:n.id}:{}}}if((e==null?void 0:e.type)==="Manifest"||(e==null?void 0:e.type)==="Collection")return{id:r,manifestId:r};if(/^https?:\/\//i.test(r))return{id:r}}}function y(i){const t=d(i==null?void 0:i.motivation);if(!(!t.includes("tagging")&&!t.includes("identifying")))for(const f of o(i)){const r=u(f);if(r&&/^https?:\/\//i.test(r.id))return{id:r.id}}}function u(i){if((i==null?void 0:i.type)!=="SpecificResource")return;const t=i.source;if(typeof t=="string")return t?{id:t,source:void 0}:void 0;const f=t==null?void 0:t.id;return typeof f=="string"&&f?{id:f,source:t}:void 0}export{y as a,g as r};
@@ -1 +1 @@
1
- import{bu as o,cs as s,ct as a}from"./viewer-Ds1v3IFN.mjs";async function d(r,c,n){const t=typeof r.id=="string"?r.id:void 0,e=o(r.service);if(!e)return t;try{const i=await s(e,{request:n});return a(i,c)??t}catch{return t}}export{d as overlayImageUrl};
1
+ import{bu as o,cs as s,ct as a}from"./viewer-BDXZbbZI.mjs";async function d(r,c,n){const t=typeof r.id=="string"?r.id:void 0,e=o(r.service);if(!e)return t;try{const i=await s(e,{request:n});return a(i,c)??t}catch{return t}}export{d as overlayImageUrl};
@@ -1 +1 @@
1
- import{az as c,bA as l,bv as g,bB as v,ba as A}from"./viewer-Ds1v3IFN.mjs";const E=t=>t&&typeof t=="object"?Object.entries(t).flatMap(([i,r])=>c(r).filter(s=>typeof s=="string").map(s=>({value:s,...i!=="none"?{language:i}:{}}))):typeof t=="string"?[{value:t}]:[],a=new WeakMap;function j(t){if(!t)return null;if(a.has(t))return a.get(t);const i=[],r=new Set,s=n=>{if(!n||r.has(n.id??n))return;r.add(n.id??n);const b=typeof n.id=="string"&&!c(n.behavior).includes("no-nav"),d=E(n.label),h=c(n.items).filter(o=>(o==null?void 0:o.type)!=="Range"&&g(v(o)).id).length;let w=0;for(const o of c(n.items)){if((o==null?void 0:o.type)==="Range"){s(o);continue}const e=g(v(o));if(!e.id)continue;const f=w++;if(!b||!e.rect)continue;const{x,y:T,w:I,h:S}=e.rect,u=A(n.id,f);i.push({id:u,setId:l,canvasId:e.id,target:{id:e.id,rect:e.rect},motivation:["highlighting"],bodies:d,...h>1?{place:{index:f+1,total:h}}:{},annotation:{id:u,type:"Annotation",motivation:["highlighting"],...d.length&&{body:d.map(({value:$,language:y})=>({type:"TextualBody",value:$,...y?{language:y}:{}}))},target:`${e.id}#xywh=${x},${T},${I},${S}`}})}};c(t.structures).forEach(s);const p=i.length?{id:l,source:"contents",entries:i}:null;return a.set(t,p),p}export{j as contentsSet};
1
+ import{az as c,bA as l,bv as g,bB as v,ba as A}from"./viewer-BDXZbbZI.mjs";const E=t=>t&&typeof t=="object"?Object.entries(t).flatMap(([i,r])=>c(r).filter(s=>typeof s=="string").map(s=>({value:s,...i!=="none"?{language:i}:{}}))):typeof t=="string"?[{value:t}]:[],a=new WeakMap;function j(t){if(!t)return null;if(a.has(t))return a.get(t);const i=[],r=new Set,s=n=>{if(!n||r.has(n.id??n))return;r.add(n.id??n);const b=typeof n.id=="string"&&!c(n.behavior).includes("no-nav"),d=E(n.label),h=c(n.items).filter(o=>(o==null?void 0:o.type)!=="Range"&&g(v(o)).id).length;let w=0;for(const o of c(n.items)){if((o==null?void 0:o.type)==="Range"){s(o);continue}const e=g(v(o));if(!e.id)continue;const f=w++;if(!b||!e.rect)continue;const{x,y:T,w:I,h:S}=e.rect,u=A(n.id,f);i.push({id:u,setId:l,canvasId:e.id,target:{id:e.id,rect:e.rect},motivation:["highlighting"],bodies:d,...h>1?{place:{index:f+1,total:h}}:{},annotation:{id:u,type:"Annotation",motivation:["highlighting"],...d.length&&{body:d.map(({value:$,language:y})=>({type:"TextualBody",value:$,...y?{language:y}:{}}))},target:`${e.id}#xywh=${x},${T},${I},${S}`}})}};c(t.structures).forEach(s);const p=i.length?{id:l,source:"contents",entries:i}:null;return a.set(t,p),p}export{j as contentsSet};
@@ -1 +1 @@
1
- import{Y as f,u as r,A as u,Z as p,_ as d,k as m}from"./viewer-Ds1v3IFN.mjs";import"./styles-ihp-vncb.mjs";const v=f(null),l=new WeakMap;function y(t){let n=l.get(t);if(!n){const{render:o}=t;n={canvasId:t.canvasId,format:t.format,match:t.match,component:c=>r(A,{...c,render:o})},l.set(t,n)}return n}function h(t){if(Array.isArray(t))return t.filter(n=>typeof n=="object"&&n!==null&&typeof n.render=="function").map(y)}function A({render:t,canvases:n,bodies:o,children:c}){const a=u(null),s=p(v);return d(()=>{const e=a.current;if(!e)return;const i=t(e,{canvases:n,bodies:o,clover:s});return()=>{typeof i=="function"&&i(),e.replaceChildren()}},[t,n,o,s]),r(m,{children:[r("div",{ref:a,className:"clover-body-renderer",style:{position:"absolute",inset:0}}),c&&r("div",{className:"clover-canvas-controls",children:c})]})}export{h as toRenderers};
1
+ import{Y as f,u as r,A as u,Z as p,_ as d,k as m}from"./viewer-BDXZbbZI.mjs";import"./styles-nU97HodU.mjs";const v=f(null),l=new WeakMap;function y(t){let n=l.get(t);if(!n){const{render:o}=t;n={canvasId:t.canvasId,format:t.format,match:t.match,component:c=>r(A,{...c,render:o})},l.set(t,n)}return n}function h(t){if(Array.isArray(t))return t.filter(n=>typeof n=="object"&&n!==null&&typeof n.render=="function").map(y)}function A({render:t,canvases:n,bodies:o,children:c}){const a=u(null),s=p(v);return d(()=>{const e=a.current;if(!e)return;const i=t(e,{canvases:n,bodies:o,clover:s});return()=>{typeof i=="function"&&i(),e.replaceChildren()}},[t,n,o,s]),r(m,{children:[r("div",{ref:a,className:"clover-body-renderer",style:{position:"absolute",inset:0}}),c&&r("div",{className:"clover-canvas-controls",children:c})]})}export{h as toRenderers};
@@ -1 +1 @@
1
- import{bW as a}from"./viewer-Ds1v3IFN.mjs";function c(t){try{const o=new URL(t).pathname.split("/").filter(Boolean).pop();return o?decodeURIComponent(o):"download"}catch{return"download"}}async function i(t,o){try{const r=await a(o,t,{referrerPolicy:"no-referrer"});if(!r.ok)return false;const n=URL.createObjectURL(await r.blob()),e=document.createElement("a");return e.href=n,e.download=c(t),document.body.append(e),e.click(),e.remove(),setTimeout(()=>URL.revokeObjectURL(n),1e4),true}catch{return false}}export{c as fileName,i as saveFile};
1
+ import{bW as a}from"./viewer-BDXZbbZI.mjs";function c(t){try{const o=new URL(t).pathname.split("/").filter(Boolean).pop();return o?decodeURIComponent(o):"download"}catch{return"download"}}async function i(t,o){try{const r=await a(o,t,{referrerPolicy:"no-referrer"});if(!r.ok)return false;const n=URL.createObjectURL(await r.blob()),e=document.createElement("a");return e.href=n,e.download=c(t),document.body.append(e),e.click(),e.remove(),setTimeout(()=>URL.revokeObjectURL(n),1e4),true}catch{return false}}export{c as fileName,i as saveFile};
@@ -1 +1 @@
1
- import{bE as b,az as f,bv as w,bF as S}from"./viewer-Ds1v3IFN.mjs";const x=10;async function R(r,t,s,o,e){var n,d;const i=(n=r.get().manifest)==null?void 0:n.id;try{const{hits:c,set:u}=await A(t,s,{request:o,signal:e});if(e.aborted||((d=r.get().manifest)==null?void 0:d.id)!==i)return;r.set({search:{query:s,status:"ready",hits:c,set:u}})}catch{if(e.aborted)return;r.set({search:{query:s,status:"error",hits:[],set:null}})}}async function A(r,t,{request:s,signal:o}={}){const e=new URL(r.id);e.searchParams.set("q",t);const i=[];let n=e.toString();const d=new Set;for(;n&&i.length<x&&!d.has(n);){d.add(n);const c=await b(s,n,o);i.push(c),n=T(c)}return $(i,t)}function E(r){var e;const t=f(r)[0];if(typeof t=="string"||!t)return t;const s=t.full??t["@id"],o=(e=f(t.selector)[0])==null?void 0:e.value;return typeof o=="string"&&typeof s=="string"?`${s}#${o}`:s}function T(r){var o;const t=r.next??((o=r.within)==null?void 0:o.next),s=typeof t=="string"?t:(t==null?void 0:t.id)??(t==null?void 0:t["@id"]);return typeof s=="string"?s:null}function $(r,t){var e,i;const s=[],o=[];for(const n of r){const d=Array.isArray(n.resources),c=d?n.resources:f(n.items),u=new Map;for(const a of c){const p=a.id??a["@id"],m=d?E(a.on):f(a.target)[0],v=w(m);if(!p||!v.id)continue;const y=d?(e=a.resource)==null?void 0:e.chars:f(a.body).map(l=>l==null?void 0:l.value).find(l=>typeof l=="string"),I={id:p,setId:S,canvasId:v.id,target:v,motivation:["highlighting"],bodies:[{value:String(y??t)}],annotation:{id:p,type:"Annotation",motivation:["highlighting"],body:{type:"TextualBody",value:String(y??t)},target:m}};u.set(p,I),s.push(I)}const g=d?H(n,u):M(n,u),h=new Set(g.flatMap(a=>a.entryIds));o.push(...g);for(const a of u.values())h.has(a.id)||o.push({id:a.id,canvasId:a.canvasId,entryIds:[a.id],match:((i=a.bodies[0])==null?void 0:i.value)??t})}return{query:t,hits:o,set:{id:S,label:{none:[t]},source:"search",entries:s}}}function H(r,t){var o;const s=[];for(const e of f(r.hits)){const i=f(e.annotations).filter(n=>t.has(n));i.length&&s.push({id:i.join(" "),canvasId:t.get(i[0]).canvasId,entryIds:i,before:e.before,match:String(e.match??((o=t.get(i[0]).bodies[0])==null?void 0:o.value)??""),after:e.after})}return s}function M(r,t){var o,e;const s=[];for(const i of f(r.annotations))for(const n of f(i==null?void 0:i.items))if(f(n==null?void 0:n.motivation).includes("contextualizing"))for(const c of f(n.target)){const u=typeof(c==null?void 0:c.source)=="string"?c.source:(o=c==null?void 0:c.source)==null?void 0:o.id,g=u?t.get(u):void 0;if(!g)continue;const h=f(c.selector).find(a=>(a==null?void 0:a.type)==="TextQuoteSelector");s.push({id:`${n.id??u}#${u}`,canvasId:g.canvasId,entryIds:[g.id],before:h==null?void 0:h.prefix,match:String((h==null?void 0:h.exact)??((e=g.bodies[0])==null?void 0:e.value)??""),after:h==null?void 0:h.suffix})}return s}export{$ as readResults,A as search,R as searchInto};
1
+ import{bE as b,az as f,bv as w,bF as S}from"./viewer-BDXZbbZI.mjs";const x=10;async function R(r,t,s,o,e){var n,d;const i=(n=r.get().manifest)==null?void 0:n.id;try{const{hits:c,set:u}=await A(t,s,{request:o,signal:e});if(e.aborted||((d=r.get().manifest)==null?void 0:d.id)!==i)return;r.set({search:{query:s,status:"ready",hits:c,set:u}})}catch{if(e.aborted)return;r.set({search:{query:s,status:"error",hits:[],set:null}})}}async function A(r,t,{request:s,signal:o}={}){const e=new URL(r.id);e.searchParams.set("q",t);const i=[];let n=e.toString();const d=new Set;for(;n&&i.length<x&&!d.has(n);){d.add(n);const c=await b(s,n,o);i.push(c),n=T(c)}return $(i,t)}function E(r){var e;const t=f(r)[0];if(typeof t=="string"||!t)return t;const s=t.full??t["@id"],o=(e=f(t.selector)[0])==null?void 0:e.value;return typeof o=="string"&&typeof s=="string"?`${s}#${o}`:s}function T(r){var o;const t=r.next??((o=r.within)==null?void 0:o.next),s=typeof t=="string"?t:(t==null?void 0:t.id)??(t==null?void 0:t["@id"]);return typeof s=="string"?s:null}function $(r,t){var e,i;const s=[],o=[];for(const n of r){const d=Array.isArray(n.resources),c=d?n.resources:f(n.items),u=new Map;for(const a of c){const p=a.id??a["@id"],m=d?E(a.on):f(a.target)[0],v=w(m);if(!p||!v.id)continue;const y=d?(e=a.resource)==null?void 0:e.chars:f(a.body).map(l=>l==null?void 0:l.value).find(l=>typeof l=="string"),I={id:p,setId:S,canvasId:v.id,target:v,motivation:["highlighting"],bodies:[{value:String(y??t)}],annotation:{id:p,type:"Annotation",motivation:["highlighting"],body:{type:"TextualBody",value:String(y??t)},target:m}};u.set(p,I),s.push(I)}const g=d?H(n,u):M(n,u),h=new Set(g.flatMap(a=>a.entryIds));o.push(...g);for(const a of u.values())h.has(a.id)||o.push({id:a.id,canvasId:a.canvasId,entryIds:[a.id],match:((i=a.bodies[0])==null?void 0:i.value)??t})}return{query:t,hits:o,set:{id:S,label:{none:[t]},source:"search",entries:s}}}function H(r,t){var o;const s=[];for(const e of f(r.hits)){const i=f(e.annotations).filter(n=>t.has(n));i.length&&s.push({id:i.join(" "),canvasId:t.get(i[0]).canvasId,entryIds:i,before:e.before,match:String(e.match??((o=t.get(i[0]).bodies[0])==null?void 0:o.value)??""),after:e.after})}return s}function M(r,t){var o,e;const s=[];for(const i of f(r.annotations))for(const n of f(i==null?void 0:i.items))if(f(n==null?void 0:n.motivation).includes("contextualizing"))for(const c of f(n.target)){const u=typeof(c==null?void 0:c.source)=="string"?c.source:(o=c==null?void 0:c.source)==null?void 0:o.id,g=u?t.get(u):void 0;if(!g)continue;const h=f(c.selector).find(a=>(a==null?void 0:a.type)==="TextQuoteSelector");s.push({id:`${n.id??u}#${u}`,canvasId:g.canvasId,entryIds:[g.id],before:h==null?void 0:h.prefix,match:String((h==null?void 0:h.exact)??((e=g.bodies[0])==null?void 0:e.value)??""),after:h==null?void 0:h.suffix})}return s}export{$ as readResults,A as search,R as searchInto};