@nulib/clover 4.1.0 → 4.2.0
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.
- package/dist/components/Body/useControlsVisibility.mjs +35 -13
- package/dist/components/Panel/Panel.mjs +47 -59
- package/dist/components/Panel/sections.mjs +62 -0
- package/dist/index.d.mts +70 -6
- package/dist/index.mjs +2 -0
- package/dist/lib/pointer.mjs +1 -1
- package/dist/styles.css +1 -1
- package/dist/templates/default/Default.mjs +5 -0
- package/dist/templates/document/Document.mjs +10 -1
- package/dist/templates/gallery/Gallery.mjs +4 -0
- package/dist/templates/index.d.mts +68 -3
- package/dist/templates/shared/LightboxView.mjs +5 -0
- package/dist/templates/shared/PanelPane.mjs +13 -1
- package/dist/web-components/{About-DvyvVUK5.mjs → About-D1TBGGPL.mjs} +1 -1
- package/dist/web-components/{AnnotationItems-BpRcSrOM.mjs → AnnotationItems-DTacmRA9.mjs} +1 -1
- package/dist/web-components/{AnnotationMenu-BDPec3iI.mjs → AnnotationMenu-DYc9ekWS.mjs} +1 -1
- package/dist/web-components/{AnnotationState-Chs_37Kk.mjs → AnnotationState--5ghW0C2.mjs} +1 -1
- package/dist/web-components/{Annotations-CLPEq7Ro.mjs → Annotations-BG8lPjk1.mjs} +1 -1
- package/dist/web-components/{Annotations-6E-oD_wg.mjs → Annotations-Bvc_FmJ5.mjs} +1 -1
- package/dist/web-components/{Body-Ct61yxI7.mjs → Body-QQ1DmnbP.mjs} +1 -1
- package/dist/web-components/{BodyAlert-C_Qh3Up_.mjs → BodyAlert-A4xRjOKr.mjs} +1 -1
- package/dist/web-components/{Button-L8ZMy5lY.mjs → Button-Cx6VE_UW.mjs} +1 -1
- package/dist/web-components/{Camera-BPyLzZjP.mjs → Camera-DqT_1MgD.mjs} +1 -1
- package/dist/web-components/{Canvas2DBackend-8wFavYdl.mjs → Canvas2DBackend-TZtR3zHf.mjs} +1 -1
- package/dist/web-components/{CanvasView-2Fj9nT06.mjs → CanvasView-DxZASM9E.mjs} +1 -1
- package/dist/web-components/{CaptionDetails-DuwS-grE.mjs → CaptionDetails-DMRWmtaY.mjs} +1 -1
- package/dist/web-components/{ChaptersMenu-Bj2EqtVJ.mjs → ChaptersMenu-BAZVVDrK.mjs} +1 -1
- package/dist/web-components/{Chevron-Cyr_cc9X.mjs → Chevron-DFGbSGPI.mjs} +1 -1
- package/dist/web-components/{ChoiceMenu-ConzybVH.mjs → ChoiceMenu-C80kdxvq.mjs} +1 -1
- package/dist/web-components/{Collection-CLayN8sv.mjs → Collection-B4CxBsFL.mjs} +1 -1
- package/dist/web-components/{CollectionSelect-D2d8dGJ4.mjs → CollectionSelect-DO8YO2p7.mjs} +1 -1
- package/dist/web-components/{Connected-pyd0EBD3.mjs → Connected-CcbVqzmj.mjs} +1 -1
- package/dist/web-components/{Connected-CBQ6xyhr.mjs → Connected-DthCPaHl.mjs} +1 -1
- package/dist/web-components/{Connected-DMXG3imZ.mjs → Connected-sYBn_9MK.mjs} +1 -1
- package/dist/web-components/{Contents-tCMXBYDK.mjs → Contents-AVPYYXht.mjs} +1 -1
- package/dist/web-components/{ControlMenu-D1zkB0qX.mjs → ControlMenu-BjJsWnuZ.mjs} +1 -1
- package/dist/web-components/ControlsFade-C-6WhSxB.mjs +1 -0
- package/dist/web-components/{CountMenu-Dnzb7lKo.mjs → CountMenu-Dx8D_RJZ.mjs} +1 -1
- package/dist/web-components/Cue-xuo5dgKE.mjs +1 -0
- package/dist/web-components/Document-BWdafeEi.mjs +1 -0
- package/dist/web-components/{DomLayers-BxPU05-D.mjs → DomLayers-DlRapZ1u.mjs} +1 -1
- package/dist/web-components/{Download-Bku9Vptk.mjs → Download-Ci_JUTVd.mjs} +1 -1
- package/dist/web-components/{EntryBodies-77vDudCb.mjs → EntryBodies-C0ICfS2R.mjs} +1 -1
- package/dist/web-components/{EntryThumbnail-BxQWKW6e.mjs → EntryThumbnail-DxHhfRo_.mjs} +1 -1
- package/dist/web-components/{FieldPill-nFGsaru9.mjs → FieldPill-CVfeeafm.mjs} +1 -1
- package/dist/web-components/{FrameAnimation-BvKiSXcm.mjs → FrameAnimation-AZpVvu0R.mjs} +1 -1
- package/dist/web-components/{Gallery-4Hd58afA.mjs → Gallery-C2PTJmvN.mjs} +1 -1
- package/dist/web-components/{HideToggle-TEhY4TS4.mjs → HideToggle-0nlIo-f8.mjs} +1 -1
- package/dist/web-components/{ImageControls-CZO7WoPb.mjs → ImageControls-tKVAMpaj.mjs} +1 -1
- package/dist/web-components/{Items-CudZ4Lnb.mjs → Items-Drd82_Jj.mjs} +1 -1
- package/dist/web-components/{Label-f07N5Fld.mjs → Label-BIjqJ-_T.mjs} +1 -1
- package/dist/web-components/{LanguageChoice-B5VM21DV.mjs → LanguageChoice-DkSc-n6g.mjs} +1 -1
- package/dist/web-components/LightboxView-Cuqx2H1m.mjs +1 -0
- package/dist/web-components/{ListEnd-M39M62Cl.mjs → ListEnd-pq-BgaDI.mjs} +1 -1
- package/dist/web-components/{Loaded-oGFyBuos.mjs → Loaded-CSO5NFhm.mjs} +1 -1
- package/dist/web-components/{LoadedCanvas-IvpSzPO6.mjs → LoadedCanvas-DK6xMmM1.mjs} +1 -1
- package/dist/web-components/LoadedMap-DmPH-LKY.mjs +1 -0
- package/dist/web-components/{Loading-YxuKrDAM.mjs → Loading-CoJLSRkv.mjs} +1 -1
- package/dist/web-components/{Map-Cw9j3gi3.mjs → Map-BEVtD52O.mjs} +1 -1
- package/dist/web-components/{MapView-3OxoCr5l.mjs → MapView-DHJcn9gW.mjs} +2 -2
- package/dist/web-components/{Markup-DW75Jx3j.mjs → Markup-Hm6bWOjm.mjs} +1 -1
- package/dist/web-components/{MediaBody-CLtd0bf0.mjs → MediaBody-BpgNtpKZ.mjs} +1 -1
- package/dist/web-components/{MediaBody-JnKnoIqY.mjs → MediaBody-Co23JjUJ.mjs} +1 -1
- package/dist/web-components/{NavDate-BCCOyycx.mjs → NavDate-CYNK0Qmp.mjs} +1 -1
- package/dist/web-components/{Navigator-Bx4zS0Yr.mjs → Navigator-DrYPepzN.mjs} +1 -1
- package/dist/web-components/{Pager-B9GvQ64b.mjs → Pager-CN4lHURv.mjs} +1 -1
- package/dist/web-components/{PagerLayout-BF33VZL_.mjs → PagerLayout-DeqnSQcF.mjs} +1 -1
- package/dist/web-components/Panel-CFYUlXup.mjs +1 -0
- package/dist/web-components/PanelPart-CpUIRbxr.mjs +1 -0
- package/dist/web-components/{PanelToggle-bPcIULGZ.mjs → PanelToggle-9ud55NNI.mjs} +1 -1
- package/dist/web-components/{PartOfManifest-HLg-r00O.mjs → PartOfManifest-KUHUq-6q.mjs} +1 -1
- package/dist/web-components/{Pending-BxGjjnqq.mjs → Pending-mcmdyZPA.mjs} +1 -1
- package/dist/web-components/{PlaceBox-D-Zhe9-U.mjs → PlaceBox-DX4ZLDat.mjs} +1 -1
- package/dist/web-components/{Placeholder-DzY5hcbk.mjs → Placeholder-0hE8q-SY.mjs} +1 -1
- package/dist/web-components/{Position-TYnzcm8e.mjs → Position-DO5qg5Sp.mjs} +1 -1
- package/dist/web-components/{Primitives-C6VJXxZD.mjs → Primitives-c9sIz0oQ.mjs} +1 -1
- package/dist/web-components/{Provider-DyB0wpeO.mjs → Provider-a3xY016W.mjs} +1 -1
- package/dist/web-components/{ReadMore-De_0T7lc.mjs → ReadMore-D_WmmKEP.mjs} +1 -1
- package/dist/web-components/{Root-Bt3NNBFb.mjs → Root-CU1o0wje.mjs} +1 -1
- package/dist/web-components/Scene-CboEeptc.mjs +1 -0
- package/dist/web-components/SceneView-hcc78jQT.mjs +1 -0
- package/dist/web-components/{Search-DgT8OPsK.mjs → Search-BgxEW1UT.mjs} +1 -1
- package/dist/web-components/{Sections-d1acn7qm.mjs → Sections-DZVrhoAC.mjs} +1 -1
- package/dist/web-components/{StandaloneItems-DUb4YKCB.mjs → StandaloneItems-6cSw7nbF.mjs} +1 -1
- package/dist/web-components/{Status-CcU3u6P4.mjs → Status-DHTzuTkh.mjs} +1 -1
- package/dist/web-components/{Steps-nlSCzbDQ.mjs → Steps-Dkpy9KiJ.mjs} +1 -1
- package/dist/web-components/{TargetItems-BDJM3Ar-.mjs → TargetItems-CyOI9_Z4.mjs} +1 -1
- package/dist/web-components/Timeline-B9tD3Rar.mjs +1 -0
- package/dist/web-components/{Tip-OCB88zwY.mjs → Tip-nJSTYquc.mjs} +1 -1
- package/dist/web-components/{Transcript-bSA3cx_K.mjs → Transcript-WvFFAJQM.mjs} +1 -1
- package/dist/web-components/{Transport-DjOYI-fR.mjs → Transport-FxLp_bdW.mjs} +1 -1
- package/dist/web-components/Transport-VUxSEIQO.mjs +1 -0
- package/dist/web-components/{annotation-collection-D8emkElk.mjs → annotation-collection-BkC3nBPA.mjs} +1 -1
- package/dist/web-components/{annotation-name-DbWjhgra.mjs → annotation-name-Du2KAWoD.mjs} +1 -1
- package/dist/web-components/{annotations-content-Bg6aVAGC.mjs → annotations-content-CEzAS-P2.mjs} +1 -1
- package/dist/web-components/{body-Ct8dmQdW.mjs → body-DPlfbLt3.mjs} +1 -1
- package/dist/web-components/{canvas-goEZLqEd.mjs → canvas-BUwBftJW.mjs} +1 -1
- package/dist/web-components/{cloverEngine-Df7cMwOP.mjs → cloverEngine-UNw5K4Xg.mjs} +1 -1
- package/dist/web-components/{content-state-reader-CNmBpG1L.mjs → content-state-reader-GgQF2MvJ.mjs} +1 -1
- package/dist/web-components/{controls-BZr16sYQ.mjs → controls-CC9G5LxK.mjs} +1 -1
- package/dist/web-components/custom-elements.json +31 -1
- package/dist/web-components/{downloads-EjJ6Hpip.mjs → downloads-CmAYeEIz.mjs} +1 -1
- package/dist/web-components/{dragToClose-X9NbZOhA.mjs → dragToClose-DK-eM097.mjs} +1 -1
- package/dist/web-components/{engine-DMoc0tff.mjs → engine-Dok0z8WP.mjs} +1 -1
- package/dist/web-components/{engines-BmB81VXR.mjs → engines-BD2IfwQF.mjs} +1 -1
- package/dist/web-components/{fetchManifest-CwQC6cCh.mjs → fetchManifest-tQXcfFiz.mjs} +1 -1
- package/dist/web-components/{fromManifest-DrAmY1lB.mjs → fromManifest-BwQdeAuL.mjs} +1 -1
- package/dist/web-components/{glyphs-BFK_hvJJ.mjs → glyphs-dp_HK3Ja.mjs} +1 -1
- package/dist/web-components/{hooks-BhtNDs_1.mjs → hooks-C4dJ5K_D.mjs} +1 -1
- package/dist/web-components/{image-layers-D2nQC4R-.mjs → image-layers-xcBsiad9.mjs} +1 -1
- package/dist/web-components/{imageService-iFElsopt.mjs → imageService-4sFnmAFX.mjs} +1 -1
- package/dist/web-components/index-DspT4wUm.mjs +1 -0
- package/dist/web-components/index.d.mts +1 -1
- package/dist/web-components/index.mjs +1 -1
- package/dist/web-components/{items-BnEnc5ot.mjs → items-BUmOy2QY.mjs} +1 -1
- package/dist/web-components/items-CWMI53aN.mjs +1 -0
- package/dist/web-components/label-BGjL7I4b.mjs +1 -0
- package/dist/web-components/{layout-Djwu8f4R.mjs → layout-B29v2RKK.mjs} +1 -1
- package/dist/web-components/{link-0lUlTZlw.mjs → link-Ct5PpHEY.mjs} +1 -1
- package/dist/web-components/logo-BFstM-0a.mjs +1 -0
- package/dist/web-components/{models-BF2pqufA.mjs → models-BXcT4ijX.mjs} +1 -1
- package/dist/web-components/{nodes-ChQRLDGU.mjs → nodes-BleXuYE6.mjs} +1 -1
- package/dist/web-components/{overlayImage-MKrcgDep.mjs → overlayImage-BJtfot4Y.mjs} +1 -1
- package/dist/web-components/{panel-C13V6w6E.mjs → panel-BxxV_JkD.mjs} +1 -1
- package/dist/web-components/part-D4gjnYmT.mjs +1 -0
- package/dist/web-components/{playerSurface-DG1XipTq.mjs → playerSurface-BXNLaFk0.mjs} +1 -1
- package/dist/web-components/{pointer-YQppt0at.mjs → pointer-CJELU3gI.mjs} +1 -1
- package/dist/web-components/{provider-DiUkZYiW.mjs → provider-CPp0Sgr_.mjs} +1 -1
- package/dist/web-components/{range-regions-CqGjyM76.mjs → range-regions-DAaOu0IS.mjs} +1 -1
- package/dist/web-components/{read-more-D8RJYdtQ.mjs → read-more-lcqGslUd.mjs} +1 -1
- package/dist/web-components/{readingLanguages-BWOLZK2k.mjs → readingLanguages-FyVsSWJ8.mjs} +1 -1
- package/dist/web-components/{rendererSurface-BkbGDL_Z.mjs → rendererSurface-nh6-EfuZ.mjs} +2 -2
- package/dist/web-components/{renderers-LtRX5pT0.mjs → renderers-BFS7hFVU.mjs} +1 -1
- package/dist/web-components/{resource-Cfydiy4m.mjs → resource-Bufu7lAr.mjs} +1 -1
- package/dist/web-components/{save-file-dZyOpXgY.mjs → save-file-CoknKOPz.mjs} +1 -1
- package/dist/web-components/{search-BfUZJM3a.mjs → search-5ocrsYmT.mjs} +1 -1
- package/dist/web-components/{shared-DkY2a89G.mjs → shared-DFAX0n3B.mjs} +1 -1
- package/dist/web-components/{show-link-DgLJzG7k.mjs → show-link-DBaJj4s_.mjs} +1 -1
- package/dist/web-components/{sizedImage-NHzhcBYk.mjs → sizedImage-jnOGcIIZ.mjs} +1 -1
- package/dist/web-components/{split-CuFiKjin.mjs → split-P6J0qqf5.mjs} +1 -1
- package/dist/web-components/{status-C3etlkhY.mjs → status-honoOMNx.mjs} +1 -1
- package/dist/web-components/styles-BwkYiCLC.mjs +1 -0
- package/dist/web-components/three.mjs +1 -1
- package/dist/web-components/{thumbnail-DecrVnpj.mjs → thumbnail-EbURh-UM.mjs} +1 -1
- package/dist/web-components/{tip-D5YgaIWW.mjs → tip-BhNI83aT.mjs} +1 -1
- package/dist/web-components/{toggle-CZGB65VZ.mjs → toggle-CJKdi5KH.mjs} +1 -1
- package/dist/web-components/{useContainerName-hKQjEt7a.mjs → useContainerName-_48Cdi0m.mjs} +1 -1
- package/dist/web-components/useControlsVisibility-CieBxGnK.mjs +1 -0
- package/dist/web-components/useLazyPanelPane-Da3kJiOt.mjs +1 -0
- package/dist/web-components/{useNearViewport-CDbHQUBk.mjs → useNearViewport-B34ebmIW.mjs} +1 -1
- package/dist/web-components/{useScrollTrack-D9l_P3_B.mjs → useScrollTrack-DgRGFeP5.mjs} +1 -1
- package/dist/web-components/viewer/{AnnotationItems-DtsnDXPM.mjs → AnnotationItems-BNA_92Dv.mjs} +1 -1
- package/dist/web-components/viewer/{AnnotationMenu-C-Mz6CCn.mjs → AnnotationMenu-BIQYVR4N.mjs} +1 -1
- package/dist/web-components/viewer/{AnnotationState-5pim5K72.mjs → AnnotationState-BbwQqA1U.mjs} +1 -1
- package/dist/web-components/viewer/{Annotations-Cqn1TkzD.mjs → Annotations-CZzOZAFP.mjs} +1 -1
- package/dist/web-components/viewer/{Annotations-CxwN9FkB.mjs → Annotations-P4XzAlNc.mjs} +1 -1
- package/dist/web-components/viewer/{Canvas2DBackend-C-ZMSCak.mjs → Canvas2DBackend-DFfCzyjL.mjs} +1 -1
- package/dist/web-components/viewer/{CaptionDetails-CRD-gSZP.mjs → CaptionDetails-DPtE-RQQ.mjs} +1 -1
- package/dist/web-components/viewer/{ChaptersMenu-Brcq3yJv.mjs → ChaptersMenu-D6Jmujag.mjs} +1 -1
- package/dist/web-components/viewer/{ChoiceMenu-ByGzQQx1.mjs → ChoiceMenu-GkqyTQRQ.mjs} +1 -1
- package/dist/web-components/viewer/{Collection-m0GCcsfQ.mjs → Collection-DjY_6qa6.mjs} +1 -1
- package/dist/web-components/viewer/{Connected-Dvx7wtot.mjs → Connected-D5T-mtiy.mjs} +1 -1
- package/dist/web-components/viewer/Connected-DIOuI3Mv.mjs +1 -0
- package/dist/web-components/viewer/{Contents-CwDpfiJY.mjs → Contents-DV-VxXuf.mjs} +1 -1
- package/dist/web-components/viewer/{ControlMenu-TcO85hDf.mjs → ControlMenu-BsEpff6N.mjs} +1 -1
- package/dist/web-components/viewer/ControlsFade-BowtN96W.mjs +1 -0
- package/dist/web-components/viewer/{CountMenu-0-ie8kIZ.mjs → CountMenu-DCmA6HdK.mjs} +1 -1
- package/dist/web-components/viewer/Cue-BjbVzrpl.mjs +1 -0
- package/dist/web-components/viewer/Document-4ZQd3W3o.mjs +1 -0
- package/dist/web-components/viewer/{DomLayers-hc0qARQc.mjs → DomLayers-BCwCxPDU.mjs} +1 -1
- package/dist/web-components/viewer/{Download-MO-1Rik4.mjs → Download-CL4IClAD.mjs} +1 -1
- package/dist/web-components/viewer/{EntryBodies-g-OEwEsk.mjs → EntryBodies-e40y47bl.mjs} +1 -1
- package/dist/web-components/viewer/{EntryThumbnail-DcIDYATi.mjs → EntryThumbnail-B_dP3w4o.mjs} +1 -1
- package/dist/web-components/viewer/{FieldPill-B9S21lxw.mjs → FieldPill-Hse1cDBE.mjs} +1 -1
- package/dist/web-components/viewer/{FrameAnimation-qI9cZPEs.mjs → FrameAnimation-CE218DCr.mjs} +1 -1
- package/dist/web-components/viewer/{Gallery-BOgUqfqw.mjs → Gallery-F2sVj4ph.mjs} +1 -1
- package/dist/web-components/viewer/{HideToggle-D8wH49mq.mjs → HideToggle-CYoqe_ez.mjs} +1 -1
- package/dist/web-components/viewer/{ImageControls-ZoEC9jWd.mjs → ImageControls-C2G4x2Es.mjs} +1 -1
- package/dist/web-components/viewer/{LanguageChoice-CRqsCBAp.mjs → LanguageChoice-BmO-322r.mjs} +1 -1
- package/dist/web-components/viewer/LightboxView-DKR8dXcg.mjs +1 -0
- package/dist/web-components/viewer/{ListEnd-D9Obxie4.mjs → ListEnd-DX1jsvJk.mjs} +1 -1
- package/dist/web-components/viewer/{MapView-DQSwUzd7.mjs → MapView-Df0wZjCh.mjs} +2 -2
- package/dist/web-components/viewer/{MediaBody-CIw2nTlj.mjs → MediaBody-CataNonO.mjs} +1 -1
- package/dist/web-components/viewer/{MediaBody-D5ff6xy-.mjs → MediaBody-SkIgrEMj.mjs} +1 -1
- package/dist/web-components/viewer/{NavDate-BnfDG57h.mjs → NavDate-BZgeaMG9.mjs} +1 -1
- package/dist/web-components/viewer/{Navigator-BNwjmkXY.mjs → Navigator-Co76p-1n.mjs} +1 -1
- package/dist/web-components/viewer/{PagerLayout-C8jraHqs.mjs → PagerLayout-tUkN1-FV.mjs} +1 -1
- package/dist/web-components/viewer/PanelPart-Cl4Sst60.mjs +1 -0
- package/dist/web-components/viewer/{PartOfManifest-DX7H0V4g.mjs → PartOfManifest-DXnbEPzS.mjs} +1 -1
- package/dist/web-components/viewer/{PlaceBox-CCWfzsNU.mjs → PlaceBox-xrJ4CGdN.mjs} +1 -1
- package/dist/web-components/viewer/{Placeholder-CsEkLhz7.mjs → Placeholder-B1AcizHL.mjs} +1 -1
- package/dist/web-components/viewer/{Search-CsdYzdq1.mjs → Search-DTg1cHZ3.mjs} +1 -1
- package/dist/web-components/viewer/{StandaloneItems-BfvBxbUm.mjs → StandaloneItems-BpBEQG8i.mjs} +1 -1
- package/dist/web-components/viewer/{Steps-BH8ZApS4.mjs → Steps-SpwMQdCL.mjs} +1 -1
- package/dist/web-components/viewer/{TargetItems-BebPFr-c.mjs → TargetItems-B6Icep5k.mjs} +1 -1
- package/dist/web-components/viewer/{Transcript-DXLv5WR9.mjs → Transcript-rTAhuXCF.mjs} +1 -1
- package/dist/web-components/viewer/{Transport-C-fh7Kx2.mjs → Transport-vKIDALE-.mjs} +1 -1
- package/dist/web-components/viewer/Transport-z_kdVisw.mjs +1 -0
- package/dist/web-components/viewer/{annotation-collection-Cjd8Dgyl.mjs → annotation-collection-B7pZiLVk.mjs} +1 -1
- package/dist/web-components/viewer/{annotation-name-CwmgQFia.mjs → annotation-name-BKj1O9lA.mjs} +1 -1
- package/dist/web-components/viewer/{annotations-content-BARXoAz-.mjs → annotations-content-9AtLlPNn.mjs} +1 -1
- package/dist/web-components/viewer/{cloverEngine-CumnJPKO.mjs → cloverEngine-jRrYLrWa.mjs} +1 -1
- package/dist/web-components/viewer/{content-state-reader-DuvyLThu.mjs → content-state-reader-CPvkju6Q.mjs} +1 -1
- package/dist/web-components/viewer/{dragToClose-CFCxhUxn.mjs → dragToClose-Co9kGk9q.mjs} +1 -1
- package/dist/web-components/viewer/{fetchManifest-qNB_KgxL.mjs → fetchManifest-D7N9WhhF.mjs} +1 -1
- package/dist/web-components/viewer/{host-GTHX2fPK.mjs → host-DMD9LE4H.mjs} +1 -1
- package/dist/web-components/viewer/{image-layers-DKOuaRTj.mjs → image-layers-x_shzPvu.mjs} +1 -1
- package/dist/web-components/viewer/index.mjs +1 -1
- package/dist/web-components/viewer/{link-BlaM0tCa.mjs → link-DikPGzNO.mjs} +1 -1
- package/dist/web-components/viewer/{overlayImage-RVpv69R5.mjs → overlayImage-33kKKB0T.mjs} +1 -1
- package/dist/web-components/viewer/{range-regions-CIZiAHOp.mjs → range-regions-TH6WWGTT.mjs} +1 -1
- package/dist/web-components/viewer/{renderers-Dw1klwlx.mjs → renderers-BxePmixF.mjs} +1 -1
- package/dist/web-components/viewer/{save-file-EvzaBEJN.mjs → save-file-QXKiPlST.mjs} +1 -1
- package/dist/web-components/viewer/{search-x1QL_bth.mjs → search-B_NePyas.mjs} +1 -1
- package/dist/web-components/viewer/styles-Bedyz7_l.mjs +1 -0
- package/dist/web-components/viewer/useControlsVisibility-Cu-jTDzs.mjs +1 -0
- package/dist/web-components/viewer/useLazyPanelPane-BhLtRixT.mjs +1 -0
- package/dist/web-components/viewer/viewer-nfPJPwwt.mjs +29 -0
- package/dist/web-components/viewer/{vtt-C2G89SWH.mjs → vtt-CUn4h5JB.mjs} +1 -1
- package/dist/web-components/viewer-DN2Mo3vc.mjs +1 -0
- package/dist/web-components/{vtt-Dd0c7psH.mjs → vtt-C5M5WPSG.mjs} +1 -1
- package/package.json +1 -1
- package/dist/web-components/ControlsFade-BNXVTL_Q.mjs +0 -1
- package/dist/web-components/Cue-CUGmPS3k.mjs +0 -1
- package/dist/web-components/Document-D-8nalCX.mjs +0 -1
- package/dist/web-components/LightboxView-C4OASmkg.mjs +0 -1
- package/dist/web-components/LoadedMap-WATGNLxl.mjs +0 -1
- package/dist/web-components/Panel-BvDpCn6K.mjs +0 -1
- package/dist/web-components/PanelPart-Bd4lSUrP.mjs +0 -1
- package/dist/web-components/Scene-DrOM9YlD.mjs +0 -1
- package/dist/web-components/SceneView-DA7Yg20p.mjs +0 -1
- package/dist/web-components/Timeline-BfdN3lIv.mjs +0 -1
- package/dist/web-components/Transport-DaIhfZqC.mjs +0 -1
- package/dist/web-components/index-FJEpXukG.mjs +0 -1
- package/dist/web-components/items-BPPrqbeh.mjs +0 -1
- package/dist/web-components/label-DauFa5sg.mjs +0 -1
- package/dist/web-components/logo-DWPxaZaG.mjs +0 -1
- package/dist/web-components/part-CekFWrtz.mjs +0 -1
- package/dist/web-components/styles-DkkVOSUQ.mjs +0 -1
- package/dist/web-components/useControlsVisibility-DPg8uAkW.mjs +0 -1
- package/dist/web-components/useLazyPanelPane-eby-OI1V.mjs +0 -1
- package/dist/web-components/viewer/Connected-Bmc_CdUD.mjs +0 -1
- package/dist/web-components/viewer/ControlsFade-BoZ4ABAE.mjs +0 -1
- package/dist/web-components/viewer/Cue-DxmAS9Gx.mjs +0 -1
- package/dist/web-components/viewer/Document-BsryuYJ1.mjs +0 -1
- package/dist/web-components/viewer/LightboxView-BB-GcbYr.mjs +0 -1
- package/dist/web-components/viewer/PanelPart-YNbBI9SQ.mjs +0 -1
- package/dist/web-components/viewer/Transport-CY6BWfMi.mjs +0 -1
- package/dist/web-components/viewer/styles-I7_LWFGj.mjs +0 -1
- package/dist/web-components/viewer/useControlsVisibility-C_SQHIVR.mjs +0 -1
- package/dist/web-components/viewer/useLazyPanelPane-UuGDJrf_.mjs +0 -1
- package/dist/web-components/viewer/viewer-DJrQuNs1.mjs +0 -29
- package/dist/web-components/viewer-Br44EEba.mjs +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as he,A as N,d as M,_ as z,T as Te,u as e,ai as B,l as F,ac as ke,y as Ne,k as le}from"./shared-
|
|
1
|
+
import{a as he,A as N,d as M,_ as z,T as Te,u as e,ai as B,l as F,ac as ke,y as Ne,k as le}from"./shared-DFAX0n3B.mjs";import{u as Ce,g as we,a as Ee,b as ce,l as Se,s as Pe,T as A,P as Fe,c as Ie,V as Oe,d as $e,C as Be,F as Me,e as Re,E as Ve,f as xe,p as De}from"./Transport-VUxSEIQO.mjs";import{imageSource as Ae}from"./thumbnail-EbURh-UM.mjs";import{u as Ke,P as Le,E as Ue}from"./EntryThumbnail-DxHhfRo_.mjs";import{j as je}from"./classnames-DukgfdpI.mjs";import{l as ue}from"./languageCode-cCpiU0b0.mjs";import{T as pe,S as ie}from"./Tip-nJSTYquc.mjs";import{u as qe}from"./useContainerName-_48Cdi0m.mjs";import{u as ze,t as _e}from"./pointer-CJELU3gI.mjs";import"./styles-BwkYiCLC.mjs";const Xe=a=>typeof(a==null?void 0:a.thumbnail)=="string"?{src:a.thumbnail}:Ae(a==null?void 0:a.thumbnail);function de(a,i){var h;let b=-1;a.forEach((I,C)=>{I.start<=i&&(b=C)});const f=(h=a[b])==null?void 0:h.end;return f!==void 0&&i>=f?-1:b}let q;function Ze(){if(q===void 0){if(typeof document>"u")return true;const a=document.createElement("video");a.volume=.5,q=a.volume===.5}return q}function Ge({id:a,label:i,labelLang:b,button:f,icon:h,active:I,current:C,options:O,selected:R,onSelect:l,request:K,asMenu:$=false}){const[p,m]=M(false),d=N(null),g=N(null),V=N(null),w=N(false),E=qe(i,b),T=O.some(r=>ue(r.language));ke(p,()=>m(false));const o=()=>{var r;m(false),(r=g.current)==null||r.focus()};return Ne(()=>{if(!p)return;const r=t=>{var c,u,k;if(t instanceof KeyboardEvent){if(t.key!=="Escape")return;(c=d.current)!=null&&c.contains(document.activeElement)&&(t.preventDefault(),(u=g.current)==null||u.focus())}else if((k=d.current)!=null&&k.contains(t.target))return;m(false)};return document.addEventListener("pointerdown",r),document.addEventListener("keydown",r,true),()=>{document.removeEventListener("pointerdown",r),document.removeEventListener("keydown",r,true)}},[p]),z(()=>{const r=V.current,t=d.current,c=t==null?void 0:t.closest(".clover-canvas-transport"),u=t==null?void 0:t.closest(".clover-canvas-media");if(!p||!r||!t||!c||!u)return;const k=()=>De(r,t,c,u);k();const S=new ResizeObserver(k);return S.observe(u),S.observe(c),S.observe(r),()=>S.disconnect()},[p]),e("div",{className:"clover-canvas-transport-menu",ref:d,onBlur:r=>{var c;const t=r.relatedTarget;p&&t instanceof Node&&!((c=d.current)!=null&&c.contains(t))&&m(false)},children:[e("button",{"aria-controls":a,"aria-describedby":C?`${a}-current`:void 0,"aria-expanded":p,"aria-label":i,...F(b),className:"clover-canvas-transport-button","data-active":I?"":void 0,"data-button":f,onClick:()=>m(r=>!r),ref:g,type:"button",children:[h,e(pe,{label:i})]}),C&&e("span",{hidden:true,id:`${a}-current`,...F(C.lang),children:C.label}),p&&E.node,p&&e("fieldset",{...E.props,className:je("clover-canvas-transport-options",$&&"clover-canvas-menu"),id:a,ref:V,children:O.map((r,t)=>{const c=ue(r.language);return e("label",{className:"clover-canvas-transport-option",onPointerDown:()=>{w.current=true},children:[e("input",{checked:R===t,name:a,onChange:()=>l(t),onClick:()=>{w.current&&o()},onKeyDown:u=>{w.current=false,u.key==="Enter"&&(u.preventDefault(),l(t),o())},type:"radio"}),r.time&&e(le,{children:[e("span",{className:"clover-cue-time",children:r.time})," "]}),T&&(c?e(le,{children:[e("span",{className:"clover-canvas-transport-code",children:c})," "]}):e("span",{className:"clover-canvas-transport-code","aria-hidden":"true"})),e("span",{className:"clover-cue-text",...F(r.lang),children:r.label}),R===t&&e(Ue,{source:r.thumbnail,request:K,large:true})]},t)})})]})}const Je=a=>a.querySelector(":scope > .clover-tip"),Qe=a=>{try{return a.matches(":focus-visible")}catch{return false}},ln=({instance:a,controller:i,kind:b,captions:f,activeCaption:h,onCaptionChange:I,fullscreen:C=false,isFullscreen:O=false,video:R,chapters:l=[],highlightedChapter:K=null,onChapterHighlight:$,request:p,fill:m})=>{var te,re;const{t:d,langOf:g}=he(),V=ze()||b==="video",w=N(null);Ce(w);const{paused:E,currentTime:T,duration:o,buffered:r,muted:t,volume:c}=i,u=de(l,T),[k,S]=M(-1),[_,me]=M(0),X=N(-1),Z=n=>{var s;X.current!==n&&(X.current=n,S(n),$==null||$(((s=l[n])==null?void 0:s.id)??null))},[G,J]=M(false),[x,Q]=M(false),y=x?k:G?u:-1,W=(x||G)&&o>0,ve=Ke(Xe(l[y]),Le,p),L=k>=0?k:l.findIndex(n=>n.id!==void 0&&n.id===K),Y=N(null);z(()=>{const n=Y.current,s=n==null?void 0:n.closest(".clover-canvas"),v=n&&y>=0?Je(n):null;if(!s||!v)return;const ae="--clover-transport-preview-top",oe=()=>s.style.setProperty(ae,`${s.getBoundingClientRect().bottom-v.getBoundingClientRect().top}px`);oe();const se=new ResizeObserver(oe);return se.observe(v),()=>{se.disconnect(),s.style.removeProperty(ae)}},[y]);const D=n=>{const{start:s,end:v=o}=l[n];return{left:s/o*100,width:(v-s)/o*100}},fe=E?"playerPlay":"playerPause",H={label:d("playerCaptionsOff"),lang:g("playerCaptionsOff")},ge=t?"playerUnmute":"playerMute",ye=O?"imageExitFullScreen":"imageFullScreen",ee=o?T/o*100:0,U=Te(()=>{const n=we(l,o);return n.length?Ee(n):void 0},[l,o]),be=o?r/o*100:0,j=C&&V,P=N(null),ne=N(null);return z(()=>{var v;const n=P.current;if(!n||n.isConnected)return;P.current=null;const s=document.activeElement;(!s||s===document.body)&&((v=ne.current)==null||v.focus())},[f.length,l.length,j]),e("div",{className:"clover-canvas-transport","data-kind":b,"data-testid":"clover-canvas-transport",onFocus:n=>{P.current=n.target},onBlur:n=>{const s=n.target,v=n.relatedTarget;if(v instanceof Node){n.currentTarget.contains(v)||(P.current=null);return}queueMicrotask(()=>{P.current===s&&s.isConnected&&(P.current=null)})},children:[e("div",{ref:Y,className:"clover-canvas-transport-seek-area",onPointerMove:n=>{if(!o||n.target.closest(".clover-tip"))return;const s=Pe(n.currentTarget,n.clientX)*o;Q(true),me(Math.floor(s)),Z(de(l,s))},onPointerLeave:()=>{Q(false),Z(-1)},style:W?{"--clover-transport-preview":ce(y>=0?D(y).left+D(y).width/2:(x?_:T)/o*100)}:void 0,children:[e("input",{"aria-label":d("playerSeek"),lang:g("playerSeek"),"aria-valuetext":`${B(T)} / ${B(o)}${u>=0?`, ${l[u].label}`:""}`,className:"clover-canvas-transport-seek",onFocus:n=>J(Qe(n.currentTarget)),onBlur:()=>J(false),max:o||0,min:0,onChange:n=>i.seek(Number(n.target.value)),step:"any","data-gaps":U?"":void 0,style:{"--clover-transport-progress":`${ee}%`,"--clover-transport-loaded":`${be}%`,...U&&{"--clover-transport-gaps":U,"--clover-transport-at":ee/100}},type:"range",value:T}),L>=0&&o>0&&e("span",{"aria-hidden":"true",className:"clover-canvas-transport-chapter-span",style:{left:ce(D(L).left),width:Se(D(L).width)}}),W&&e(pe,{lead:B(x?_:T),label:((te=l[y])==null?void 0:te.label)??"",lang:(re=l[y])==null?void 0:re.lang,image:y>=0?ve:void 0},y)]}),e("div",{className:"clover-canvas-transport-bar",ref:w,children:[e(A,{words:fe,button:E?"play":"pause",shortcut:ie.play,onClick:i.toggle,buttonRef:ne,children:E?e(Fe,{}):e(Ie,{})}),e(A,{words:ge,button:"mute",shortcut:ie.mute,onClick:i.toggleMute,children:t||c===0?e(Oe,{}):e($e,{})}),Ze()&&e("input",{"aria-label":d("playerVolume"),lang:g("playerVolume"),className:"clover-canvas-transport-volume",max:1,min:0,onChange:n=>i.setVolume(Number(n.target.value)),step:.05,style:{"--clover-transport-progress":`${(t?0:c)*100}%`},type:"range",value:t?0:c}),e("span",{className:"clover-canvas-transport-status",children:[e("span",{className:"clover-canvas-transport-time",children:[e("span",{"aria-label":d("playerCurrentTime"),...F(g("playerCurrentTime")),children:B(T)}),e("span",{"aria-hidden":"true",children:" / "}),e("span",{"aria-label":d("playerDuration"),...F(g("playerDuration")),children:B(o)})]}),u>=0&&e("span",{className:"clover-canvas-transport-chapter",...F(l[u].lang),children:l[u].label})]}),(f.length>0||j||m)&&e("div",{className:"clover-canvas-transport-end",children:[f.length>0&&e(Ge,{id:`${a}-captions`,label:d("playerCaptions"),labelLang:g("playerCaptions"),button:"captions",icon:e(Be,{on:h>=0}),active:h>=0,current:f[h]??H,options:[H,...f],selected:h+1,onSelect:n=>I(n-1)}),m&&e(A,{words:m.filled?"playerFit":"playerFill",button:"fill",onClick:m.onToggle,children:m.filled?e(Me,{}):e(Re,{})}),j&&e(A,{words:ye,button:"fullscreen",onClick:n=>void _e(n.currentTarget,R),children:O?e(Ve,{}):e(xe,{})})]})]})]})};export{ln as T,Xe as a,de as c};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as b,u as o,l as g,_ as m}from"./shared-DFAX0n3B.mjs";import{T as x}from"./Tip-nJSTYquc.mjs";import{f,g as k}from"./pointer-CJELU3gI.mjs";import{a as y}from"./index-DspT4wUm.mjs";function T({words:r,button:e,shortcut:t,disabled:n,pressed:s,onClick:a,buttonRef:c,children:v}){const{t:i,langOf:h}=b(),d=i(r);return o("button",{"aria-label":d,...g(h(r)),"aria-keyshortcuts":t==null?void 0:t.keys,"aria-disabled":n||void 0,"aria-pressed":s,className:"clover-canvas-transport-button","data-button":e,onClick:a,ref:c,type:"button",children:[v,o(x,{label:d,shortcut:t})]})}function B(r){m(()=>{const e=r.current,t=e==null?void 0:e.closest(".clover-canvas");if(!e||!t)return;const n=()=>{const a=e.offsetHeight;a&&t.style.setProperty("--clover-transport-bar-height",`${a}px`)};n();const s=new ResizeObserver(n);return s.observe(e),()=>{s.disconnect(),t.style.removeProperty("--clover-transport-bar-height")}},[r])}const p=r=>`var(--clover-transport-thumb) / 2 + (100% - var(--clover-transport-thumb)) * ${r/100}`,F=r=>`calc(${p(r)})`,H=r=>`calc((100% - var(--clover-transport-thumb)) * ${r/100})`;function P(r){const e="var(--clover-transport-gap) / 2";return`linear-gradient(to right, ${[...r.flatMap(n=>[`#000 0 calc(${p(n)} - ${e})`,`transparent 0 calc(${p(n)} + ${e})`]),"#000 0"].join(", ")})`}function $(r,e){if(!(e>0))return[];const t=(a,c)=>Math.abs(a-c)<.05,n=[],s=a=>{a>0&&a<e&&!n.some(c=>t(c,a))&&n.push(a)};for(const a of r)s(a.start);for(const a of r)a.end!==void 0&&Number.isFinite(a.end)&&!r.some(c=>t(c.start,a.end))&&s(a.end);return n.sort((a,c)=>a-c).map(a=>a/e*100)}function L(r,e){const t=r.querySelector("input")??r,n=t.getBoundingClientRect(),s=parseFloat(getComputedStyle(t).getPropertyValue("--clover-transport-thumb"))||0,a=n.width-s;return a>0?Math.min(1,Math.max(0,(e-n.left-s/2)/a)):0}function I(r,e,t,n){const s=n.getBoundingClientRect(),a=s.height-(t.getBoundingClientRect().bottom-e.getBoundingClientRect().top);r.style.setProperty("--clover-transport-menu-above",`${a}px`),r.style.removeProperty("--clover-transport-menu-shift");const c=r.getBoundingClientRect(),v=parseFloat(getComputedStyle(t).paddingRight)||0,i=Math.max(s.left+v-c.left,Math.min(0,s.right-v-c.right));i&&r.style.setProperty("--clover-transport-menu-shift",`${i}px`)}const l={xmlns:"http://www.w3.org/2000/svg",width:16,height:16,viewBox:"0 0 512 512","aria-hidden":true,focusable:false},S=()=>o("svg",{...l,children:o("path",{d:"M133 440a35.37 35.37 0 01-17.5-4.67c-12-6.8-19.46-20-19.46-34.33V111c0-14.37 7.46-27.53 19.46-34.33a35.13 35.13 0 0135.77.45l247.85 148.36a36 36 0 010 61.11L151.23 435a35.5 35.5 0 01-18.23 5z"})}),V=()=>o("svg",{...l,children:o("path",{d:"M224 432h-80V80h80zm144 0h-80V80h80z"})}),q=()=>o("svg",{...l,children:[o("path",{d:"M232 416a23.88 23.88 0 01-14.2-4.68 8.27 8.27 0 01-.66-.51L125.76 336H56a24 24 0 01-24-24V200a24 24 0 0124-24h69.75l91.37-74.81a8.27 8.27 0 01.66-.51A24 24 0 01256 120v272a24 24 0 01-24 24z"}),o("path",{d:"M320 336a16 16 0 01-14.29-23.16c8.34-16.63 12.29-34.5 12.29-56.84s-3.95-40.21-12.29-56.84a16 16 0 0128.58-14.32C345.06 205.86 350 228.13 350 256s-4.94 50.14-15.71 71.16A16 16 0 01320 336zM368 384a16 16 0 01-13.87-24C373.85 325.75 384 292.28 384 256c0-36.28-10.15-69.75-29.87-104a16 16 0 0127.74-16C404.19 174.71 416 214.17 416 256s-11.81 81.29-34.13 120A16 16 0 01368 384z",fillOpacity:"0.85"})]}),R=()=>o("svg",{...l,children:[o("path",{d:"M232 416a23.88 23.88 0 01-14.2-4.68 8.27 8.27 0 01-.66-.51L125.76 336H56a24 24 0 01-24-24V200a24 24 0 0124-24h69.75l91.37-74.81a8.27 8.27 0 01.66-.51A24 24 0 01256 120v272a24 24 0 01-24 24z"}),o("path",{d:"M320 196l128 120M448 196L320 316",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeWidth:"32"})]}),j=({on:r=false})=>o("svg",{...l,"data-on":r||void 0,className:"clover-captions-icon",children:[r?o("rect",{x:"22",y:"86",width:"468",height:"340",rx:"74",fill:"currentColor"}):o("rect",{x:"40",y:"104",width:"432",height:"304",rx:"56",fill:"none",stroke:"currentColor",strokeWidth:"36"}),o("path",{className:"clover-captions-icon-letters",d:"M228 216a48 48 0 1 0 0 80M356 216a48 48 0 1 0 0 80",fill:"none",stroke:r?"var(--clover-color-control, #1a1d1e)":"currentColor",strokeLinecap:"round",strokeWidth:"36"})]}),u=()=>o("rect",{x:"40",y:"104",width:"432",height:"304",rx:"56",fill:"none",stroke:"currentColor",strokeWidth:"36"}),W=()=>o("svg",{...l,children:[o(u,{}),o("path",{d:"M204 208l-48 48 48 48M308 208l48 48-48 48",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"36"})]}),O=()=>o("svg",{...l,children:[o(u,{}),o("path",{d:"M140 208l48 48-48 48M372 208l-48 48 48 48",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"36"})]}),A=()=>o("svg",{...l,children:o(k,{})}),N=()=>o("svg",{...l,children:o(f,{})});y(14,"components/Canvas/media/Transport",'@layer clover{.clover-canvas{--clover-transport-room: calc( var(--clover-transport-bar-height, var(--clover-control)) + var(--clover-space-l) + var(--clover-space-xs) + var(--clover-canvas-controls-inset) + var(--clover-space-m) )}.clover-canvas-transport{position:absolute;inset:auto 0 0;z-index:2;display:flex;flex-direction:column;padding:var(--clover-space-xl) var(--clover-canvas-controls-inset) var(--clover-canvas-controls-inset);--clover-controls-edge: 1;--clover-transport-thumb: 12px;--clover-transport-track: var(--clover-space-xs);-webkit-user-select:none;user-select:none;--clover-transport-menu-room: calc( 100cqb - var(--clover-canvas-controls-inset) - var(--clover-control) - var(--clover-space-s) - var(--clover-space-xs) )}.clover-canvas-transport:before{position:absolute;inset:0;z-index:-1;background:linear-gradient(to top,#000000c7,#0009 calc(100% - var(--clover-space-xl)),#0000);pointer-events:none;content:""}.clover-canvas-transport:has([aria-expanded=true],:focus-visible,>.clover-canvas-transport-seek-area:hover){z-index:4}.clover-canvas-transport-bar{display:flex;flex-wrap:wrap;align-items:center;gap:var(--clover-space-xs) var(--clover-space-s);min-width:0}.clover-canvas-transport-bar>*{flex-shrink:0}.clover-canvas-transport-bar>:is(:hover,:active,:focus-within){z-index:1}.clover-canvas-transport-bar>.clover-canvas-transport-status{display:flex;flex:1 1 0;align-items:center;gap:var(--clover-space-s);min-width:min-content}.clover-canvas-transport-end{display:flex;gap:var(--clover-space-s);margin-inline-start:auto}@container (max-width: 37.5rem){.clover-canvas-transport-bar:has([data-button=chapters])>.clover-canvas-transport-status{order:-1;flex-basis:100%}.clover-canvas-transport-status>.clover-canvas-transport-chapter{max-width:none}}@container (max-width: 28rem){.clover-canvas-transport-bar>.clover-canvas-transport-status{order:-1;flex-basis:100%}}.clover-canvas-transport-button svg{fill:currentColor;stroke:none}.clover-canvas-transport-button svg [stroke]{fill:none}.clover-canvas-transport-button:hover,.clover-canvas-transport-button:focus-visible{background-color:var(--clover-color-accent, #0065c3)}:where([data-high-contrast]) .clover-canvas-transport-button:is(:hover,:focus-visible){background-color:var(--clover-accent-fill)}:where([data-high-contrast]) .clover-canvas-transport-button:hover:not(:focus-visible){outline:var(--clover-accent-ring-hover);outline-offset:1px}button.clover-canvas-transport-button[aria-pressed=true]:after{content:"";position:absolute;inset-inline:var(--clover-space-s);bottom:var(--clover-space-2xs);border-bottom:2px solid;border-radius:1px}.clover-canvas-transport-button:focus-visible{outline:none;box-shadow:0 0 0 2px var(--clover-color-secondary, #fff),0 0 0 4px var(--clover-color-accent, #0065c3)}.clover-canvas-transport-seek-area{position:relative;display:flex;margin-bottom:var(--clover-space-xs);--clover-transport-gap: var(--clover-space-2xs)}.clover-canvas-transport input[type=range]{appearance:none;-webkit-appearance:none;width:100%;height:var(--clover-space-l);margin:0;background:transparent;cursor:pointer;touch-action:none}.clover-canvas-transport input.clover-canvas-transport-volume{width:var(--clover-space-2xl)}@container (max-width: 28rem){.clover-canvas-transport input.clover-canvas-transport-volume{width:var(--clover-space-xl)}.clover-canvas-transport-bar,.clover-canvas-transport-end{column-gap:var(--clover-space-xs)}}.clover-canvas-transport input[type=range]::-webkit-slider-runnable-track{height:var(--clover-transport-track);border-radius:var(--clover-radius, 3px);background:linear-gradient(to right,var(--clover-color-accent, #0065c3) var(--clover-transport-progress, 0%),rgb(255 255 255 / 90%) var(--clover-transport-progress, 0%),rgb(255 255 255 / 90%) var(--clover-transport-loaded, 0%),var(--clover-player-track, rgb(255 255 255 / 65%)) var(--clover-transport-loaded, 0%));box-shadow:var(--clover-player-track-shadow, none)}.clover-canvas-transport input[type=range]::-moz-range-track{height:var(--clover-transport-track);border-radius:var(--clover-radius, 3px);background:linear-gradient(to right,var(--clover-color-accent, #0065c3) var(--clover-transport-progress, 0%),rgb(255 255 255 / 90%) var(--clover-transport-progress, 0%),rgb(255 255 255 / 90%) var(--clover-transport-loaded, 0%),var(--clover-player-track, rgb(255 255 255 / 65%)) var(--clover-transport-loaded, 0%));box-shadow:var(--clover-player-track-shadow, none)}.clover-canvas-transport input[type=range]::-webkit-slider-thumb{-webkit-appearance:none;width:var(--clover-transport-thumb);height:var(--clover-transport-thumb);margin-top:calc((var(--clover-transport-track) - var(--clover-transport-thumb)) / 2);border:none;border-radius:var(--clover-radius-pill, 2rem);background-color:var(--clover-player-text, #fff)}.clover-canvas-transport input[type=range]::-moz-range-thumb{width:var(--clover-transport-thumb);height:var(--clover-transport-thumb);border:none;border-radius:var(--clover-radius-pill, 2rem);background-color:var(--clover-player-text, #fff)}.clover-canvas-transport input[type=range]:focus-visible{outline:none}.clover-canvas-transport input[type=range]:focus-visible::-webkit-slider-thumb{box-shadow:0 0 0 2px var(--clover-color-accent, #0065c3),0 0 0 4px var(--clover-player-text, #fff),0 0 0 6px #0009}.clover-canvas-transport input[type=range]:focus-visible::-moz-range-thumb{box-shadow:0 0 0 2px var(--clover-color-accent, #0065c3),0 0 0 4px var(--clover-player-text, #fff),0 0 0 6px #0009}.clover-canvas-transport-time{display:flex;align-items:center;gap:var(--clover-space-xs);color:var(--clover-player-text, #fff);font-size:var(--clover-text-s);font-variant-numeric:tabular-nums;white-space:nowrap;text-shadow:0 1px 2px rgb(0 0 0 / 90%)}.clover-canvas-transport-frames{position:relative;display:flex}button.clover-canvas-transport-time{margin:0;padding:var(--clover-space-2xs) var(--clover-space-xs);border:0;border-radius:var(--clover-radius, 3px);background:none;font:inherit;font-size:var(--clover-text-s);cursor:pointer}button.clover-canvas-transport-time:is(:hover,[aria-expanded=true]){background-color:#0006}button.clover-canvas-transport-time:focus-visible{outline:2px solid var(--clover-player-text, #fff)}.clover-canvas-transport-place{display:inline-grid;justify-items:end;font-variant-numeric:tabular-nums}.clover-canvas-transport-place>*{grid-area:1 / 1}.clover-canvas-transport-place>.clover-canvas-transport-place-room[hidden]{display:block;visibility:hidden}.clover-canvas-transport-frames>.clover-canvas-menu{right:0;bottom:calc(100% + var(--clover-space-s));left:auto;max-width:min(20rem,100cqi - 2 * var(--clover-canvas-controls-inset));max-height:min(24rem,var(--clover-transport-menu-room),var(--clover-transport-menu-above, 100cqb) - var(--clover-space-s) - var(--clover-space-xs));translate:var(--clover-transport-menu-shift, 0px) 0}.clover-canvas-transport-menu{position:relative;display:flex}.clover-canvas-transport-options{position:absolute;right:0;bottom:calc(100% + var(--clover-space-s));display:flex;flex-direction:column;box-sizing:border-box;min-width:min(11rem,100cqi - 2 * var(--clover-canvas-controls-inset));max-width:calc(100cqi - 2 * var(--clover-canvas-controls-inset));max-height:min(16rem,var(--clover-transport-menu-room),var(--clover-transport-menu-above, 100cqb) - var(--clover-space-s) - var(--clover-space-xs));translate:var(--clover-transport-menu-shift, 0px) 0;margin:0;padding:var(--clover-space-xs);border:none;border-radius:var(--clover-radius, 3px);background-color:var(--clover-player-menu-surface, #151718);color:var(--clover-player-text, #fff);overflow-y:auto}.clover-canvas-transport-option{display:flex;flex:none;align-items:center;gap:var(--clover-space-xs);min-height:var(--clover-space-l);padding:var(--clover-space-xs) var(--clover-space-s);border-radius:var(--clover-radius, 3px);font-size:var(--clover-text-s);cursor:pointer}.clover-canvas-transport-option:hover{background-color:var(--clover-player-menu-hover, #26292b)}.clover-canvas-transport-option:has(input:checked){background-color:color-mix(in srgb,var(--clover-color-accent, #0065c3) 24%,transparent);font-weight:600}.clover-canvas-transport-option:has(input:focus-visible){box-shadow:inset 0 0 0 2px var(--clover-player-text, #fff)}.clover-canvas-transport-code{flex:none;min-width:var(--clover-space-l);color:color-mix(in srgb,currentColor 72%,transparent);font-size:var(--clover-text-xs);font-weight:600;line-height:1}.clover-canvas-transport-options:has(.clover-canvas-transport-code),.clover-canvas-transport-menu:has([data-button=chapters]) .clover-canvas-transport-options{min-width:min(16rem,100cqi - 2 * var(--clover-canvas-controls-inset))}.clover-canvas-transport-option:has(>.clover-entry-thumbnail){display:grid;grid-template-columns:auto minmax(0,1fr);justify-items:start;gap:var(--clover-space-2xs) var(--clover-space-s);padding-block-end:var(--clover-space-s)}.clover-canvas-transport-options.clover-canvas-menu{border-radius:var(--clover-radius, 6px);background-color:var(--clover-color-secondary, #fff);color:var(--clover-color-primary, #1a1d1e)}.clover-canvas-menu>.clover-canvas-transport-option{align-items:baseline;gap:var(--clover-space-s);font-size:inherit}.clover-canvas-menu>.clover-canvas-transport-option:hover{background-color:var(--clover-color-secondary-muted, #e6e8eb)}@media (forced-colors: none){.clover-canvas-menu>.clover-canvas-transport-option:has(input:checked){background-color:color-mix(in srgb,var(--clover-color-accent, #0065c3) 8%,transparent)}}.clover-canvas-menu>.clover-canvas-transport-option:has(input:focus-visible){box-shadow:none;outline:2px solid var(--clover-color-accent, #0065c3);outline-offset:-2px}.clover-canvas-transport-option input{position:absolute;opacity:0;pointer-events:none}@media (forced-colors: active){.clover-canvas-transport button.clover-canvas-transport-button{border:1px solid ButtonText}.clover-canvas-transport input[type=range]{forced-color-adjust:none}.clover-canvas-transport input[type=range]::-webkit-slider-runnable-track{border:1px solid CanvasText;background:linear-gradient(to right,Highlight var(--clover-transport-progress, 0%),Canvas var(--clover-transport-progress, 0%));box-shadow:none}.clover-canvas-transport input[type=range]::-moz-range-track{border:1px solid CanvasText;background:linear-gradient(to right,Highlight var(--clover-transport-progress, 0%),Canvas var(--clover-transport-progress, 0%));box-shadow:none}.clover-canvas-transport input[type=range]::-webkit-slider-thumb,.clover-canvas-transport input[type=range]:focus-visible::-webkit-slider-thumb{background-color:CanvasText;box-shadow:0 0 0 2px Canvas}.clover-canvas-transport input[type=range]::-moz-range-thumb,.clover-canvas-transport input[type=range]:focus-visible::-moz-range-thumb{background-color:CanvasText;box-shadow:0 0 0 2px Canvas}.clover-canvas-transport input[type=range]:focus-visible{outline:2px solid CanvasText;outline-offset:2px}.clover-canvas-transport-button:focus-visible{outline:3px solid CanvasText;outline-offset:2px;box-shadow:none}.clover-canvas-transport-button:is([data-active],[aria-pressed=true]),.clover-canvas-transport-option:has(input:checked){background-color:Highlight;color:HighlightText}.clover-captions-icon[data-on] .clover-captions-icon-letters{stroke:ButtonFace}.clover-canvas-transport-button[data-active] .clover-captions-icon[data-on] .clover-captions-icon-letters{stroke:Highlight}}@media (prefers-reduced-motion: reduce){.clover-canvas-transport,.clover-canvas-transport-button,.clover-canvas-transport-button svg{transition:none}}.clover-canvas-transport-seek[data-gaps]{--clover-transport-disk: calc(var(--clover-transport-thumb) / 2 + 1px);-webkit-mask-image:radial-gradient(circle at calc(var(--clover-transport-thumb) / 2 + (100% - var(--clover-transport-thumb)) * var(--clover-transport-at, 0)) 50%,#000 var(--clover-transport-disk),transparent var(--clover-transport-disk)),var(--clover-transport-gaps);mask-image:radial-gradient(circle at calc(var(--clover-transport-thumb) / 2 + (100% - var(--clover-transport-thumb)) * var(--clover-transport-at, 0)) 50%,#000 var(--clover-transport-disk),transparent var(--clover-transport-disk)),var(--clover-transport-gaps)}.clover-canvas-transport-seek[data-gaps]:focus-visible{--clover-transport-disk: calc(var(--clover-transport-thumb) / 2 + 6px)}.clover-canvas-transport-chapter-span{position:absolute;top:50%;box-sizing:border-box;border-inline:calc(var(--clover-transport-gap) / 2) solid transparent;background-clip:padding-box;height:var(--clover-space-s);translate:0 -50%;border-radius:var(--clover-radius, 3px);background-color:var(--clover-player-text, #fff);opacity:.5;pointer-events:none}.clover-canvas-transport-seek-area>.clover-tip{left:var(--clover-transport-preview, 50%)}.clover-canvas-transport-seek-area>.clover-tip:has(>.clover-tip-image){padding:var(--clover-space-s)}.clover-canvas-transport-seek-area>.clover-tip .clover-tip-image{width:var(--clover-picture);max-height:none;margin-block-end:var(--clover-space-xs)}.clover-canvas-transport-seek-area:is(:hover,:has(>input:focus-visible)):not([data-tip-hidden])>.clover-tip{opacity:1;visibility:visible;pointer-events:auto;transition-delay:0s}@media (forced-colors: active){.clover-canvas-transport-chapter-span{background-color:Highlight;opacity:1}}.clover-canvas-transport-status>.clover-canvas-transport-chapter{flex:1 1 auto;overflow:hidden;width:0;min-width:0;max-width:16rem;color:color-mix(in srgb,var(--clover-player-text, #fff) 85%,transparent);font-size:var(--clover-text-s);text-overflow:ellipsis;white-space:nowrap;text-shadow:0 1px 2px rgb(0 0 0 / 90%)}}');export{j as C,N as E,O as F,S as P,T,R as V,P as a,F as b,V as c,q as d,W as e,A as f,$ as g,H as l,I as p,L as s,B as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{S as l,az as g,ax as y,aA as u,ay as f}from"./shared-
|
|
1
|
+
import{S as l,az as g,ax as y,aA as u,ay as f}from"./shared-DFAX0n3B.mjs";const w=100;async function p(t,n,i){if(typeof t=="string")return await f(n,t,i);const a=t;return a!=null&&a.id&&a.type==="AnnotationPage"&&!a.items?await f(n,a.id,i):a}async function h(t,n,i){const a=String((t==null?void 0:t.type)??(t==null?void 0:t["@type"])??""),c=/AnnotationCollection/.test(a),o=c?[]:[t],r=new Set(c?[]:[t.id]);let e=c?t.first:t.next;for(;e&&o.length<w;){const s=typeof e=="string"?e:e.id;if(r.has(s??e))break;r.add(s??e);const d=await p(e,n,i);o.push(d),e=d.next}return o}async function x(t,{request:n,signal:i}={}){const a=[];for(const c of l(t)){const o=await p(c,n,i);for(const r of await h(o,n,i)){const e=await g(r),s=e.id??`added-${a.length}`,d=y(e,s);d.length&&a.push({id:s,label:u(e,r===o?c:void 0)??o.label,source:"added",entries:d})}}return a}export{x as loadAnnotationSets};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as d,
|
|
1
|
+
import{t as d,V as p}from"./shared-DFAX0n3B.mjs";import{t as u,r as v,m as T}from"./text-BTAkxEfQ.mjs";const m=t=>t.language&&t.language!=="none"?t.language:"none";function k(t,e){const o=p([...new Set(t.map(m))],e);return t.find(r=>m(r)===o)}function P(t,e){const o=(n,a)=>n?{text:n,...a?{lang:a}:{}}:{},r=t.filter(n=>{var a;return(a=n.value)==null?void 0:a.trim()});if(!r.length){const n=t.find(s=>(s.image||s.place)&&s.label);if(!n)return{};const{text:a,lang:x}=d(n.label,e);return o(u(a).trim(),x)}const l=k(r,e),i=l.value,c=v(l.format,i),f=c==="markdown"?T(i):c==="html"?u(i):i,g=m(l);return o(f.trim(),g==="none"?void 0:g)}export{P as a,k as b};
|
package/dist/web-components/{annotations-content-Bg6aVAGC.mjs → annotations-content-CEzAS-P2.mjs}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{loadAnnotationSets as f}from"./annotation-collection-
|
|
1
|
+
import{loadAnnotationSets as f}from"./annotation-collection-BkC3nBPA.mjs";import{G as i,aB as l,ar as c}from"./shared-DFAX0n3B.mjs";async function y(n,a){const s={id:String(n.id??""),type:/Collection/.test(String(n.type??n["@type"]))?"AnnotationCollection":"AnnotationPage",...n.label?{label:n.label}:{}},o=(await f(n,a)).map(t=>({...t,content:s})),r=o.flatMap(t=>t.entries),e=r.find(t=>a.manifestId&&i(t.annotation)===a.manifestId)??r.find(t=>i(t.annotation));if(!e)throw new l("The annotations name no Manifest");return{manifest:await c({id:i(e.annotation),type:"Manifest"},a),target:{canvasId:e.canvasId},annotationSets:o,pick:e.id}}export{y as annotationsContent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{f as m,T as u,h as g,u as r,i as B,g as p}from"./shared-
|
|
1
|
+
import{f as m,T as u,h as g,u as r,i as B,g as p}from"./shared-DFAX0n3B.mjs";import{B as h}from"./Body-QQ1DmnbP.mjs";import{u as y,P as L}from"./nodes-BleXuYE6.mjs";import{Toggle as b}from"./toggle-CJKdi5KH.mjs";const R={height:"100%"},T=e=>[...e.children].find(s=>s.localName==="clover-panel-toggle")??null,C=e=>e instanceof HTMLElement&&e.localName==="button";function P({hosted:e,props:s}){const a=y(e.element,()=>T(e.element),Object.is),{controlButtons:n,renderers:l,onReady:c,...d}=s,o=m(B,!!n),t=m(p,!!l),i=u(()=>o==null?void 0:o.toControlButtons(n),[o,n]),f=u(()=>t==null?void 0:t.toRenderers(l),[t,l]);return g(c),n&&!o||l&&!t?null:r(h,{...d,onReady:c,controlButtons:i,renderers:f,style:R,children:[a&&r(b,{element:a}),r(L,{from:e.element,picks:C})]})}export{P as BodyElement};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{O as l,u as o,z as c,P as r,f,T as v,h as C,i as m}from"./shared-
|
|
1
|
+
import{O as l,u as o,z as c,P as r,f,T as v,h as C,i as m}from"./shared-DFAX0n3B.mjs";import{C as b}from"./CanvasView-DxZASM9E.mjs";import{r as s}from"./rendererSurface-nh6-EfuZ.mjs";import{C as i}from"./Pending-mcmdyZPA.mjs";const h=c(()=>import("./Connected-sYBn_9MK.mjs")),B=c(()=>import("./LoadedCanvas-DK6xMmM1.mjs")),k=n=>{const a=l();if(n.iiifContent!==void 0&&n.canvases===void 0)return o(r,{fallback:o(i,{}),children:o(B,{...n,surface:s})});const e=n.canvases!==void 0||n.body!==void 0||n.src!==void 0;return a&&!e?o(r,{fallback:o(i,{}),children:o(h,{...n,surface:s})}):o(b,{...n,surface:s})};function g({props:n}){const{controlButtons:a,onReady:e,...d}=n,t=f(m,!!a),u=v(()=>t==null?void 0:t.toControlButtons(a),[t,a]);return C(e),a&&!t?null:o(k,{...d,onReady:e,controlButtons:u})}export{g as CanvasElement};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{c as ne,F as ae,i as se,M as ie}from"./models-
|
|
1
|
+
import{c as ne,F as ae,i as se,M as ie}from"./models-BXcT4ijX.mjs";import{au as ce,a1 as ue}from"./shared-DFAX0n3B.mjs";const le=["KHR_materials_unlit","KHR_materials_ior","KHR_materials_specular","KHR_mesh_quantization"],Z=1179937895,fe=1313821514,de=5130562;function me(e){const s=new DataView(e);if(s.getUint32(0,true)!==Z)throw new Error("This is not a GLB.");if(s.getUint32(4,true)!==2)throw new Error("Only glTF 2.0 is drawn.");let o,t;const n=Math.min(s.getUint32(8,true),e.byteLength);for(let a=12;a+8<=n;){const i=s.getUint32(a,true),l=s.getUint32(a+4,true),c=a+8;l===fe?o=JSON.parse(new TextDecoder().decode(new Uint8Array(e,c,i))):l===de&&(t=e.slice(c,c+i)),a=c+i}if(!o)throw new Error("The GLB has no JSON chunk.");return{json:o,bin:t}}async function z(e,s,o){const t=new URL(e,s).href,n=t.startsWith("data:")?await fetch(t):await ue(o,t);if(!n.ok)throw new Error(`${t} answered ${n.status}`);return n.arrayBuffer()}const $=new WeakMap;function ve(e,s,o){const t=(s==null?void 0:s.fetch)??globalThis.fetch,n=$.get(t)??new Map;$.set(t,n);const a=`${ce(s)} ${o??""} ${e}`;let i=n.get(a);return i||(i=he(e,s,o).finally(()=>n.delete(a)),n.set(a,i)),i}async function he(e,s,o){const t=await z(e,location.href,s),n=new DataView(t).getUint32(0,true)===Z,{json:a,bin:i}=n?me(t):{json:JSON.parse(new TextDecoder().decode(t))},l=(a.extensionsRequired??[]).filter(f=>!le.includes(f));if(l.length)throw new Error(`Clover's renderer cannot draw this model: it requires ${l.join(", ")}.`);const c=await Promise.all((a.buffers??[]).map((f,r)=>{if(f.uri!==void 0)return z(f.uri,e,s);if(r===0&&i)return i;throw new Error("A buffer of the model has no data.")})),u=await Promise.all((a.images??[]).map(async f=>{try{let r;if(f.bufferView!==void 0){const d=a.bufferViews[f.bufferView];r=new Blob([new Uint8Array(c[d.buffer],d.byteOffset??0,d.byteLength)],{type:f.mimeType})}else if(f.uri!==void 0)r=new Blob([await z(f.uri,e,s)],{type:f.mimeType});else return null;const m={premultiplyAlpha:"none",colorSpaceConversion:"none"};return await pe(await createImageBitmap(r,m),o,m)}catch{return null}}));return{json:a,buffers:c,images:u}}async function pe(e,s,o){const t=Math.max(e.width,e.height);if(!s||t<=s)return e;const n=s/t,a=await createImageBitmap(e,{...o,resizeWidth:Math.max(1,Math.floor(e.width*n)),resizeHeight:Math.max(1,Math.floor(e.height*n)),resizeQuality:"high"});return e.close(),a}const we={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},Ee={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},q=e=>we[e];function Te(e,s){const o=e.json.accessors[s],t=q(o.type),n=new Float32Array(o.count*t);if(o.bufferView===void 0)return n;const a=e.json.bufferViews[o.bufferView],i=Ee[o.componentType],l=a.byteStride||i*t,c=new DataView(e.buffers[a.buffer],(a.byteOffset??0)+(o.byteOffset??0)),u={5120:r=>c.getInt8(r),5121:r=>c.getUint8(r),5122:r=>c.getInt16(r,true),5123:r=>c.getUint16(r,true),5125:r=>c.getUint32(r,true),5126:r=>c.getFloat32(r,true)}[o.componentType]??(()=>0),f=o.normalized?{5120:127,5121:255,5122:32767,5123:65535}[o.componentType]:void 0;for(let r=0;r<o.count;r++)for(let m=0;m<t;m++){const d=u(r*l+m*i);n[r*t+m]=f?Math.max(d/f,-1):d}return n}const ee=()=>new Float32Array([1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]);function I(e,s){const o=new Float32Array(16);for(let t=0;t<4;t++)for(let n=0;n<4;n++){let a=0;for(let i=0;i<4;i++)a+=e[i*4+n]*s[t*4+i];o[t*4+n]=a}return o}function X([e,s,o],[t,n,a,i],[l,c,u]){const f=t+t,r=n+n,m=a+a,d=t*f,M=t*r,p=t*m,w=n*r,S=n*m,y=a*m,k=i*f,L=i*r,O=i*m;return new Float32Array([(1-(w+y))*l,(M+O)*l,(p-L)*l,0,(M-O)*c,(1-(d+y))*c,(S+k)*c,0,(p+L)*u,(S-k)*u,(1-(d+w))*u,0,e,s,o,1])}const K=e=>X(e,[0,0,0,1],[1,1,1]),xe=e=>X([0,0,0],[0,0,0,1],e);function be([e,s,o]){const t=(n,a)=>{const i=a*Math.PI/180,l=Math.cos(i),c=Math.sin(i),u=ee(),[f,r]=n===0?[1,2]:n===1?[2,0]:[0,1];return u[f*4+f]=l,u[f*4+r]=c,u[r*4+f]=-c,u[r*4+r]=l,u};return I(t(2,o),I(t(1,s),t(0,e)))}function ye(e,s,o,t){const n=1/Math.tan(e/2),a=1/(o-t);return new Float32Array([n/s,0,0,0,0,n,0,0,0,0,(t+o)*a,-1,0,0,2*t*o*a,0])}function Ae(e,s){const o=c=>{const u=Math.hypot(...c)||1;return[c[0]/u,c[1]/u,c[2]/u]},t=(c,u)=>[c[1]*u[2]-c[2]*u[1],c[2]*u[0]-c[0]*u[2],c[0]*u[1]-c[1]*u[0]],n=(c,u)=>c[0]*u[0]+c[1]*u[1]+c[2]*u[2],a=o([e[0]-s[0],e[1]-s[1],e[2]-s[2]]),i=o(t([0,1,0],a)),l=t(a,i);return new Float32Array([i[0],l[0],a[0],0,i[1],l[1],a[1],0,i[2],l[2],a[2],0,-n(i,e),-n(l,e),-n(a,e),1])}function Re(e){const[s,o,t,,n,a,i,,l,c,u]=e,f=a*u-i*c,r=i*l-n*u,m=n*c-a*l,d=s*f+o*r+t*m||1;return new Float32Array([f/d,r/d,m/d,(t*c-o*u)/d,(s*u-t*l)/d,(o*l-s*c)/d,(o*i-t*a)/d,(t*n-s*i)/d,(s*a-o*n)/d])}const Me=()=>({min:[1/0,1/0,1/0],max:[-1/0,-1/0,-1/0]});function _e(e){for(let s=0;s<3;s++){let o=0;for(let t=0;t<3;t++)Math.abs(e[s*4+t])>1e-6&&o++;if(o>1)return false}return true}function Ne(e,s,o,t){const n=s.json.accessors[o];let a;if(_e(t)&&n.min&&n.max&&!n.normalized){const[l,c]=[n.min,n.max];a=Array.from({length:8},(u,f)=>[f&1?c[0]:l[0],f&2?c[1]:l[1],f&4?c[2]:l[2]]).flat()}else a=Te(s,o);const i=t;for(let l=0;l+2<a.length;l+=3){const c=a[l],u=a[l+1],f=a[l+2];for(let r=0;r<3;r++){const m=i[r]*c+i[4+r]*u+i[8+r]*f+i[12+r];m<e.min[r]&&(e.min[r]=m),m>e.max[r]&&(e.max[r]=m)}}return e}const C={normals:1,normalMap:2,unlit:4,mask:8},Y={POSITION:0,NORMAL:1,TEXCOORD_0:2,COLOR_0:3},J=["uBaseTexture","uMetalRoughTexture","uNormalTexture","uOcclusionTexture","uEmissiveTexture"],Se=`#version 300 es
|
|
2
2
|
layout(location = 0) in vec3 aPosition;
|
|
3
3
|
layout(location = 1) in vec3 aNormal;
|
|
4
4
|
layout(location = 2) in vec2 aUv;
|
package/dist/web-components/{content-state-reader-CNmBpG1L.mjs → content-state-reader-GgQF2MvJ.mjs}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{S as l,a9 as g}from"./shared-
|
|
1
|
+
import{S as l,a9 as g}from"./shared-DFAX0n3B.mjs";function b(t){const e=t.replace(/-/g,"+").replace(/_/g,"/"),n=e+"=".repeat((4-e.length%4)%4),o=atob(n);try{return decodeURIComponent(o)}catch{const a=Uint8Array.from(o,s=>s.charCodeAt(0));return new TextDecoder().decode(a)}}function I(t){const e=t.trim();for(const n of[()=>JSON.parse(e),()=>JSON.parse(b(e))])try{const o=n();if(o&&typeof o=="object")return o}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 h(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 o=typeof t.id=="string"?t.id:"content-state",a=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:`${o}#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 a.length>1?{...n,targets:{id:o,...t.label&&typeof t.label=="object"?{label:t.label}:{},items:a}}:n}function m(t,e){const n=g(t),o=typeof t=="string"?{id:n.id}:t.type==="SpecificResource"?typeof t.source=="string"?{id:t.source}:t.source??{}:t,a=o.type;if(a==="Manifest"||a==="Collection"){const c=a==="Manifest"?u(o):void 0;return c?{id:c.id,type:"Collection",manifestId:n.id}:{id:n.id,type:a}}const s=l(t.selector).find(c=>(c==null?void 0:c.type)==="PointSelector"&&c.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=l(o.partOf).find(c=>(c==null?void 0:c.id)&&(!c.type||c.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:a??"Canvas",target:d,...f}}export{I as decodeContentState,h as resolveContentState};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{u as d,A as v,d as y,_ as g,$ as w,k as A}from"./shared-
|
|
1
|
+
import{u as d,A as v,d as y,_ as g,$ as w,k as A}from"./shared-DFAX0n3B.mjs";const E=new Map;function D(o){if(!o||typeof o!="object")return;const s={};for(const[n,r]of Object.entries(o)){if(typeof r!="function")continue;const u=E.get(n)??new WeakMap;E.set(n,u);let c=u.get(r);c||(c=l=>d(x,{...l,name:n,make:r}),u.set(r,c)),s[n]=c}return s}const B=["id","type","aria-label","lang","aria-keyshortcuts","aria-expanded","aria-controls"];function x({name:o,make:s,buttonProps:n,icon:r,label:u,tip:c}){const l=v(null),[m]=y(()=>{const e=document.createElement("span");return e.style.display="contents",e}),[a,k]=y(null),f=v(n.onClick);return f.current=n.onClick,g(()=>{const e=l.current;if(!e)return;const t=s({name:o,label:u,icon:m});if(!(t instanceof HTMLElement)){console.warn(`controlButtons.${o} returned no element; Clover's own is not drawn either.`);return}const i=t.matches("button")?t:t.querySelector("button")??t,b=h=>{var p;return(p=f.current)==null?void 0:p.call(f,h)};return i.addEventListener("click",b),e.after(t),k(i),()=>{i.removeEventListener("click",b),t.remove(),k(null)}},[s]),g(()=>{if(!a)return;const e=n;for(const t of B){const i=e[t];i===void 0?a.removeAttribute(t):a.setAttribute(t,String(i))}}),d(A,{children:[d("span",{ref:l,hidden:true}),w(r,m),a&&w(c,a)]})}export{D as toControlButtons};
|
|
@@ -147,6 +147,21 @@
|
|
|
147
147
|
"description": "Default, Document and Gallery: the panel's sections as stacked boxes, each opened by its heading, or as tabs.",
|
|
148
148
|
"default": "accordion"
|
|
149
149
|
},
|
|
150
|
+
{
|
|
151
|
+
"name": "panel-sections",
|
|
152
|
+
"type": {
|
|
153
|
+
"text": "string"
|
|
154
|
+
},
|
|
155
|
+
"description": "Default, Document and Gallery: which of the panel's sections it may have, as a JSON array: [\"contents\",\"search\",\"transcript\",\"annotations\"] leaves out About and the rest. Each still shows only where the resource has data for it, and there is no panel where none of them does.",
|
|
156
|
+
"default": "every section"
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
"name": "panel-labels",
|
|
160
|
+
"type": {
|
|
161
|
+
"text": "string"
|
|
162
|
+
},
|
|
163
|
+
"description": "Default, Document and Gallery: what a panel section's tab or heading says, in place of Clover's own word for it, as JSON by the section's value: {\"annotations\": \"Chapters\"}, or a word by language tag to say it in several (clover-panel's labels)."
|
|
164
|
+
},
|
|
150
165
|
{
|
|
151
166
|
"name": "sidebar-open",
|
|
152
167
|
"type": {
|
|
@@ -1907,6 +1922,21 @@
|
|
|
1907
1922
|
"description": "Where what the resource says of itself comes in several languages, About's heading offers them, and the whole clover-root reads in the one chosen. \"false\" leaves the choice out.",
|
|
1908
1923
|
"default": "true"
|
|
1909
1924
|
},
|
|
1925
|
+
{
|
|
1926
|
+
"name": "sections",
|
|
1927
|
+
"type": {
|
|
1928
|
+
"text": "string"
|
|
1929
|
+
},
|
|
1930
|
+
"description": "Which of the default sections it may have, as a JSON array: [\"contents\",\"search\",\"transcript\",\"annotations\"] leaves out About and the rest. Each still shows only where the resource has data for it, and the panel draws nothing where none of them does. Its clover-tab children win over it.",
|
|
1931
|
+
"default": "every section"
|
|
1932
|
+
},
|
|
1933
|
+
{
|
|
1934
|
+
"name": "labels",
|
|
1935
|
+
"type": {
|
|
1936
|
+
"text": "string"
|
|
1937
|
+
},
|
|
1938
|
+
"description": "What a default section's tab or heading says, in place of Clover's own word for it, as JSON by the section's value: {\"annotations\": \"Chapters\"}, or {\"annotations\": {\"en\": \"Chapters\", \"de\": \"Kapitel\"}} to say it in several, read in the language Clover speaks and marked with it where that is not the page's."
|
|
1939
|
+
},
|
|
1910
1940
|
{
|
|
1911
1941
|
"name": "closable",
|
|
1912
1942
|
"type": {
|
|
@@ -2519,7 +2549,7 @@
|
|
|
2519
2549
|
"type": {
|
|
2520
2550
|
"text": "{ request?: Record<string, unknown>; hideDelay?: number } | null"
|
|
2521
2551
|
},
|
|
2522
|
-
"description": "request: credentials and headers for the Scene and its models; hideDelay: how long the controls stay after a mouse stops, in milliseconds."
|
|
2552
|
+
"description": "request: credentials and headers for the Scene and its models; hideDelay: how long the controls stay after a mouse stops or a finger lifts, in milliseconds (3000)."
|
|
2523
2553
|
},
|
|
2524
2554
|
{
|
|
2525
2555
|
"kind": "field",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{e as i,c as f,n as d,S as u,t as g,
|
|
1
|
+
import{e as i,c as f,n as d,S as u,t as g,Y as h}from"./shared-DFAX0n3B.mjs";function c(s,t){const e=new Set,a=[];for(const r of s)for(const n of u(r==null?void 0:r.rendering)){const o=(n==null?void 0:n.id)??(n==null?void 0:n["@id"]);if(typeof o!="string"||e.has(o))continue;e.add(o);const l=g(n.label,t);a.push({id:o,label:l.text||n.format||o,lang:l.text?l.lang:void 0,format:n.format,hrefLang:h(n)})}return a}function p(){const{language:s}=i("Download"),t=f(a=>a.manifest),e=f(a=>d(a.manifest,a.canvasId));return{page:c(e,s),all:c([t],s)}}export{p as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as _}from"./viewer-
|
|
1
|
+
import{g as _}from"./viewer-DN2Mo3vc.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 h,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{(h=t.setPointerCapture)==null||h.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 g=(v=n.current.scrim)==null?void 0:v.current;g&&(g.style.transition="none",g.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,g]=c[0],[h,v]=c[c.length-1],I=h>y?(v-g)/(h-y):0,l=(X=n.current.scrim)==null?void 0:X.current,L=(C=window.matchMedia)==null?void 0:C.call(window,"(prefers-reduced-motion: reduce)").matches;if(s>d*k||I>Y){const x=L?0:Math.min(D[1],Math.max(D[0],2*(d-s)/Math.max(I,.001))),w=`${x}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(),x);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),x)),n.current.onClose();return}u(f(),"",L?"none":z),l&&(l.style.transition=L?"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,4 +1,4 @@
|
|
|
1
|
-
import{a0 as jc}from"./shared-
|
|
1
|
+
import{a0 as jc}from"./shared-DFAX0n3B.mjs";import{F as eu,c as tu,i as nu,M as iu}from"./models-BXcT4ijX.mjs";/**
|
|
2
2
|
* @license
|
|
3
3
|
* Copyright 2010-2026 Three.js Authors
|
|
4
4
|
* SPDX-License-Identifier: MIT
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const r=Symbol.for("@nulib/clover/scene-engines"),o=globalThis,c=o[r]??(o[r]=new Map);function s(e,n){c.set(e,n)}const t=()=>import("./cloverEngine-
|
|
1
|
+
const r=Symbol.for("@nulib/clover/scene-engines"),o=globalThis,c=o[r]??(o[r]=new Map);function s(e,n){c.set(e,n)}const t=()=>import("./cloverEngine-UNw5K4Xg.mjs");let i=false;function l(e="clover"){if(e==="clover")return t;const n=c.get(e);return n||(i||(i=true,console.warn(`Clover: no Scene engine "${e}"; drawing with Clover's.`)),t)}export{l as e,s as r};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{S as h,a8 as m,a9 as x,ar as I}from"./shared-
|
|
1
|
+
import{S as h,a8 as m,a9 as x,ar as I}from"./shared-DFAX0n3B.mjs";import{b as S}from"./imageService-4sFnmAFX.mjs";function k(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(!m(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=S(t.service);if(!r)continue;const f=x(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),p=Math.max(0,c),M=Math.min(1,a+i.w/f.w)-u,g=Math.min(1,c+i.h/f.h)-p;if(M>0&&g>0)return{service:r,region:{x:u,y:p,width:M,height:g}}}}return null}const w=new WeakMap;function C(e,i){let n=w.get(e);n||w.set(e,n=new Map);let s=n.get(i);return s||(s=I({id:i,type:"Manifest"},{request:e.request}).catch(()=>null),n.set(i,s)),s}export{C as f,k as r};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{T as f,t as d}from"./shared-
|
|
1
|
+
import{T as f,t as d}from"./shared-DFAX0n3B.mjs";function c(e,u,n,o){return f(()=>((o==null?void 0:o(e??null,(u==null?void 0:u.id)??null,u==null?void 0:u.duration))??[]).map(t=>{const i=d(t.label,n);return{...t.id?{id:t.id}:{},label:i.text,lang:i.lang,start:t.start,end:t.end,...t.thumbnail?{thumbnail:t.thumbnail}:{}}}),[e,u,n,o])}function m(e,u,n,o){if(e.region){if(!u)return false;const{x:t,y:i,w:l,h:s}=e.region;if(!u.fitCanvasRect(e.canvasId,{x:t,y:i,width:l,height:s},true))return false}if(o&&(e.time!==void 0||e.autoplay)){if(!n)return false;const t=()=>{e.time!==void 0&&(n.currentTime=e.time),e.autoplay&&n.play().catch(()=>{})};n.readyState>=HTMLMediaElement.HAVE_METADATA?t():n.addEventListener("loadedmetadata",t,{once:true})}return true}export{m as a,c as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{u as e,k as o}from"./shared-
|
|
1
|
+
import{u as e,k as o}from"./shared-DFAX0n3B.mjs";const t=()=>e("path",{fillRule:"evenodd",stroke:"none",d:"M144 72H368A96 96 0 0 1 464 168V296A96 96 0 0 1 368 392H200L104 460L144 392A96 96 0 0 1 48 296V168A96 96 0 0 1 144 72Z M168 184H344A16 16 0 0 1 344 216H168A16 16 0 0 1 168 184Z M168 264H280A16 16 0 0 1 280 296H168A16 16 0 0 1 168 264Z"}),c=()=>e(o,{children:[e("path",{d:"M160 144h288M160 256h288M160 368h288",fill:"none",strokeLinecap:"round",strokeWidth:"32"}),e("circle",{cx:"80",cy:"144",r:"20",stroke:"none"}),e("circle",{cx:"80",cy:"256",r:"20",stroke:"none"}),e("circle",{cx:"80",cy:"368",r:"20",stroke:"none"})]}),s=()=>e("path",{stroke:"none",d:"M256 72A48 48 0 1 1 256 168A48 48 0 1 1 256 72Z M192 216H296V384H328V432H184V384H216V264H192Z"}),r=()=>e("path",{fillRule:"evenodd",stroke:"none",d:"M256 40C166 40 100 108 100 196C100 300 216 420 246 452A14 14 0 0 0 266 452C296 420 412 300 412 196C412 108 346 40 256 40Z M256 136A60 60 0 1 1 256 256A60 60 0 1 1 256 136Z"}),h=()=>e("path",{strokeLinejoin:"round",strokeWidth:"40",d:"M184 128V384L392 256Z"}),a=()=>e("path",{strokeLinecap:"round",strokeWidth:"45",d:"M154 154L358 358M358 154L154 358"}),d=()=>e(o,{children:[e("path",{stroke:"none",d:"m456.69,421.39l-94.09-94.09c22.65-30.16,34.88-66.86,34.84-104.58,0-96.34-78.38-174.72-174.72-174.72S48,126.38,48,222.72s78.38,174.72,174.72,174.72c37.72.04,74.42-12.19,104.58-34.84l94.09,94.09c10.29,9.2,26.1,8.32,35.3-1.98,8.48-9.49,8.48-23.83,0-33.32Zm-233.97-73.87c-68.89-.08-124.72-55.91-124.8-124.8h0c0-68.93,55.87-124.8,124.8-124.8s124.8,55.87,124.8,124.8-55.87,124.8-124.8,124.8Z"}),e("path",{stroke:"none",d:"m279.5,197.76h-3.35s-28.47,0-28.47,0v-31.82c-.77-13.79-12.57-24.33-26.36-23.56-12.71.71-22.85,10.86-23.56,23.56v3.35h0v28.47h-31.82c-13.79.77-24.33,12.57-23.56,26.36.71,12.71,10.86,22.85,23.56,23.56h3.35s28.47,0,28.47,0v31.82c.77,13.79,12.57,24.33,26.36,23.56,12.71-.71,22.85-10.86,23.56-23.56v-3.35h0v-28.47h31.82c13.79-.77,24.33-12.57,23.56-26.36-.71-12.71-10.86-22.85-23.56-23.56Z"})]}),l=()=>e(o,{children:[e("path",{stroke:"none",d:"m456.69,421.39l-94.09-94.09c22.65-30.16,34.88-66.86,34.84-104.58,0-96.34-78.38-174.72-174.72-174.72S48,126.38,48,222.72s78.38,174.72,174.72,174.72c37.72.04,74.42-12.19,104.58-34.84l94.09,94.09c10.29,9.2,26.1,8.32,35.3-1.98,8.48-9.49,8.48-23.83,0-33.32Zm-233.97-73.87c-68.89-.08-124.72-55.91-124.8-124.8h0c0-68.93,55.87-124.8,124.8-124.8s124.8,55.87,124.8,124.8-55.87,124.8-124.8,124.8Z"}),e("path",{stroke:"none",d:"M167.26 197.76H278.1a24.96 24.96 0 0 1 0 49.92H167.26a24.96 24.96 0 0 1 0-49.92Z"})]});export{a as C,s as I,d as O,r as P,c as a,t as b,h as c,l as d};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as s,T as o,e as i,af as r,
|
|
1
|
+
import{c as s,T as o,e as i,af as r,Z as f,ag as l,ah as v,F as u,n as g,a as c,t as d}from"./shared-DFAX0n3B.mjs";function C(){const n=s(a=>a.status),e=s(a=>a.error);return o(()=>({status:n,error:e}),[n,e])}function S(){return s(n=>n.manifest)}function b(){return s(n=>u(n.manifest))}function h(){return s(n=>g(n.manifest,n.canvasId))}function p(){return s(n=>f(n.manifest,n.canvasId))}function z(){const{clover:n}=i("useNavigation"),e=s(t=>v(t.manifest,t.canvasId)),a=s(t=>u(t.manifest).views.length);return o(()=>r(n,e,a),[n,e,a])}function A(){return s(n=>l(n.manifest,n.addedSets))}function I(n){const{language:e}=i("useLocalized");return o(()=>d(n,e),[n,e])}function L(){return c().t}function O(){return c().langOf}export{h as a,C as b,z as c,b as d,S as e,p as f,L as g,O as h,I as i,A as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{F as I,S as u,a8 as L,a9 as $,ax as P}from"./shared-
|
|
1
|
+
import{F as I,S as u,a8 as L,a9 as $,ax as P}from"./shared-DFAX0n3B.mjs";import{c as j}from"./choice-key-BUNebLKe.mjs";function F(t){const c=new Map;for(const e of I(t).canvases)k(e,c);return[...c.values()]}function k(t,c){u(t.items).forEach((e,s)=>u(e==null?void 0:e.items).forEach((d,f)=>{if(!L(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((r,y)=>{const w=(r==null?void 0:r.type)==="Choice";(w?u(r.items):[r]).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`,A=w?{key:j(t.id,d.id,s,f,y),item:x,image:o.id}:void 0,M=P(n,l,t.id).map(p=>{const h=q(p.annotation,o),b=Math.round(a.x+h.x*(a.w/h.width)),E=Math.round(a.y+h.y*(a.h/h.height)),S=Math.round(h.w*(a.w/h.width)),g=Math.round(h.h*(a.h/h.height)),N=`${t.id}#xywh=${b},${E},${S},${g}`;return{...p,canvasId:t.id,target:$(N),annotation:{...p.annotation,target:N},...A?{layer:A}:{}}});if(!M.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(...M)}})})}))}function q(t,c){const e=Number(c.width)||1,s=Number(c.height)||1,d={x:0,y:0,w:e,h:s,width:e,height:s},f=u(t==null?void 0:t.target)[0],r=(typeof f=="object"?u(f==null?void 0:f.selector):[]).find(i=>(i==null?void 0:i.type)==="ImageApiSelector"),y=typeof(r==null?void 0:r.region)=="string"?r.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*s,w:n/100*e,h:l/100*s,width:e,height:s}:{x:o,y:x,w:n,h:l,width:e,height:s}}const w=$(f).rect;return w?{...w,width:e,height:s}:d}export{F as imageLayers};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a1 as j}from"./shared-
|
|
1
|
+
import{a1 as j}from"./shared-DFAX0n3B.mjs";const S=["jpg","png","webp","gif"];class y extends Error{constructor(t,e,i){super(t),this.url=e,this.status=i,this.name="ImageServiceError"}}function g(r){return r.replace(/\/info\.json$/,"").replace(/\/+$/,"")}function O(r){const t=Array.isArray(r)?r:r?[r]:[];for(const e of t){if(!e||typeof e!="object")continue;const i=e,o=String(i.type??i["@type"]??""),s=JSON.stringify(i.profile??""),n=/ImageService/i.test(o)||/iiif\.io\/api\/image/.test(s)||/^"level[012]"$/.test(s)||!o&&!i.profile,c=i["@id"]??i.id;if(n&&typeof c=="string")return g(c)}}function F(r,t){if(!r||typeof r!="object")throw new y("info.json is not an object",t??"");const e=r,i=N(e),o=i===3?e.id??e["@id"]:e["@id"]??e.id,s=g(o??t??""),n=Number(e.width),c=Number(e.height);if(!s||!(n>0)||!(c>0))throw new y("info.json is missing id, width or height",t??s);const f=Array.isArray(e.profile)?e.profile:[e.profile],b=f.find(a=>typeof a=="string"),w=f.filter(a=>!!a&&typeof a=="object"),l=I(b),d=new Set([...Array.isArray(e.extraFeatures)?e.extraFeatures:[],...w.flatMap(a=>Array.isArray(a.supports)?a.supports:[])]),x=[...Array.isArray(e.preferredFormats)?e.preferredFormats:[]].map(a=>String(a).toLowerCase()).find(a=>S.includes(a))??"jpg",m=a=>{var A;const v=e[a]??((A=w.find($=>$[a]!==void 0))==null?void 0:A[a]);return Number(v)>0?Number(v):void 0};let u=m("maxWidth"),h=m("maxHeight");return u&&!h&&(h=u),h&&!u&&(u=void 0),{id:s,version:i,level:l,width:n,height:c,tiles:z(e.tiles),sizes:B(e.sizes),maxWidth:u,maxHeight:h,maxArea:m("maxArea"),regionByPx:l>=1||d.has("regionByPx"),sizeByW:l>=1||d.has("sizeByW")||d.has("sizeByWh"),format:x,quality:"default"}}function N(r){const t=[].concat(r["@context"]??[]).map(String);return t.some(e=>e.includes("/image/3"))?3:t.some(e=>e.includes("/image/2"))?2:r.type==="ImageService3"?3:r["@id"]?2:3}function I(r){const t=r==null?void 0:r.match(/level([012])/);return t?Number(t[1]):0}function z(r){return Array.isArray(r)?r.map(t=>{const e=Number(t==null?void 0:t.width),i=Number((t==null?void 0:t.height)??(t==null?void 0:t.width)),o=(Array.isArray(t==null?void 0:t.scaleFactors)?t.scaleFactors:[1]).map(Number).filter(s=>s>0).sort((s,n)=>s-n);return{width:e,height:i,scaleFactors:o}}).filter(t=>t.width>0&&t.height>0&&t.scaleFactors.length):[]}function B(r){return Array.isArray(r)?r.map(t=>({width:Number(t==null?void 0:t.width),height:Number(t==null?void 0:t.height)})).filter(t=>t.width>0&&t.height>0).sort((t,e)=>t.width-e.width):[]}function P(r,t,e,i,o=r.quality){const s=t.x===0&&t.y===0&&t.width===r.width&&t.height===r.height,n=s?"full":`${t.x},${t.y},${t.width},${t.height}`,c=s&&e===r.width&&i===r.height;let f;return r.version===3?f=c?"max":`${e},${i}`:f=c?"full":`${e},`,`${r.id}/${n}/${f}/0/${o}.${r.format}`}function C(r){return r.version===2&&r.level===0?"native":void 0}const p=new Map;function L(r,{request:t}={}){const e=g(r),i=p.get(e);if(i)return i;const o=`${e}/info.json`,s=j(t,o,{headers:{Accept:"application/ld+json, application/json"}}).then(async n=>{if(!n.ok)throw new y(`info.json request failed with ${n.status}`,o,n.status);return F(await n.json(),e)}).catch(n=>{throw p.delete(e),n});return p.set(e,s),s}export{C as a,O as b,L as f,P as i};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var $=Object.defineProperty;var U=(e,t,o)=>t in e?$(e,t,{enumerable:true,configurable:true,writable:true,value:o}):e[t]=o;var l=(e,t,o)=>U(e,typeof t!="symbol"?t+"":t,o);let x;function H(e){x=e}function Je(){return x}function V(e={}){return import("./shared-DFAX0n3B.mjs").then(t=>t.aI).then(t=>t.initCloverI18n(e))}const A=new Map,T=new Set;function _e(e,t,o){if(!A.has(t)){A.set(t,{index:e,css:o});for(const n of T)n.place(t,e,o)}}class W{constructor(t){l(this,"injected",new Set);this.doc=t,T.add(this),A.forEach(({index:o,css:n},i)=>this.place(i,o,n))}inject(t,o){this.injected.has(t)||(this.injected.add(t),this.doc.head.prepend(this.style(t,o)))}place(t,o,n){if(this.injected.has(t))return;this.injected.add(t);const i=this.style(t,n);i.dataset.cloverIndex=String(o);const c=[...this.doc.head.querySelectorAll("style[data-clover-index]")],k=c.filter(s=>Number(s.dataset.cloverIndex)<o).at(-1),w=c.find(s=>Number(s.dataset.cloverIndex)>o),v=this.doc.head.querySelectorAll("style[data-clover]");k?k.after(i):w?w.before(i):v.length?v[v.length-1].after(i):this.doc.head.prepend(i)}style(t,o){const n=this.doc.createElement("style");return n.dataset.clover=t,n.textContent=o,n}}const P=new WeakMap;function z(e){let t=P.get(e);return t||P.set(e,t=new W(e)),t}const M="@layer clover{:is(clover-root,clover-items,clover-viewer,clover-panel,clover-read-more):not([hidden]){display:block}:is(clover-body,clover-canvas,clover-timeline,clover-scene):not([hidden]){display:block;height:var(--clover-body-height,60vh)}clover-split:not([hidden]){display:flex}:is(clover-label,clover-panel-toggle):not([hidden]){display:contents}clover-tab,clover-tip,clover-status>[slot]{display:none}}";let B=null,f=null;const F=()=>B??(B=import("./shared-DFAX0n3B.mjs").then(e=>e.aJ).then(e=>f=e)),J=e=>e.trim().toLowerCase()==="false";function _(e,{type:t,min:o},n){if(e===null)return;if(t==="string")return e;if(t==="boolean")return!J(e);if(t==="number"){const c=Number(e);if(e.trim()===""||!Number.isFinite(c)){n("is not a number");return}if(o!==void 0&&c<o){n(`is less than ${o}`);return}return c}if(t==="data"){const c=e.trim();if(!/^[[{"]/.test(c))return e;try{return JSON.parse(c)}catch{n("is not JSON");return}}const i=e.trim().toLowerCase();if(t.includes(i))return i==="false"?false:i;n(`is not ${t.join(", ")}`)}const K=(e,t)=>{const o=Object.keys(e);return o.length===Object.keys(t).length&&o.every(n=>Object.is(e[n],t[n]))};function Q(e){class t extends HTMLElement{constructor(){super(...arguments);l(this,"kind",e.kind)}static get observedAttributes(){return Object.keys(e.attributes)}connectedCallback(){z(this.ownerDocument).inject("elements",M)}}customElements.define(e.tag,t)}function G(e,t){if(typeof customElements>"u"||customElements.get(e.tag))return;if(e.kind==="config"||!t)return Q(e);const o=e.kind,n=e.properties??[],i=Object.entries(e.events??{});let c=null,k=null;const w=()=>k??(k=Promise.all([t().then(s=>c=s),F()]));class v extends HTMLElement{constructor(){super(...arguments);l(this,"kind",o);l(this,"needsRoot",!!e.needsRoot);l(this,"values",{});l(this,"kept",{});l(this,"props",{});l(this,"listeners",new Set);l(this,"warned",new Set);l(this,"handlers",Object.fromEntries(i.map(([r,a])=>[a.prop,(...g)=>{var b;if(a.keeps&&(this.kept[a.keeps]=g[0]??null,g[0]==null))return true;const y=a.detail==="first"?g[0]:Object.fromEntries(a.detail.map((h,N)=>[h,g[N]])),E=new CustomEvent(r,{detail:y,bubbles:!a.keeps,composed:!a.keeps,cancelable:!!a.cancelable}),S=this.dispatchEvent(E);if(!S&&a.cancelable){const h=g[g.length-1];(b=h==null?void 0:h.preventDefault)==null||b.call(h)}return S}])));l(this,"getProps",()=>this.props);l(this,"subscribe",r=>(this.listeners.add(r),()=>{this.listeners.delete(r)}))}static get observedAttributes(){return Object.keys(e.attributes)}get element(){return this}get Component(){return c}connectedCallback(){for(const r of n){if(!Object.prototype.hasOwnProperty.call(this,r))continue;const a=this[r];delete this[r],a!=null&&(this.values[r]=a)}this.update(),this.warnOfAria(),z(this.ownerDocument).inject("elements",M),w().then(()=>{this.isConnected&&f.hostOf(this.ownerDocument).connect(this)})}disconnectedCallback(){queueMicrotask(()=>{this.isConnected||f==null||f.hostOf(this.ownerDocument).disconnect(this)})}attributeChangedCallback(){this.update()}warnOfAria(){if(!e.native)for(const r of["aria-label","aria-labelledby","role"])!this.hasAttribute(r)||this.warned.has(r)||(this.warned.add(r),console.warn(`<${e.tag}>: ${r} names the element, a box no reader is told of; Clover names what it draws itself.`))}update(){const r={...this.handlers,...this.values};for(const[a,g]of Object.entries(e.attributes)){if(g.prop in this.values)continue;const y=this.getAttribute(a),E=_(y,g,S=>{const b=`${a}=${y}`;this.warned.has(b)||(this.warned.add(b),console.warn(`<${e.tag}>: ${a}="${y}" ${S}; ignored.`))});E!==void 0&&(r[g.prop]=E)}K(r,this.props)||(this.props=r,this.listeners.forEach(a=>a()))}}l(v,"initCloverI18n",V);for(const s of n)Object.defineProperty(v.prototype,s,{configurable:true,enumerable:true,get(){return s in this.values?this.values[s]:this.getProps()[s]},set(m){m==null?delete this.values[s]:this.values[s]=m,this.update()}});for(const[,s]of i){if(!s.keeps)continue;const m=s.keeps;Object.defineProperty(v.prototype,m,{configurable:true,enumerable:true,get(){return this.kept[m]??null}})}customElements.define(e.tag,v)}const Y={tag:"clover-panel",kind:"part",needsRoot:true,attributes:{layout:{prop:"layout",type:["tabs","accordion"]},value:{prop:"value",type:"string"},"heading-level":{prop:"headingLevel",type:"number",min:1},download:{prop:"download",type:"boolean"},languages:{prop:"languages",type:"boolean"},sections:{prop:"sections",type:"data"},labels:{prop:"labels",type:"data"},closable:{prop:"closable",type:"boolean"},"close-on-escape":{prop:"closeOnEscape",type:"boolean"},as:{prop:"as",type:["aside","div"]}},events:{"clover-value-change":{prop:"onValueChange",detail:["value"]},"clover-close":{prop:"onClose",detail:[],cancelable:true}}},Z={tag:"clover-tab",kind:"config",attributes:{value:{prop:"value",type:"string"},label:{prop:"label",type:"string"}},slots:["label"]},X={tag:"clover-panel-toggle",kind:"part",attributes:{controls:{prop:"controls",type:"string"}},events:{"clover-open-change":{prop:"onOpenChange",detail:["open"],cancelable:true}}},ee={tag:"clover-split",kind:"part",native:true,attributes:{"storage-key":{prop:"storageKey",type:"string"}}},te={tag:"clover-split-pane",kind:"part",native:true,attributes:{size:{prop:"size",type:"string"},min:{prop:"min",type:"string"},max:{prop:"max",type:"string"},name:{prop:"name",type:"string"}}},oe={tag:"clover-split-handle",kind:"part",native:true,attributes:{}},q={"clover-ready":{prop:"onReady",detail:["handle"],keeps:"handle"}},O={"clover-content-state-change":{prop:"onContentStateChange",detail:"first"}},ne={tag:"clover-canvas",kind:"part",attributes:{"iiif-content":{prop:"iiifContent",type:"string"},src:{prop:"src",type:"string"},tiled:{prop:"isTiledImage",type:"boolean"},label:{prop:"label",type:"string"},language:{prop:"language",type:"string"},"high-contrast":{prop:"highContrast",type:"boolean"},controls:{prop:"controls",type:"boolean"},"collapse-controls":{prop:"collapseControls",type:["auto","always"]},navigator:{prop:"navigator",type:"boolean"},placeholder:{prop:"placeholder",type:"boolean"},"viewing-direction":{prop:"viewingDirection",type:["left-to-right","right-to-left","top-to-bottom","bottom-to-top"]},"animate-annotations":{prop:"animateAnnotations",type:"boolean"}},properties:["iiifContent","canvases","src","annotations","options","controlButtons","controls"],events:{...q,...O,"clover-annotation-select":{prop:"onAnnotationSelect",detail:["id"]},"clover-annotation-active":{prop:"onAnnotationActive",detail:["id"]},"clover-caption-change":{prop:"onCaptionChange",detail:["caption"]},"clover-ended":{prop:"onEnded",detail:[]}}},re={tag:"clover-timeline",kind:"part",attributes:{"iiif-content":{prop:"iiifContent",type:"string"},label:{prop:"label",type:"string"},language:{prop:"language",type:"string"},"high-contrast":{prop:"highContrast",type:"boolean"},controls:{prop:"controls",type:"boolean"},placeholder:{prop:"placeholder",type:"boolean"}},properties:["iiifContent","timeline","annotations","options","controls"],events:{...O,"clover-caption-change":{prop:"onCaptionChange",detail:["caption"]},"clover-ended":{prop:"onEnded",detail:[]}}},ae={tag:"clover-scene",kind:"part",attributes:{"iiif-content":{prop:"iiifContent",type:"string"},label:{prop:"label",type:"string"},language:{prop:"language",type:"string"},"high-contrast":{prop:"highContrast",type:"boolean"},controls:{prop:"controls",type:"boolean"},engine:{prop:"engine",type:["clover","three"]}},properties:["iiifContent","scene","options","controls"],events:{...O}},ie={tag:"clover-body",kind:"part",needsRoot:true,attributes:{controls:{prop:"controls",type:"boolean"},"collapse-controls":{prop:"collapseControls",type:["auto","always"]},navigator:{prop:"navigator",type:"boolean"},placeholder:{prop:"placeholder",type:"boolean"},"animate-annotations":{prop:"animateAnnotations",type:"boolean"}},properties:["controls","options","controlButtons","renderers"],events:{...q,...O,"clover-annotation-active":{prop:"onAnnotationActive",detail:["id"]},"clover-caption-change":{prop:"onCaptionChange",detail:["caption"]},"clover-ended":{prop:"onEnded",detail:[]}}},se={tag:"clover-items",kind:"part",attributes:{layout:{prop:"layout",type:["slider","list","grid","masonry","pager"]},secondary:{prop:"secondary",type:["summary","navDate","none"]},size:{prop:"size",type:["large","small"]},of:{prop:"of",type:["views","members","targets","annotations"]},navigation:{prop:"navigation",type:["id","homepage"]},"iiif-content":{prop:"iiifContent",type:"string"},header:{prop:"header",type:"boolean"},"heading-level":{prop:"headingLevel",type:"number",min:2},"thumbnail-size":{prop:"thumbnailSize",type:"number",min:1},"single-item":{prop:"singleItem",type:"boolean"},language:{prop:"language",type:"string"},"high-contrast":{prop:"highContrast",type:"boolean"}},properties:["iiifContent","items","request","renderItem"],events:{"clover-select":{prop:"onSelect",detail:["item"],cancelable:true}}},pe=["h1","h2","h3","h4","h5","h6","span","label","figcaption","p","strong","em","div"],le={tag:"clover-label",kind:"part",attributes:{of:{prop:"of",type:["manifest","canvas"]},as:{prop:"as",type:pe},label:{prop:"label",type:"data"}},properties:["label"]},ce={prop:"of",type:["manifest","canvas"]},D={prop:"value",type:"data"},d=(e,t={})=>({tag:e,kind:"part",attributes:{of:ce,value:D,...t},properties:["value"]}),de=d("clover-summary",{as:{prop:"as",type:["p","div","span"]}}),ge={...d("clover-metadata"),properties:["value","renderValue"]},ue=d("clover-required-statement"),ve=d("clover-rights"),he=d("clover-id"),me=d("clover-homepage"),ye=d("clover-rendering"),be=d("clover-see-also"),fe=d("clover-part-of"),Ce=d("clover-thumbnail",{size:{prop:"size",type:"number",min:1},alt:{prop:"alt",type:"string"}}),ke=d("clover-provider",{link:{prop:"link",type:["false"]}}),we=d("clover-logo",{alt:{prop:"alt",type:"string"}}),Ee={tag:"clover-value",kind:"part",attributes:{value:D,format:{prop:"format",type:"string"},"heading-level":{prop:"headingLevel",type:"number",min:1},as:{prop:"as",type:["span","p","div"]}},properties:["value"]},Se={tag:"clover-root",kind:"root",attributes:{"iiif-content":{prop:"iiifContent",type:"string"},"canvas-id":{prop:"canvasId",type:"string"},"manifest-id":{prop:"manifestId",type:"string"},language:{prop:"language",type:"string"},"high-contrast":{prop:"highContrast",type:"boolean"},"search-query":{prop:"searchQuery",type:"string"},annotations:{prop:"annotations",type:"data"},"annotation-pages":{prop:"annotationPages",type:["view","all"]},lang:{prop:"lang",type:"string"}},properties:["iiifContent","annotations","request","renderers"],events:{"clover-ready":{prop:"onReady",detail:["clover"],keeps:"clover"},"clover-canvas-change":{prop:"onCanvasChange",detail:["canvasId"]},"clover-manifest-change":{prop:"onManifestChange",detail:["manifestId"]},"clover-status-change":{prop:"onStatusChange",detail:["status","error"]},"clover-content-state-change":{prop:"onContentStateChange",detail:"first"}}},C={"heading-level":{prop:"headingLevel",type:"number",min:1}},I={of:{prop:"of",type:["views","members","targets"]}},Oe={tag:"clover-status",kind:"part",needsRoot:true,attributes:{loading:{prop:"loading",type:["false"]}},slots:["loading","error"]},Re={tag:"clover-position",kind:"part",needsRoot:true,attributes:{...I,as:{prop:"as",type:["span","p","div"]}}},Ae={tag:"clover-next",kind:"part",needsRoot:true,attributes:I},Ie={tag:"clover-previous",kind:"part",needsRoot:true,attributes:I},Pe={tag:"clover-download",kind:"part",needsRoot:true,attributes:C},je={tag:"clover-search",kind:"part",needsRoot:true,attributes:{...C,sticky:{prop:"sticky",type:"boolean"},size:{prop:"size",type:["large","small"]}}},Le={tag:"clover-contents",kind:"part",needsRoot:true,attributes:{}},xe={tag:"clover-transcript",kind:"part",needsRoot:true,attributes:{follow:{prop:"follow",type:"boolean"},find:{prop:"find",type:"boolean"},sticky:{prop:"sticky",type:"boolean"},size:{prop:"size",type:["large","small"]}}},Te={tag:"clover-annotations",kind:"part",needsRoot:true,attributes:{scope:{prop:"scope",type:["view","all"]},...C},properties:["renderEntry"]},ze={tag:"clover-collection",kind:"part",needsRoot:true,attributes:C},Me={tag:"clover-collection-select",kind:"part",needsRoot:true,attributes:{},events:{"clover-change":{prop:"onChange",detail:["manifestId"]}}},qe={tag:"clover-about",kind:"part",needsRoot:true,attributes:{"canvas-summary":{prop:"canvasSummary",type:"boolean"},download:{prop:"download",type:"boolean"},languages:{prop:"languages",type:"boolean"},thumbnail:{prop:"thumbnail",type:"boolean"},label:{prop:"label",type:"boolean"},...C}},De={tag:"clover-map",kind:"part",attributes:{"iiif-content":{prop:"iiifContent",type:"string"},overlay:{prop:"overlay",type:"boolean"},"overlay-opacity":{prop:"overlayOpacity",type:"number",min:0},"style-url":{prop:"styleUrl",type:"string"},"scroll-zoom":{prop:"scrollZoom",type:"boolean"},credits:{prop:"credits",type:"boolean"},language:{prop:"language",type:"string"},"high-contrast":{prop:"highContrast",type:"boolean"}},properties:["iiifContent","navPlace","georeferences","request"],events:{"clover-select":{prop:"onSelect",detail:["feature"]}}},Ne={tag:"clover-read-more",kind:"part",attributes:{}},$e={tag:"clover-tip",kind:"part",attributes:{label:{prop:"label",type:"string"},lang:{prop:"lang",type:"string"},keys:{prop:"keys",type:"string"},glyph:{prop:"glyph",type:"string"}},properties:["shortcut"]},Ue={tag:"clover-viewer",kind:"alone",attributes:{template:{prop:"template",type:["default","document","gallery"]},"iiif-content":{prop:"iiifContent",type:"string"},"canvas-id":{prop:"defaultCanvasId",type:"string"},"manifest-id":{prop:"defaultManifestId",type:"string"},language:{prop:"language",type:"string"},"high-contrast":{prop:"highContrast",type:"boolean"},"search-query":{prop:"searchQuery",type:"string"},annotations:{prop:"annotations",type:"data"},"heading-level":{prop:"headingLevel",type:"number",min:2},items:{prop:"items",type:["slider","list","grid","masonry","false"]},"single-item":{prop:"singleItem",type:"boolean"},header:{prop:"header",type:"boolean"},panel:{prop:"panel",type:"boolean"},download:{prop:"download",type:"boolean"},languages:{prop:"languages",type:"boolean"},"panel-open":{prop:"defaultPanelOpen",type:"boolean"},"panel-layout":{prop:"panelLayout",type:["accordion","tabs"]},"panel-sections":{prop:"panelSections",type:"data"},"panel-labels":{prop:"panelLabels",type:"data"},"sidebar-open":{prop:"defaultSidebarOpen",type:"boolean"},"storage-key":{prop:"storageKey",type:"string"},fill:{prop:"fill",type:"boolean"},"collapse-controls":{prop:"collapseControls",type:["auto","always"]},size:{prop:"size",type:"string"},height:{prop:"height",type:"string"},gap:{prop:"gap",type:"string"},secondary:{prop:"secondary",type:["summary","navDate","none"]},summary:{prop:"summary",type:"boolean"},"lightbox-items":{prop:"lightboxItems",type:["slider","pager"]}},properties:["iiifContent","annotations","request","renderers"],events:{"clover-canvas-change":{prop:"onCanvasChange",detail:["canvasId"]},"clover-manifest-change":{prop:"onManifestChange",detail:["manifestId"]},"clover-status-change":{prop:"onStatusChange",detail:["status","error"]},"clover-content-state-change":{prop:"onContentStateChange",detail:"first"}}},j=[Ue,Se,ie,le,se,Re,Ie,Ae,Oe,Ce,de,ge,ue,ve,me,be,ye,fe,he,ke,we,Ee,qe,Te,ze,Me,Le,je,xe,Pe,De,Y,Z,X,ee,te,oe,ne,re,ae,$e,Ne],p=(e,t,o)=>()=>Promise.all([e(),import("./part-D4gjnYmT.mjs")]).then(([n,{drawn:i}])=>i(n[t],o)),R=e=>()=>import("./split-P6J0qqf5.mjs").then(t=>t[e]),u=e=>p(()=>import("./Primitives-c9sIz0oQ.mjs"),e),L=e=>p(()=>import("./Pager-CN4lHURv.mjs"),e),He={"clover-viewer":()=>import("./viewer-DN2Mo3vc.mjs").then(e=>e.v).then(e=>e.ViewerElement),"clover-root":()=>import("./shared-DFAX0n3B.mjs").then(e=>e.aL).then(e=>e.RootElement),"clover-label":()=>import("./label-BGjL7I4b.mjs").then(e=>e.LabelElement),"clover-body":()=>import("./body-DPlfbLt3.mjs").then(e=>e.BodyElement),"clover-items":()=>import("./items-CWMI53aN.mjs").then(e=>e.ItemsElement),"clover-position":p(()=>import("./Position-DO5qg5Sp.mjs"),"Position"),"clover-previous":L("Previous"),"clover-next":L("Next"),"clover-status":()=>import("./status-honoOMNx.mjs").then(e=>e.StatusElement),"clover-thumbnail":u("Thumbnail"),"clover-summary":u("Summary"),"clover-metadata":p(()=>import("./Primitives-c9sIz0oQ.mjs"),"Metadata",["renderValue"]),"clover-required-statement":u("RequiredStatement"),"clover-rights":u("Rights"),"clover-homepage":u("Homepage"),"clover-see-also":u("SeeAlso"),"clover-rendering":u("Rendering"),"clover-part-of":u("PartOf"),"clover-id":u("Id"),"clover-provider":()=>import("./provider-CPp0Sgr_.mjs").then(e=>e.ProviderElement),"clover-logo":()=>import("./logo-BFstM-0a.mjs").then(e=>e.LogoElement),"clover-value":u("Value"),"clover-about":p(()=>import("./About-D1TBGGPL.mjs").then(e=>e.a),"About"),"clover-annotations":p(()=>import("./Annotations-Bvc_FmJ5.mjs"),"Annotations",["renderEntry"]),"clover-collection":p(()=>import("./Collection-B4CxBsFL.mjs"),"Collection"),"clover-collection-select":p(()=>import("./CollectionSelect-DO8YO2p7.mjs"),"CollectionSelect"),"clover-contents":p(()=>import("./Contents-AVPYYXht.mjs"),"Contents"),"clover-search":p(()=>import("./Search-BgxEW1UT.mjs"),"Search"),"clover-transcript":p(()=>import("./Transcript-WvFFAJQM.mjs"),"Transcript"),"clover-download":p(()=>import("./Download-Ci_JUTVd.mjs"),"Download"),"clover-map":p(()=>import("./Map-BEVtD52O.mjs"),"CloverMap"),"clover-panel":()=>import("./panel-BxxV_JkD.mjs").then(e=>e.PanelElement),"clover-panel-toggle":()=>import("./toggle-CJKdi5KH.mjs").then(e=>e.PanelToggleElement),"clover-split":R("SplitElement"),"clover-split-pane":R("SplitPaneElement"),"clover-split-handle":R("SplitHandleElement"),"clover-canvas":()=>import("./canvas-BUwBftJW.mjs").then(e=>e.CanvasElement),"clover-timeline":p(()=>import("./Timeline-B9tD3Rar.mjs"),"Timeline"),"clover-scene":p(()=>import("./Scene-CboEeptc.mjs"),"Scene"),"clover-tip":()=>import("./tip-BhNI83aT.mjs").then(e=>e.TipElement),"clover-read-more":()=>import("./read-more-lcqGslUd.mjs").then(e=>e.ReadMoreElement)};function Ve(e,t=j.map(({tag:o})=>o)){e.mapWorkerUrl&&H(e.mapWorkerUrl);for(const o of j)t.includes(o.tag)&&G(o,He[o.tag])}const We=""+new URL("assets/maplibre-gl-worker-kTz9OPxr.js",import.meta.url).href,Be={mapWorkerUrl:We};Ve(Be);export{_e as a,Ve as d,Je as g,V as i};
|
|
@@ -609,7 +609,7 @@ export interface CloverSceneElement extends HTMLElement {
|
|
|
609
609
|
iiifContent: string | Record<string, unknown> | null;
|
|
610
610
|
/** A Presentation 4 Scene to draw. */
|
|
611
611
|
scene: Record<string, unknown> | null;
|
|
612
|
-
/** request: credentials and headers for the Scene and its models; hideDelay: how long the controls stay after a mouse stops, in milliseconds. */
|
|
612
|
+
/** request: credentials and headers for the Scene and its models; hideDelay: how long the controls stay after a mouse stops or a finger lifts, in milliseconds (3000). */
|
|
613
613
|
options: { request?: Record<string, unknown>; hideDelay?: number } | null;
|
|
614
614
|
/** Which of the Body's controls it shows: false for none, or some ({ rotation: false }), in place of the attribute. */
|
|
615
615
|
controls: boolean | { zoom?: boolean; fullPage?: boolean; rotation?: boolean; reset?: boolean; information?: boolean } | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as n,i as o}from"./index-
|
|
1
|
+
import{d as n,i as o}from"./index-DspT4wUm.mjs";export{n as defineCloverElements,o as initCloverI18n};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{S as p,
|
|
1
|
+
import{S as p,Y as l,F as g,t as r,ad as v}from"./shared-DFAX0n3B.mjs";function h(t){var i;return(i=v(t).find(({body:a})=>a.type))==null?void 0:i.body.type}function y(t){const i=h(t)??(t.type==="Timeline"?"Sound":void 0);return{id:t.id,type:t.type,label:t.label,resource:t,duration:Number(t.duration)||void 0,media:i}}const d=new WeakMap;function w(t){if(!t)return[];let i=d.get(t);if(!i){const{canvases:a,views:e}=g(t);i=e.map(u=>{const n=u.map(s=>y(a[s]));return{id:n[0].id,parts:n,label:n.length===1?n[0].label:{none:[n.map(s=>r(s.label).text).filter(Boolean).join(" \u2013 ")]}}}),d.set(t,i)}return i}const f=new WeakMap;function o(t){if(!t)return[];let i=f.get(t);return i||(i=p(t.items).filter(a=>a==null?void 0:a.id).map(a=>{var e;return{id:a.id,parts:[y(a)],label:a.label,summary:a.summary,...typeof a.navDate=="string"?{navDate:a.navDate}:{},href:((e=p(a.homepage)[0])==null?void 0:e.id)??a.id,...l(p(a.homepage)[0])?{hrefLang:l(p(a.homepage)[0])}:{}}}),f.set(t,i)),i}function A(t){return t?Array.isArray(t)?o({items:t}):t.type==="Collection"?o(t):w(t):[]}export{w as a,A as b,o as i};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{T as m,u as r}from"./shared-DFAX0n3B.mjs";import{I as o}from"./Items-Drd82_Jj.mjs";import{w as n}from"./nodes-BleXuYE6.mjs";function I({props:t}){const e=m(()=>n(t,["renderItem"]),[t]);return r(o,{...e})}export{I as ItemsElement};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{u as e}from"./shared-DFAX0n3B.mjs";import{L as o}from"./Label-BIjqJ-_T.mjs";function n({props:r}){return e(o,{...r})}export{n as LabelElement};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a8 as L,a9 as j,S as p,aa as H,ab as E,B as G}from"./shared-
|
|
1
|
+
import{a8 as L,a9 as j,S as p,aa as H,ab as E,B as G}from"./shared-DFAX0n3B.mjs";import{b as O}from"./imageService-4sFnmAFX.mjs";import{c as J}from"./choice-key-BUNebLKe.mjs";const Q=/^((application|audio|video)\/)?(vnd\.apple\.|x-)?mpegurl$/i,U=(t,o)=>!!(t&&/\.m3u8$/i.test(t.split(/[?#]/)[0]))||!!(o&&Q.test(o)),X={width:1600,height:900};function tt(t,o){const e=new Array(t.length);if(!t.length)return e;const n=t.map(N),i=o==="left-to-right"||o==="right-to-left",s=o==="right-to-left"||o==="bottom-to-top",u=i?n[0].height:n[0].width,r=t.map((a,h)=>h);s&&r.reverse();let c=0;for(const a of r){const h=n[a],f=u/(i?h.height:h.width),y=h.width*f,g=h.height*f;e[a]=i?{x:c,y:0,width:y,height:g}:{x:0,y:c,width:y,height:g},c+=i?y:g}return e}function N(t){var s,u;if(t.width&&t.height)return{width:t.width,height:t.height};const o=R(t);if(o!=null&&o.width&&o.height)return{width:o.width,height:o.height};const e=((s=k(t)[0])==null?void 0:s.body)??((u=D(t)[0])==null?void 0:u.body),n=Number(e==null?void 0:e.width),i=Number(e==null?void 0:e.height);return n>0&&i>0?{width:n,height:i}:X}function R(t){return t.accompanyingContainer??t.placeholderContainer}function ot(t,o,e,n,i){return J(t.id,o.id,e,n,i)}function gt(t){const o=[];for(const e of t)W(e,(n,i)=>{const s=n;if((s==null?void 0:s.type)!=="Choice")return;const u=p(s.items).filter(r=>!!r&&typeof r=="object");u.length>1&&o.push({key:i,canvasId:e.id,label:s.label,items:u.map(r=>({label:r.label,id:r.id,...typeof r.type=="string"?{type:r.type}:{},...typeof r.format=="string"?{format:r.format}:{}}))})});return o}const F={};function et(t){if(t.type!=="Video"&&!E(t.type)||!t.format||U(t.id,t.format)||typeof document>"u")return true;const o=t.type==="Video"?"video":"audio",e=F[o]??(F[o]=document.createElement(o));return typeof e.canPlayType!="function"?true:e.canPlayType(t.format)!==""}function lt(t){const o={};for(const e of t){const n=e.items.findIndex(et);n>0&&(o[e.key]=n)}return o}const V=new WeakMap,z=[];function nt(t){return H(t).some(o=>((o==null?void 0:o.type)==="Choice"?p(o.items):[o]).some(n=>(n==null?void 0:n.type)==="Video"||E(n==null?void 0:n.type)))}function it(t){var u;const o=V.get(t);if(o)return o;const e=[];for(const r of t.items??[])for(const c of r.items??[]){if(!L(c))continue;const a=c.target?(u=j(c.target))==null?void 0:u.t:void 0;if(!a)continue;const[h,f]=a.split(",").map(Number);Number.isFinite(h)&&e.push({annotation:c,start:h,end:Number.isFinite(f)?f:NaN})}if(e.every(r=>nt(r.annotation)))return V.set(t,z),z;e.sort((r,c)=>r.start-c.start);const n=Number(t.duration),i=Number.isFinite(n)&&n/e.length||.5;e.forEach((r,c)=>{var h;const a=(h=e[c+1])==null?void 0:h.start;r.end>r.start||(a!=null?r.end=a>r.start?a:r.start+i:Number.isFinite(n)&&n>r.start?r.end=n:r.end>r.start||(r.end=r.start+i))});const s=e.length>1?e:z;return V.set(t,s),s}const A=t=>`frame:${t.id}`;function W(t,o){(t.items??[]).forEach((e,n)=>{(e.items??[]).forEach((i,s)=>{L(i)&&H(i).forEach((u,r)=>o(u,ot(t,i,n,s,r),i))})})}function k(t,o={},{allFrames:e=false}={}){const n=[];return M(t,o,(i,s,u)=>{i.body.type==="Image"&&n.push({body:i.body,region:i.region,...i.rotation?{rotation:i.rotation}:{},target:s,...u>=0?{frame:u}:{}})},e),n}function yt(t,o={}){for(const e of t){let n;if(M(e,o,i=>{n??(n=i.body.type)}),typeof n=="string")return n.toLowerCase()}}function D(t,o={}){const e=[];return M(t,o,(n,i,s,u)=>{const r=n.body.type;if(r!=="Video"&&!E(r))return;const c=G(u);e.push({kind:r==="Video"?"video":"audio",body:n.body,target:i,...c?{time:c}:{}})}),e}function rt(t){const o=t.filter(n=>n.time&&typeof n.body.id=="string"),e=new Set(o.map(n=>n.time.start));if(!(o.length<2||e.size!==o.length))return o.sort((n,i)=>n.time.start-i.time.start).map(n=>{const i=Number(n.body.duration)||(n.time.end!==void 0?n.time.end-n.time.start:void 0);return{src:n.body.id,...n.body.format?{format:n.body.format}:{},start:n.time.start,...i?{duration:i}:{}}})}function M(t,o,e,n=false){const i=t.width??0,s=t.height??0,u=it(t),r=Math.min(o[A(t)]??0,Math.max(0,u.length-1));W(t,(c,a,h)=>{const f=u.findIndex(x=>x.annotation===h);if(!n&&f>=0&&f!==r)return;const y=B(c,o[a]??0);if(!y)return;const g=h.target?j(h.target):void 0,b=g==null?void 0:g.rect;e(y,b?{x:b.x,y:b.y,width:b.w,height:b.h}:{x:0,y:0,width:i||Number(y.body.width)||0,height:s||Number(y.body.height)||0},f,g==null?void 0:g.t)})}function st(t){return ut(t).filter(o=>o.kind!=="transcript")}function ct(t){const o=p(t.provides);return o.includes("closedCaptions")?"captions":o.includes("subtitles")||o.includes("translation")?"subtitles":o.includes("transcript")?"transcript":"captions"}function ut(t){const o=[],e=[...t.annotations??[],...t.items??[]];for(const n of e)for(const i of n.items??[])if(p(i.motivation).includes("supplementing"))for(const s of p(i.body)){const u=s,r=(u==null?void 0:u.type)==="Choice"?p(u.items):[u];for(const c of r){const a=c==null?void 0:c.id;!((c==null?void 0:c.format)==="text/vtt"||typeof a=="string"&&/\.vtt(\?|$)/i.test(a))||typeof a!="string"||o.push({id:a,label:c.label,language:p(c.language)[0],kind:ct(i)})}}return o}function mt(t){const o=[],e=i=>{const s=i,u=s==null?void 0:s.id;if(typeof u!="string"||o.some(c=>c.id===u))return;const r=s==null?void 0:s.format;(r?r!=="text/plain":!/\.txt(\?|$)/i.test(u))||o.push({id:u,label:s==null?void 0:s.label,language:p(s==null?void 0:s.language)[0]})},n=[...t.annotations??[],...t.items??[]];for(const i of n)for(const s of i.items??[])if(p(s.motivation).includes("supplementing"))for(const u of p(s.body)){const r=u;((r==null?void 0:r.type)==="Choice"?p(r.items):[r]).forEach(e)}return p(t.rendering).forEach(e),o}function B(t,o=0){if(!t||typeof t!="object")return null;const e=t;if(e.type==="Choice"){const n=p(e.items);return B(n[o]??n[0])}if(e.type==="SpecificResource"&&e.source){const n=typeof e.source=="string"?{id:e.source}:e.source,i=p(e.selector).find(r=>(r==null?void 0:r.type)==="ImageApiSelector"),s=B({type:"Image",...n});if(!s)return null;const u=(i==null?void 0:i.rotation)!=null?String(i.rotation):void 0;return{...s,region:(i==null?void 0:i.region)||s.region,...u?{rotation:u}:{}}}return e.type!=="Image"&&e.type!=="Video"&&!E(e.type)?null:{body:e,region:typeof e.region=="string"?e.region:void 0}}function bt(t,o,e={},{standIns:n=true}={}){const i=tt(t,o),s=[],u=[],r={};return t.forEach((c,a)=>{const h=i[a],f=N(c),y=h.width/f.width,g=h.height/f.height,b=d=>({x:h.x+d.x*y,y:h.y+d.y*g,width:d.width*y,height:d.height*g}),x=D(c,e),T=k(c,e,{allFrames:true}).map(d=>({...d,canvas:c})),S=R(c);if(n&&!T.length&&x.some(d=>d.kind==="audio")&&S){const d=N(S);for(const l of k(S))T.push({...l,canvas:S,target:{x:l.target.x/d.width*f.width,y:l.target.y/d.height*f.height,width:l.target.width/d.width*f.width,height:l.target.height/d.height*f.height}})}const Y=e[A(c)]??0;T.forEach(({body:d,target:l,region:I,rotation:$,frame:w,canvas:Z},q)=>{var K;const C=O(d.service);if(!C&&!d.id)return;const _=`${Z.id}|${q}|${d.id??C}|${I??""}|${$??""}`,P=!(C&&I);if(s.push({id:_,service:C,url:d.id,width:P&&Number(d.width)||void 0,height:P&&Number(d.height)||void 0,region:I,...$?{rotation:$}:{},placement:b(l),...w!=null&&w!==Y?{hidden:true}:{}}),w!=null){const v=r[K=A(c)]??(r[K]=[]);(v[w]??(v[w]=[])).push(_)}});const[m]=x;if(m!=null&&m.body.id){const d=rt(x),l=d?d[0]:void 0;u.push({id:`${c.id}|media|${m.body.id}`,kind:m.kind,src:(l==null?void 0:l.src)??m.body.id,format:l?l.format:m.body.format,placement:b(m.target),duration:d?Number(c.duration)||void 0:Number(m.body.duration??c.duration)||void 0,...d?{segments:d}:{},poster:dt(c),captions:st(c)})}}),{images:s,media:u,placements:i,frames:r}}function dt(t){var o;return(o=ht(t))==null?void 0:o.source}const wt=1280;function ht(t){var c;const o=t.placeholderContainer;if(!o)return;const e=(c=k(o)[0])==null?void 0:c.body;if(!e)return;const n=O(e.service),i=typeof e.id=="string"?e.id:void 0,s=n?{service:n,fallback:i}:i?{src:i}:void 0;if(!s)return;const{width:u,height:r}=N(o);return{source:s,width:u,height:r}}function xt(t,o,e){const n=N(t),i=o.width/n.width,s=o.height/n.height;return{x:o.x+e.x*i,y:o.y+e.y*s,width:e.width*i,height:e.height*s}}export{wt as S,mt as a,it as b,ut as c,bt as d,ht as e,gt as f,A as g,xt as h,N as i,D as j,st as k,U as l,et as m,yt as p,B as r,lt as s};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{S as n,aa as p,a9 as c}from"./shared-
|
|
1
|
+
import{S as n,aa as p,a9 as c}from"./shared-DFAX0n3B.mjs";function g(r){if(n(r==null?void 0:r.motivation).includes("linking"))for(const i of p(r)){if((i==null?void 0:i.type)==="TextualBody"||typeof(i==null?void 0:i.value)=="string")continue;const t=(i==null?void 0:i.type)==="SpecificResource"?i.source:i,e=typeof t=="string"?t:t==null?void 0:t.id;if(!(typeof e!="string"||!e)){if((t==null?void 0:t.type)==="Canvas"){const f=n(t.partOf).find(s=>(s==null?void 0:s.id)&&(!s.type||s.type==="Manifest")),u=c(e).id;return{id:e,canvasId:u,...f?{manifestId:f.id}:{}}}if((t==null?void 0:t.type)==="Manifest"||(t==null?void 0:t.type)==="Collection")return{id:e,manifestId:e};if(/^https?:\/\//i.test(e))return{id:e}}}}function o(r){const i=n(r==null?void 0:r.motivation);if(!(!i.includes("tagging")&&!i.includes("identifying")))for(const t of p(r)){if((t==null?void 0:t.type)==="TextualBody"||typeof(t==null?void 0:t.value)=="string")continue;const e=(t==null?void 0:t.type)==="SpecificResource"?t.source:t,f=typeof e=="string"?e:e==null?void 0:e.id;if(typeof f=="string"&&/^https?:\/\//i.test(f))return{id:f}}}export{o as a,g as r};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{u as t}from"./shared-DFAX0n3B.mjs";import{L as n}from"./Provider-a3xY016W.mjs";function i({hosted:o,props:r}){var e;return((e=o.element.parentElement)==null?void 0:e.localName)==="clover-provider"?null:t(n,{...r})}export{i as LogoElement};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a8 as M,aa as l,S as f}from"./shared-
|
|
1
|
+
import{a8 as M,aa as l,S as f}from"./shared-DFAX0n3B.mjs";const m=45,d=75*Math.PI/180,h=5*Math.PI/180,p=Math.PI-h,y=1.1,g=.35,I=4;function P(n,a=1){const t=m*Math.PI/180,o=2*Math.atan(Math.tan(t/2)*a),s=Math.min(t,o);return Math.max(n,1e-6)/Math.sin(s/2)*y}function x(n,a=1){return{theta:0,phi:d,distance:P(n.radius,a)}}function E(n,a,t){return{...n,theta:n.theta+a,phi:Math.min(p,Math.max(h,n.phi+t))}}function R(n,a,t){const o=n.distance/a;return{...n,distance:Math.min(t.distance*I,Math.max(t.distance*g,o))}}function z(n,a){const{theta:t,phi:o,distance:s}=n;return[a[0]+s*Math.sin(o)*Math.sin(t),a[1]+s*Math.cos(o),a[2]+s*Math.sin(o)*Math.cos(t)]}function A(n,a){const t=(s,i)=>Math.abs(s-i)<1e-6,o=(n.theta-a.theta)%(2*Math.PI);return(t(o,0)||t(Math.abs(o),2*Math.PI))&&t(n.phi,a.phi)&&t(n.distance,a.distance)}const O=["model/gltf-binary","model/gltf+json"],c=(n,a)=>{const t=Number(n);return Number.isFinite(t)?t:a};function F(n){return n.format?O.includes(n.format.toLowerCase()):/\.(glb|gltf)(\?|#|$)/i.test(n.src)}function S(n){return f(n.transform).flatMap(a=>{const t=a,o=(t==null?void 0:t.type)==="ScaleTransform"?"scale":(t==null?void 0:t.type)==="RotateTransform"?"rotate":(t==null?void 0:t.type)==="TranslateTransform"?"translate":null;if(!o||!t)return[];const s=o==="scale"?1:0;return[{type:o,x:c(t.x,s),y:c(t.y,s),z:c(t.z,s)}]})}function b(n){for(const a of f(n)){const t=a;if((t==null?void 0:t.type)!=="SpecificResource")continue;const o=f(t.selector).find(s=>(s==null?void 0:s.type)==="PointSelector");if(o)return[c(o.x,0),c(o.y,0),c(o.z,0)]}return[0,0,0]}const u=new WeakMap;function _(n){const a=u.get(n);if(a)return a;const t=[];for(const o of n.items??[])for(const s of(o==null?void 0:o.items)??[])if(M(s))for(let i of l(s)){(i==null?void 0:i.type)==="Choice"&&(i=f(i.items)[0]);const r=(i==null?void 0:i.type)==="SpecificResource"?i:null,e=r?typeof r.source=="string"?{id:r.source,type:"Model"}:r.source:i;(e==null?void 0:e.type)!=="Model"||typeof e.id!="string"||t.push({id:String(s.id??e.id),src:e.id,...typeof e.format=="string"?{format:e.format}:{},...e.label?{label:e.label}:{},position:b(s.target),transforms:r?S(r):[]})}return u.set(n,t),t}function w(n){const a=n.backgroundColor;return typeof a=="string"&&/^#([0-9a-f]{3}|[0-9a-f]{6})$/i.test(a)?a:void 0}export{m as F,O as M,w as a,A as b,z as c,x as h,F as i,_ as s,E as t,R as z};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{A as i,q as f,C as p,_ as l,u as a}from"./shared-
|
|
1
|
+
import{A as i,q as f,C as p,_ as l,u as a}from"./shared-DFAX0n3B.mjs";const b={childList:true,subtree:true,attributes:true,attributeFilter:["value","label","slot","controls"]};function h(t,e,n){const r=i(null),o=f(s=>{const u=new MutationObserver(s);return u.observe(t,b),()=>u.disconnect()},[t]);return p(o,()=>{const s=e();return r.current&&n(r.current.value,s)?r.current.value:(r.current={value:s},s)})}const v=(t,e)=>[...t.children].find(n=>n.getAttribute("slot")===e)??null;function y(t,e){return h(t,()=>v(t,e),Object.is)}function C({of:t}){const e=i(null);return l(()=>{const n=e.current;if(!n)return;const r=()=>n.replaceChildren(...[...t.childNodes].map(c=>c.cloneNode(true)));r();const o=new MutationObserver(r);return o.observe(t,{childList:true,subtree:true,characterData:true,attributes:true}),()=>o.disconnect()},[t]),a("span",{ref:e,style:{display:"contents"}})}function M({from:t,stays:e}){const n=i(null);return l(()=>{const r=n.current;if(!r)return;const o=()=>{for(const s of[...t.childNodes])e(s)||r.append(s)};o();const c=new MutationObserver(o);return c.observe(t,{childList:true}),()=>{c.disconnect(),t.append(...r.childNodes)}},[t,e]),a("div",{ref:n,style:{display:"contents"}})}function O({from:t,picks:e}){const n=i(null);return l(()=>{const r=n.current;if(!r)return;let o=[];const c=()=>{const u=[...t.childNodes].filter(e);u.length&&(o=o.filter(d=>d.parentNode===r.parentNode),(o.at(-1)??r).after(...u),o.push(...u))};c();const s=new MutationObserver(c);return s.observe(t,{childList:true}),()=>{s.disconnect();for(const u of o)u.parentNode===r.parentNode&&t.append(u)}},[t,e]),a("span",{ref:n,hidden:true})}function N({value:t}){const e=i(null);return l(()=>{var n;(n=e.current)==null||n.replaceChildren(t instanceof Node?t:String(t))},[t]),a("span",{ref:e,style:{display:"contents"}})}function g(t,e){let n=t;for(const r of e){const o=t[r];typeof o=="function"&&(n={...n,[r]:(...c)=>{const s=o(...c);return s==null?s:a(N,{value:s})}})}return n}export{C,M,O as P,y as a,v as s,h as u,g as w};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as c,f as s}from"./imageService-
|
|
1
|
+
import{b as c,f as s}from"./imageService-4sFnmAFX.mjs";import{s as a}from"./sizedImage-jnOGcIIZ.mjs";async function l(r,o,i){const t=typeof r.id=="string"?r.id:void 0,e=c(r.service);if(!e)return t;try{const n=await s(e,{request:i});return a(n,o)??t}catch{return t}}export{l as overlayImageUrl};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as v,A as g,y as p,u as s}from"./shared-
|
|
1
|
+
import{d as v,A as g,y as p,u as s}from"./shared-DFAX0n3B.mjs";import{T as y,P as S}from"./Panel-CFYUlXup.mjs";import{u as b,M as C,C as w,s as A}from"./nodes-BleXuYE6.mjs";const k=l=>[...l.children].filter(t=>t.localName==="clover-tab").map((t,e)=>{const n=t.getAttribute("value")||String(e);return{element:t,value:n,label:t.getAttribute("label")||n,labelSlot:A(t,"label")}}),E=(l,t)=>l.length===t.length&&l.every((e,n)=>e.element===t[n].element&&e.value===t[n].value&&e.label===t[n].label&&e.labelSlot===t[n].labelSlot),M=l=>l instanceof Element&&l.getAttribute("slot")==="label",a=new WeakMap;let O=0;const P=l=>(a.has(l)||a.set(l,++O),a.get(l));function T(l){const t=l.ownerDocument;for(let e=l;e&&e!==t.body;e=e.parentElement){if(!e.id)continue;const n=e.id.replace(/["\\]/g,"\\$&");if(t.querySelector(`[aria-controls~="${n}"]`)){e.hidden=true;return}}l.hidden=true}function q({hosted:l,props:t}){const e=l.element,n=b(e,()=>k(e),E),{value:r,closable:i,onValueChange:m,onClose:f,...d}=t,[h,c]=v(r),u=g(r);return p(()=>{r!==u.current&&(u.current=r,r&&c(r))},[r]),s(S,{...d,value:h,onValueChange:o=>{c(o),m(o)},onClose:i?()=>{f()&&T(e)}:void 0,children:n.length?n.map(o=>s(y,{value:o.value,label:o.labelSlot?s(w,{of:o.labelSlot}):o.label,children:s(C,{from:o.element,stays:M})},P(o.element))):null})}export{q as PanelElement};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{T as i,u as e}from"./shared-DFAX0n3B.mjs";import{w as u}from"./nodes-BleXuYE6.mjs";function a(r,t=[]){return function({props:n}){const o=i(()=>u(n,t),[n]);return e(r,{...o})}}export{a as drawn};
|