@nulib/clover 4.0.0 → 4.1.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/Body.mjs +16 -1
- package/dist/components/Body/glyphs.mjs +15 -0
- package/dist/components/Canvas/CanvasView.mjs +116 -12
- package/dist/components/Canvas/ChaptersMenu.mjs +105 -0
- package/dist/components/Canvas/ControlMenu.mjs +23 -4
- package/dist/components/Canvas/Controls.mjs +223 -60
- package/dist/components/Canvas/ControlsFade.mjs +16 -0
- package/dist/components/Canvas/ImageControls.mjs +209 -0
- package/dist/components/Canvas/Placeholder.mjs +44 -12
- package/dist/components/Canvas/RowFits.mjs +85 -0
- package/dist/components/Canvas/layout.mjs +11 -0
- package/dist/components/Canvas/media/MediaBody.mjs +105 -46
- package/dist/components/Canvas/media/Player.mjs +0 -55
- package/dist/components/Canvas/media/Transport.mjs +14 -23
- package/dist/components/Canvas/panClearOfControls.mjs +1 -1
- package/dist/components/Collection/Collection.mjs +1 -1
- package/dist/components/Items/CountMenu.mjs +1 -0
- package/dist/components/Items/Item.mjs +4 -3
- package/dist/components/Items/Items.mjs +30 -10
- package/dist/components/Items/PagerLayout.mjs +2 -0
- package/dist/components/Items/TargetItems.mjs +1 -1
- package/dist/components/Items/masonry.mjs +35 -0
- package/dist/components/Panel/About.mjs +25 -8
- package/dist/components/Root/useRootState.mjs +2 -49
- package/dist/components/Scene/SceneView.mjs +13 -2
- package/dist/components/Scene/cloverEngine.mjs +2 -1
- package/dist/components/Timeline/playerSurface.mjs +2 -0
- package/dist/core/clover.mjs +7 -4
- package/dist/core/content-state.mjs +5 -3
- package/dist/i18n/locales/en.json.mjs +1 -1
- package/dist/i18n/locales/es.json.mjs +1 -1
- package/dist/i18n/locales/fi.json.mjs +1 -1
- package/dist/i18n/locales/fr.json.mjs +1 -1
- package/dist/i18n/locales/nb.json.mjs +1 -1
- package/dist/i18n/locales/nn.json.mjs +1 -1
- package/dist/i18n/locales/no.json.mjs +1 -1
- package/dist/i18n/locales/pt.json.mjs +1 -1
- package/dist/index.d.mts +109 -51
- package/dist/lib/gltf/load.mjs +26 -6
- package/dist/lib/renderer/CanvasRenderer.mjs +44 -32
- package/dist/lib/renderer/camera/Camera.mjs +1 -1
- package/dist/react/useContentStateOutput.mjs +71 -0
- package/dist/styles.css +1 -1
- package/dist/templates/default/Default.mjs +37 -128
- package/dist/templates/document/Document.mjs +41 -64
- package/dist/templates/document/Sheets.mjs +13 -5
- package/dist/templates/gallery/Gallery.mjs +90 -18
- package/dist/templates/index.d.mts +299 -17
- package/dist/templates/shared/Lightbox.mjs +161 -69
- package/dist/templates/shared/LightboxView.mjs +118 -0
- package/dist/templates/shared/PanelPane.mjs +104 -0
- package/dist/templates/{document/DocumentPanel.mjs → shared/PanelPart.mjs} +2 -2
- package/dist/templates/shared/dragToClose.mjs +51 -8
- package/dist/templates/shared/givenAnnotations.mjs +13 -0
- package/dist/templates/shared/useDragToClose.mjs +6 -3
- package/dist/templates/shared/useLazyPanelPane.mjs +16 -0
- package/dist/templates/shared/useSlide.mjs +6 -0
- package/dist/templates.css +1 -1
- package/dist/ui/ControlCluster.mjs +15 -17
- package/dist/ui/Sections.mjs +3 -3
- package/dist/ui/mediaIcons.mjs +35 -8
- package/dist/ui/useScrollTrack.mjs +2 -1
- package/dist/web-components/About-DvyvVUK5.mjs +1 -0
- package/dist/web-components/AnnotationItems-BpRcSrOM.mjs +1 -0
- package/dist/web-components/{AnnotationMenu-BCwwwfbb.mjs → AnnotationMenu-BDPec3iI.mjs} +1 -1
- package/dist/web-components/{AnnotationState-CavxnAAq.mjs → AnnotationState-Chs_37Kk.mjs} +1 -1
- package/dist/web-components/{Annotations-DDjSrBL5.mjs → Annotations-6E-oD_wg.mjs} +1 -1
- package/dist/web-components/{Annotations-rBmeI5sR.mjs → Annotations-CLPEq7Ro.mjs} +1 -1
- package/dist/web-components/Body-Ct61yxI7.mjs +1 -0
- package/dist/web-components/{BodyAlert-COKp19lq.mjs → BodyAlert-C_Qh3Up_.mjs} +1 -1
- package/dist/web-components/{Button-DLFYqtz9.mjs → Button-L8ZMy5lY.mjs} +1 -1
- package/dist/web-components/{Camera-Cp5ma-6C.mjs → Camera-BPyLzZjP.mjs} +1 -1
- package/dist/web-components/{Canvas2DBackend-3PToh87Z.mjs → Canvas2DBackend-8wFavYdl.mjs} +1 -1
- package/dist/web-components/CanvasView-2Fj9nT06.mjs +2 -0
- package/dist/web-components/CaptionDetails-DuwS-grE.mjs +1 -0
- package/dist/web-components/ChaptersMenu-Bj2EqtVJ.mjs +1 -0
- package/dist/web-components/{Chevron-r-_hUPn8.mjs → Chevron-Cyr_cc9X.mjs} +1 -1
- package/dist/web-components/ChoiceMenu-ConzybVH.mjs +1 -0
- package/dist/web-components/Collection-CLayN8sv.mjs +1 -0
- package/dist/web-components/{CollectionSelect-CBWUbqQi.mjs → CollectionSelect-D2d8dGJ4.mjs} +1 -1
- package/dist/web-components/{Connected-B2d6EoFl.mjs → Connected-CBQ6xyhr.mjs} +1 -1
- package/dist/web-components/{Connected-BSRM9FJY.mjs → Connected-DMXG3imZ.mjs} +1 -1
- package/dist/web-components/{Connected-BnpxYeJN.mjs → Connected-pyd0EBD3.mjs} +1 -1
- package/dist/web-components/{Contents-D7FPxSH-.mjs → Contents-tCMXBYDK.mjs} +1 -1
- package/dist/web-components/ControlMenu-D1zkB0qX.mjs +1 -0
- package/dist/web-components/ControlsFade-BNXVTL_Q.mjs +1 -0
- package/dist/web-components/{CountMenu-DyTp_J4k.mjs → CountMenu-Dnzb7lKo.mjs} +1 -1
- package/dist/web-components/Cue-CUGmPS3k.mjs +1 -0
- package/dist/web-components/Document-D-8nalCX.mjs +1 -0
- package/dist/web-components/{DomLayers-CTGub6wo.mjs → DomLayers-BxPU05-D.mjs} +1 -1
- package/dist/web-components/{Download-BOYNIb7C.mjs → Download-Bku9Vptk.mjs} +1 -1
- package/dist/web-components/{EntryBodies-Bfd2Z42z.mjs → EntryBodies-77vDudCb.mjs} +1 -1
- package/dist/web-components/{EntryThumbnail-DQE8ajI9.mjs → EntryThumbnail-BxQWKW6e.mjs} +1 -1
- package/dist/web-components/{FieldPill-D5DNJWLy.mjs → FieldPill-nFGsaru9.mjs} +1 -1
- package/dist/web-components/FrameAnimation-BvKiSXcm.mjs +1 -0
- package/dist/web-components/Gallery-4Hd58afA.mjs +1 -0
- package/dist/web-components/{HideToggle-DL911R1Z.mjs → HideToggle-TEhY4TS4.mjs} +1 -1
- package/dist/web-components/ImageControls-CZO7WoPb.mjs +1 -0
- package/dist/web-components/Items-CudZ4Lnb.mjs +1 -0
- package/dist/web-components/Label-f07N5Fld.mjs +1 -0
- package/dist/web-components/{LanguageChoice-DT1UPiDn.mjs → LanguageChoice-B5VM21DV.mjs} +1 -1
- package/dist/web-components/LightboxView-C4OASmkg.mjs +1 -0
- package/dist/web-components/ListEnd-M39M62Cl.mjs +1 -0
- package/dist/web-components/{Loaded-BWfEBJyg.mjs → Loaded-oGFyBuos.mjs} +1 -1
- package/dist/web-components/LoadedCanvas-IvpSzPO6.mjs +1 -0
- package/dist/web-components/LoadedMap-WATGNLxl.mjs +1 -0
- package/dist/web-components/{Loading-zw74TdAz.mjs → Loading-YxuKrDAM.mjs} +1 -1
- package/dist/web-components/{Map--dJhk0_0.mjs → Map-Cw9j3gi3.mjs} +1 -1
- package/dist/web-components/MapView-3OxoCr5l.mjs +3 -0
- package/dist/web-components/Markup-DW75Jx3j.mjs +2 -0
- package/dist/web-components/MediaBody-CLtd0bf0.mjs +1 -0
- package/dist/web-components/MediaBody-JnKnoIqY.mjs +1 -0
- package/dist/web-components/{NavDate-BQHuyLOC.mjs → NavDate-BCCOyycx.mjs} +1 -1
- package/dist/web-components/{Navigator-B3U21_ti.mjs → Navigator-Bx4zS0Yr.mjs} +1 -1
- package/dist/web-components/{Pager-DnJknq92.mjs → Pager-B9GvQ64b.mjs} +1 -1
- package/dist/web-components/PagerLayout-BF33VZL_.mjs +1 -0
- package/dist/web-components/Panel-BvDpCn6K.mjs +1 -0
- package/dist/web-components/PanelPart-Bd4lSUrP.mjs +1 -0
- package/dist/web-components/{PanelToggle-CFtWIeWv.mjs → PanelToggle-bPcIULGZ.mjs} +1 -1
- package/dist/web-components/{PartOfManifest-F87jIrf9.mjs → PartOfManifest-HLg-r00O.mjs} +1 -1
- package/dist/web-components/{Pending-CYAQajKu.mjs → Pending-BxGjjnqq.mjs} +1 -1
- package/dist/web-components/PlaceBox-D-Zhe9-U.mjs +1 -0
- package/dist/web-components/Placeholder-DzY5hcbk.mjs +1 -0
- package/dist/web-components/{Position-BkWBRBfW.mjs → Position-TYnzcm8e.mjs} +1 -1
- package/dist/web-components/{Primitives-BmODPlnK.mjs → Primitives-C6VJXxZD.mjs} +1 -1
- package/dist/web-components/Provider-DyB0wpeO.mjs +1 -0
- package/dist/web-components/{ReadMore-BwGFsLS2.mjs → ReadMore-De_0T7lc.mjs} +1 -1
- package/dist/web-components/Root-Bt3NNBFb.mjs +1 -0
- package/dist/web-components/Scene-DrOM9YlD.mjs +1 -0
- package/dist/web-components/SceneView-DA7Yg20p.mjs +1 -0
- package/dist/web-components/{Search-CbmK9vLp.mjs → Search-DgT8OPsK.mjs} +1 -1
- package/dist/web-components/{Sections-Dy5_pkyQ.mjs → Sections-d1acn7qm.mjs} +2 -2
- package/dist/web-components/{StandaloneItems-BmUnBp0H.mjs → StandaloneItems-DUb4YKCB.mjs} +1 -1
- package/dist/web-components/{Status-Dww3Pyf4.mjs → Status-CcU3u6P4.mjs} +1 -1
- package/dist/web-components/{Steps-o_UprQfZ.mjs → Steps-nlSCzbDQ.mjs} +1 -1
- package/dist/web-components/{TargetItems-BBOGDubv.mjs → TargetItems-BDJM3Ar-.mjs} +1 -1
- package/dist/web-components/Timeline-BfdN3lIv.mjs +1 -0
- package/dist/web-components/{Tip-BbexILXs.mjs → Tip-OCB88zwY.mjs} +1 -1
- package/dist/web-components/{Transcript-ZVXM3ZDA.mjs → Transcript-bSA3cx_K.mjs} +1 -1
- package/dist/web-components/Transport-DaIhfZqC.mjs +1 -0
- package/dist/web-components/Transport-DjOYI-fR.mjs +1 -0
- package/dist/web-components/{annotation-collection-7SS1ELcO.mjs → annotation-collection-D8emkElk.mjs} +1 -1
- package/dist/web-components/{annotation-name-CYkZopdd.mjs → annotation-name-DbWjhgra.mjs} +1 -1
- package/dist/web-components/{annotations-content-Bdtn50sf.mjs → annotations-content-Bg6aVAGC.mjs} +1 -1
- package/dist/web-components/{body-CkOBHlJ0.mjs → body-Ct8dmQdW.mjs} +1 -1
- package/dist/web-components/canvas-goEZLqEd.mjs +1 -0
- package/dist/web-components/cloverEngine-Df7cMwOP.mjs +164 -0
- package/dist/web-components/{content-state-reader-Ahh6artg.mjs → content-state-reader-CNmBpG1L.mjs} +1 -1
- package/dist/web-components/{controls-BJrZVQkS.mjs → controls-BZr16sYQ.mjs} +1 -1
- package/dist/web-components/custom-elements.json +160 -44
- package/dist/web-components/{downloads-CqVWo-yn.mjs → downloads-EjJ6Hpip.mjs} +1 -1
- package/dist/web-components/dragToClose-X9NbZOhA.mjs +1 -0
- package/dist/web-components/{engine-B-sscpLa.mjs → engine-DMoc0tff.mjs} +1 -1
- package/dist/web-components/{engines-DfCHjbt3.mjs → engines-BmB81VXR.mjs} +1 -1
- package/dist/web-components/es-B1NvdYp-.mjs +1 -0
- package/dist/web-components/{fetchManifest-BIzne1Pj.mjs → fetchManifest-CwQC6cCh.mjs} +1 -1
- package/dist/web-components/fi-BjtYZNLo.mjs +1 -0
- package/dist/web-components/fr-Cd22Lziw.mjs +1 -0
- package/dist/web-components/fromManifest-DrAmY1lB.mjs +1 -0
- package/dist/web-components/glyphs-BFK_hvJJ.mjs +1 -0
- package/dist/web-components/hooks-BhtNDs_1.mjs +1 -0
- package/dist/web-components/image-layers-D2nQC4R-.mjs +1 -0
- package/dist/web-components/{imageService-0eTvQ-3h.mjs → imageService-iFElsopt.mjs} +1 -1
- package/dist/web-components/index-FJEpXukG.mjs +1 -0
- package/dist/web-components/index.d.mts +4 -4
- package/dist/web-components/index.mjs +1 -1
- package/dist/web-components/items-BPPrqbeh.mjs +1 -0
- package/dist/web-components/items-BnEnc5ot.mjs +1 -0
- package/dist/web-components/label-DauFa5sg.mjs +1 -0
- package/dist/web-components/layout-Djwu8f4R.mjs +1 -0
- package/dist/web-components/{link-GEdiEwlR.mjs → link-0lUlTZlw.mjs} +1 -1
- package/dist/web-components/logo-DWPxaZaG.mjs +1 -0
- package/dist/web-components/masonry-0QfzOgbB.mjs +1 -0
- package/dist/web-components/{models-59cEeiAA.mjs → models-BF2pqufA.mjs} +1 -1
- package/dist/web-components/nb-CEwZDBiR.mjs +1 -0
- package/dist/web-components/nn-jYQhr9RI.mjs +1 -0
- package/dist/web-components/no-CEwZDBiR.mjs +1 -0
- package/dist/web-components/{nodes-CTw9OqlA.mjs → nodes-ChQRLDGU.mjs} +1 -1
- package/dist/web-components/{overlayImage-BMt4UTlR.mjs → overlayImage-MKrcgDep.mjs} +1 -1
- package/dist/web-components/panClearOfControls-Cn2ZXsZi.mjs +1 -0
- package/dist/web-components/{panel-C17Rl9Ya.mjs → panel-C13V6w6E.mjs} +1 -1
- package/dist/web-components/part-CekFWrtz.mjs +1 -0
- package/dist/web-components/playerSurface-DG1XipTq.mjs +1 -0
- package/dist/web-components/pointer-YQppt0at.mjs +1 -0
- package/dist/web-components/{provider-BpxorEiq.mjs → provider-DiUkZYiW.mjs} +1 -1
- package/dist/web-components/pt-CWR30SzS.mjs +1 -0
- package/dist/web-components/{range-regions-BGQy4E9U.mjs → range-regions-CqGjyM76.mjs} +1 -1
- package/dist/web-components/{read-more-BDM_6CVc.mjs → read-more-D8RJYdtQ.mjs} +1 -1
- package/dist/web-components/readingLanguages-BWOLZK2k.mjs +1 -0
- package/dist/web-components/rendererSurface-BkbGDL_Z.mjs +22 -0
- package/dist/web-components/{renderers-CiB74bQh.mjs → renderers-LtRX5pT0.mjs} +1 -1
- package/dist/web-components/{resource-CRbpf9pX.mjs → resource-Cfydiy4m.mjs} +1 -1
- package/dist/web-components/{save-file-CCuZEuQr.mjs → save-file-dZyOpXgY.mjs} +1 -1
- package/dist/web-components/search-BfUZJM3a.mjs +1 -0
- package/dist/web-components/shared-DkY2a89G.mjs +1 -0
- package/dist/web-components/{show-link-BXm7SNIC.mjs → show-link-DgLJzG7k.mjs} +1 -1
- package/dist/web-components/{sizedImage-k4Q-eyOB.mjs → sizedImage-NHzhcBYk.mjs} +1 -1
- package/dist/web-components/{split-Hp6z-v4h.mjs → split-CuFiKjin.mjs} +1 -1
- package/dist/web-components/{status-BmtuKfAG.mjs → status-C3etlkhY.mjs} +1 -1
- package/dist/web-components/styles-DkkVOSUQ.mjs +1 -0
- package/dist/web-components/three.mjs +1 -1
- package/dist/web-components/{thumbnail-Dp7a8oom.mjs → thumbnail-DecrVnpj.mjs} +1 -1
- package/dist/web-components/{tip-C-oovDZK.mjs → tip-D5YgaIWW.mjs} +1 -1
- package/dist/web-components/{toggle-C7ODWDEZ.mjs → toggle-CZGB65VZ.mjs} +1 -1
- package/dist/web-components/{useContainerName-CrOmY-km.mjs → useContainerName-hKQjEt7a.mjs} +1 -1
- package/dist/web-components/useControlsVisibility-DPg8uAkW.mjs +1 -0
- package/dist/web-components/useLazyPanelPane-eby-OI1V.mjs +1 -0
- package/dist/web-components/{useNearViewport-BqXi9Gn4.mjs → useNearViewport-CDbHQUBk.mjs} +1 -1
- package/dist/web-components/useScrollTrack-D9l_P3_B.mjs +1 -0
- package/dist/web-components/viewer/AnnotationItems-DtsnDXPM.mjs +1 -0
- package/dist/web-components/viewer/{AnnotationMenu-DPOSehBo.mjs → AnnotationMenu-C-Mz6CCn.mjs} +1 -1
- package/dist/web-components/viewer/AnnotationState-5pim5K72.mjs +1 -0
- package/dist/web-components/viewer/Annotations-Cqn1TkzD.mjs +2 -0
- package/dist/web-components/viewer/Annotations-CxwN9FkB.mjs +1 -0
- package/dist/web-components/viewer/{Canvas2DBackend-BTK6ZJh0.mjs → Canvas2DBackend-C-ZMSCak.mjs} +1 -1
- package/dist/web-components/viewer/CaptionDetails-CRD-gSZP.mjs +1 -0
- package/dist/web-components/viewer/ChaptersMenu-Brcq3yJv.mjs +1 -0
- package/dist/web-components/viewer/{ChoiceMenu-DQ1x572Y.mjs → ChoiceMenu-ByGzQQx1.mjs} +1 -1
- package/dist/web-components/viewer/Collection-m0GCcsfQ.mjs +1 -0
- package/dist/web-components/viewer/Connected-Bmc_CdUD.mjs +1 -0
- package/dist/web-components/viewer/Connected-Dvx7wtot.mjs +1 -0
- package/dist/web-components/viewer/Contents-CwDpfiJY.mjs +1 -0
- package/dist/web-components/viewer/ControlMenu-TcO85hDf.mjs +1 -0
- package/dist/web-components/viewer/ControlsFade-BoZ4ABAE.mjs +1 -0
- package/dist/web-components/viewer/{CountMenu-4u6U6yqb.mjs → CountMenu-0-ie8kIZ.mjs} +1 -1
- package/dist/web-components/viewer/Cue-DxmAS9Gx.mjs +1 -0
- package/dist/web-components/viewer/Document-BsryuYJ1.mjs +1 -0
- package/dist/web-components/viewer/{DomLayers-CGkDtemL.mjs → DomLayers-hc0qARQc.mjs} +1 -1
- package/dist/web-components/viewer/Download-MO-1Rik4.mjs +1 -0
- package/dist/web-components/viewer/EntryBodies-g-OEwEsk.mjs +1 -0
- package/dist/web-components/viewer/EntryThumbnail-DcIDYATi.mjs +1 -0
- package/dist/web-components/viewer/{FieldPill-DFXGWrvB.mjs → FieldPill-B9S21lxw.mjs} +1 -1
- package/dist/web-components/viewer/FrameAnimation-qI9cZPEs.mjs +1 -0
- package/dist/web-components/viewer/Gallery-BOgUqfqw.mjs +1 -0
- package/dist/web-components/viewer/{HideToggle-DP5kHzWM.mjs → HideToggle-D8wH49mq.mjs} +1 -1
- package/dist/web-components/viewer/ImageControls-ZoEC9jWd.mjs +1 -0
- package/dist/web-components/viewer/LanguageChoice-CRqsCBAp.mjs +1 -0
- package/dist/web-components/viewer/LightboxView-BB-GcbYr.mjs +1 -0
- package/dist/web-components/viewer/ListEnd-D9Obxie4.mjs +1 -0
- package/dist/web-components/viewer/{MapView-BN9wXQKV.mjs → MapView-DQSwUzd7.mjs} +2 -2
- package/dist/web-components/viewer/MediaBody-CIw2nTlj.mjs +1 -0
- package/dist/web-components/viewer/MediaBody-D5ff6xy-.mjs +1 -0
- package/dist/web-components/viewer/{NavDate-C2-wwLuB.mjs → NavDate-BnfDG57h.mjs} +1 -1
- package/dist/web-components/viewer/{Navigator-C3jghOd3.mjs → Navigator-BNwjmkXY.mjs} +1 -1
- package/dist/web-components/viewer/PagerLayout-C8jraHqs.mjs +1 -0
- package/dist/web-components/viewer/PanelPart-YNbBI9SQ.mjs +1 -0
- package/dist/web-components/viewer/{PartOfManifest-D22yMgCf.mjs → PartOfManifest-DX7H0V4g.mjs} +1 -1
- package/dist/web-components/viewer/PlaceBox-CCWfzsNU.mjs +1 -0
- package/dist/web-components/viewer/Placeholder-CsEkLhz7.mjs +1 -0
- package/dist/web-components/viewer/Search-CsdYzdq1.mjs +1 -0
- package/dist/web-components/viewer/StandaloneItems-BfvBxbUm.mjs +1 -0
- package/dist/web-components/viewer/{Steps-Bw32X5xO.mjs → Steps-BH8ZApS4.mjs} +1 -1
- package/dist/web-components/viewer/{TargetItems-DLhUH1Gq.mjs → TargetItems-BebPFr-c.mjs} +1 -1
- package/dist/web-components/viewer/Transcript-DXLv5WR9.mjs +1 -0
- package/dist/web-components/viewer/Transport-C-fh7Kx2.mjs +1 -0
- package/dist/web-components/viewer/Transport-CY6BWfMi.mjs +1 -0
- package/dist/web-components/viewer/annotation-collection-Cjd8Dgyl.mjs +1 -0
- package/dist/web-components/viewer/annotation-name-CwmgQFia.mjs +1 -0
- package/dist/web-components/viewer/{annotations-content-CbA3eOIC.mjs → annotations-content-BARXoAz-.mjs} +1 -1
- package/dist/web-components/viewer/cloverEngine-CumnJPKO.mjs +164 -0
- package/dist/web-components/viewer/{content-state-reader-C7UBMOq3.mjs → content-state-reader-DuvyLThu.mjs} +1 -1
- package/dist/web-components/viewer/dragToClose-CFCxhUxn.mjs +1 -0
- package/dist/web-components/viewer/{fetchManifest-C2Yxg3x9.mjs → fetchManifest-qNB_KgxL.mjs} +1 -1
- package/dist/web-components/viewer/{host-CZeyjCKR.mjs → host-GTHX2fPK.mjs} +1 -1
- package/dist/web-components/viewer/image-layers-DKOuaRTj.mjs +1 -0
- package/dist/web-components/viewer/index.mjs +1 -1
- package/dist/web-components/viewer/{link-DssZ0Z2N.mjs → link-BlaM0tCa.mjs} +1 -1
- package/dist/web-components/viewer/overlayImage-RVpv69R5.mjs +1 -0
- package/dist/web-components/viewer/range-regions-CIZiAHOp.mjs +1 -0
- package/dist/web-components/viewer/{renderers-DLoqv3QO.mjs → renderers-Dw1klwlx.mjs} +1 -1
- package/dist/web-components/viewer/{save-file-CJT5p5Hg.mjs → save-file-EvzaBEJN.mjs} +1 -1
- package/dist/web-components/viewer/{search-PhOwMKHi.mjs → search-x1QL_bth.mjs} +1 -1
- package/dist/web-components/viewer/styles-I7_LWFGj.mjs +1 -0
- package/dist/web-components/viewer/useControlsVisibility-C_SQHIVR.mjs +1 -0
- package/dist/web-components/viewer/useLazyPanelPane-UuGDJrf_.mjs +1 -0
- package/dist/web-components/viewer/viewer-DJrQuNs1.mjs +29 -0
- package/dist/web-components/viewer/{vtt-1Pk7Dhsj.mjs → vtt-C2G89SWH.mjs} +1 -1
- package/dist/web-components/viewer-Br44EEba.mjs +1 -0
- package/dist/web-components/{vtt-CacHieeN.mjs → vtt-Dd0c7psH.mjs} +1 -1
- package/package.json +1 -1
- package/dist/templates/shared/LightboxBody.mjs +0 -9
- package/dist/web-components/About-DhOGPFaI.mjs +0 -1
- package/dist/web-components/AnnotationItems-CNP4CJiT.mjs +0 -1
- package/dist/web-components/Body-DaY1UJIy.mjs +0 -1
- package/dist/web-components/BodyUnloadable-DcTM7hHF.mjs +0 -1
- package/dist/web-components/CanvasView-BWQ4SK2b.mjs +0 -2
- package/dist/web-components/CaptionDetails-DSziiuQV.mjs +0 -1
- package/dist/web-components/ChoiceMenu-DTuEEUeM.mjs +0 -1
- package/dist/web-components/Collection-B9swJtPW.mjs +0 -1
- package/dist/web-components/ControlMenu-Crtho2cs.mjs +0 -1
- package/dist/web-components/Cue-CbZaGwZh.mjs +0 -1
- package/dist/web-components/Document-BfltLWZZ.mjs +0 -1
- package/dist/web-components/DocumentPanel-ZSe40cV4.mjs +0 -1
- package/dist/web-components/FrameAnimation-IfR1czfc.mjs +0 -1
- package/dist/web-components/Gallery-DD06BDQo.mjs +0 -1
- package/dist/web-components/Items-BHzT9A73.mjs +0 -1
- package/dist/web-components/Label-KabnxuMN.mjs +0 -1
- package/dist/web-components/LightboxBody-BhRhdXo6.mjs +0 -1
- package/dist/web-components/ListEnd-CbwNlty-.mjs +0 -1
- package/dist/web-components/LoadedCanvas-CdZ5WOWz.mjs +0 -1
- package/dist/web-components/LoadedMap-DQyQVRVQ.mjs +0 -1
- package/dist/web-components/MapView-duA5WGsu.mjs +0 -3
- package/dist/web-components/Markup-D-kioDf9.mjs +0 -2
- package/dist/web-components/MediaBody-CoOiVXcv.mjs +0 -1
- package/dist/web-components/MediaBody-d8ErTuwT.mjs +0 -1
- package/dist/web-components/PagerLayout-CvOmKtSW.mjs +0 -1
- package/dist/web-components/Panel-CIdjOznL.mjs +0 -1
- package/dist/web-components/PlaceBox-BtIbIotm.mjs +0 -1
- package/dist/web-components/Placeholder-TIyj4ZjR.mjs +0 -1
- package/dist/web-components/Provider-C8se8i4I.mjs +0 -1
- package/dist/web-components/Root-CAJB0-Mh.mjs +0 -1
- package/dist/web-components/Scene-Ctcdt7CD.mjs +0 -1
- package/dist/web-components/SceneView-B6bEx_7x.mjs +0 -1
- package/dist/web-components/Timeline-CfIF4APc.mjs +0 -1
- package/dist/web-components/canvas-CWf_Fag8.mjs +0 -1
- package/dist/web-components/cloverEngine-6djEHNCD.mjs +0 -164
- package/dist/web-components/dragToClose-C-Pf1IeO.mjs +0 -1
- package/dist/web-components/es-BYfHUZ7P.mjs +0 -1
- package/dist/web-components/fi-B5y2qr8T.mjs +0 -1
- package/dist/web-components/fr-ChezCx6V.mjs +0 -1
- package/dist/web-components/fromManifest-gg5Wx14y.mjs +0 -1
- package/dist/web-components/glyphs-JYl2STEr.mjs +0 -1
- package/dist/web-components/hooks-x7rO95CS.mjs +0 -1
- package/dist/web-components/image-layers-BjbeyHBS.mjs +0 -1
- package/dist/web-components/index-BZ7b9k0N.mjs +0 -1
- package/dist/web-components/items-CnAIl9fS.mjs +0 -1
- package/dist/web-components/items-F6hJgdAS.mjs +0 -1
- package/dist/web-components/label-CI88KH2_.mjs +0 -1
- package/dist/web-components/layout-De1MOSYe.mjs +0 -1
- package/dist/web-components/logo-Ckwj7FlP.mjs +0 -1
- package/dist/web-components/nb-8J22f9Td.mjs +0 -1
- package/dist/web-components/nn-Dv1EvzI1.mjs +0 -1
- package/dist/web-components/no-8J22f9Td.mjs +0 -1
- package/dist/web-components/panClearOfControls-ac9uf-Qs.mjs +0 -1
- package/dist/web-components/part-CXts97_M.mjs +0 -1
- package/dist/web-components/playerSurface-HYwEwPK6.mjs +0 -1
- package/dist/web-components/pt-DWYQkATt.mjs +0 -1
- package/dist/web-components/readingLanguages-fs_HqvqQ.mjs +0 -1
- package/dist/web-components/rendererSurface-C0aKlE0v.mjs +0 -22
- package/dist/web-components/search-CkM0O0Z1.mjs +0 -1
- package/dist/web-components/shared-MTsMddHx.mjs +0 -1
- package/dist/web-components/styles-CZV1nbBQ.mjs +0 -1
- package/dist/web-components/useScrollTrack-CEsOU2yT.mjs +0 -1
- package/dist/web-components/viewer/AnnotationItems-CyhVcRFc.mjs +0 -1
- package/dist/web-components/viewer/AnnotationState-Bjztkobn.mjs +0 -1
- package/dist/web-components/viewer/Annotations-Dh_8Tzi0.mjs +0 -2
- package/dist/web-components/viewer/Annotations-wwuOCxzI.mjs +0 -1
- package/dist/web-components/viewer/CaptionDetails-BwCTovy_.mjs +0 -1
- package/dist/web-components/viewer/Collection-DSBxCmXw.mjs +0 -1
- package/dist/web-components/viewer/Connected-CL3N8F2J.mjs +0 -1
- package/dist/web-components/viewer/Connected-DTk1jlyI.mjs +0 -1
- package/dist/web-components/viewer/Contents-DrXckx7d.mjs +0 -1
- package/dist/web-components/viewer/ControlMenu-Bp91s-g_.mjs +0 -1
- package/dist/web-components/viewer/Cue-C-aF8peC.mjs +0 -1
- package/dist/web-components/viewer/Document-BN1rICu3.mjs +0 -1
- package/dist/web-components/viewer/DocumentPanel-CEesxdeY.mjs +0 -1
- package/dist/web-components/viewer/Download-CawEl9MN.mjs +0 -1
- package/dist/web-components/viewer/EntryBodies-nYHMwSSM.mjs +0 -1
- package/dist/web-components/viewer/EntryThumbnail-DrO_0SzR.mjs +0 -1
- package/dist/web-components/viewer/FrameAnimation-CZfzpxaD.mjs +0 -1
- package/dist/web-components/viewer/Gallery-MWHtvjti.mjs +0 -1
- package/dist/web-components/viewer/LanguageChoice-C50T7dPI.mjs +0 -1
- package/dist/web-components/viewer/LightboxBody-C2T7IC29.mjs +0 -1
- package/dist/web-components/viewer/ListEnd-BDuOx__m.mjs +0 -1
- package/dist/web-components/viewer/MediaBody-CEyswliX.mjs +0 -1
- package/dist/web-components/viewer/MediaBody-Dw3DWDjc.mjs +0 -1
- package/dist/web-components/viewer/PagerLayout-Cg2NpqoD.mjs +0 -1
- package/dist/web-components/viewer/PlaceBox-Dckw4Sfk.mjs +0 -1
- package/dist/web-components/viewer/Placeholder-NYVWYg5Q.mjs +0 -1
- package/dist/web-components/viewer/Search-DC259m4f.mjs +0 -1
- package/dist/web-components/viewer/StandaloneItems-E4kpMne9.mjs +0 -1
- package/dist/web-components/viewer/Transcript-D_VGJQxn.mjs +0 -1
- package/dist/web-components/viewer/annotation-collection-DZHa18ir.mjs +0 -1
- package/dist/web-components/viewer/annotation-name-BaNdW2Xk.mjs +0 -1
- package/dist/web-components/viewer/cloverEngine-C04bCSFR.mjs +0 -164
- package/dist/web-components/viewer/image-layers-B09fporZ.mjs +0 -1
- package/dist/web-components/viewer/overlayImage-BR3eJCKq.mjs +0 -1
- package/dist/web-components/viewer/range-regions-By6L5JOK.mjs +0 -1
- package/dist/web-components/viewer/styles-NZLnZPAC.mjs +0 -1
- package/dist/web-components/viewer/viewer-D30YHqyF.mjs +0 -29
- package/dist/web-components/viewer-CH7re5OO.mjs +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as p,e as O,b as M,
|
|
1
|
+
import{a as p,e as O,b as M,V as $,u as t,l,t as y}from"./shared-DkY2a89G.mjs";import{t as C}from"./heading-Cjt0f-Eu.mjs";import"./styles-DkkVOSUQ.mjs";function T({manifest:o,headingLevel:u,onOpened:d}){const{t:s,langOf:i}=p(),{clover:b,language:f}=O("About"),n=M(),c=[].concat(o.partOf??[]).filter(e=>(e==null?void 0:e.id)&&(!e.type||e.type==="Manifest"));if(!$(o)||!c.length)return null;const v=o.items[0].id,{as:g,title:h,group:m}=C(u,`${n}-title`);return t("section",{className:"clover-about-section",...m,children:[t(g,{className:"clover-about-heading",...l(i("aboutPartOf")),...h,children:s("aboutPartOf")}),t("ul",{className:"clover-about-part-of",children:c.map((e,r)=>{const a=y(e.label,f);return t("li",{children:[a.text&&t("span",{id:`${n}-${r}`,...l(a.lang),children:a.text}),t("button",{type:"button",className:"clover-about-open",...l(i("aboutOpenManifest")),"aria-describedby":a.text?`${n}-${r}`:void 0,onClick:()=>void b.goToManifest(e.id,v).then(d),children:s("aboutOpenManifest")})]},e.id)})})]})}export{T as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{u as a}from"./shared-
|
|
1
|
+
import{u as a}from"./shared-DkY2a89G.mjs";import{L as s}from"./Loading-YxuKrDAM.mjs";import"./styles-DkkVOSUQ.mjs";function i({children:r}){return r?a("div",{className:"clover-canvas","data-status":"error",children:r}):a("div",{className:"clover-canvas","data-status":"loading","aria-busy":"true",children:a(s,{overlay:true})})}export{i as C};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as p,ac as d,t as f,u as a,l as u,v}from"./shared-DkY2a89G.mjs";import{C as g}from"./glyphs-BFK_hvJJ.mjs";import{GivenMap as x}from"./MapView-3OxoCr5l.mjs";import{B as y}from"./Button-L8ZMy5lY.mjs";function k({id:e,open:o,onClose:s,feature:r,name:c,language:n}){const{t:i,langOf:m}=p();d(o,()=>s(false));const l=f(c,n);return a("div",{className:"clover-canvas-caption clover-canvas-place","data-open":o,"data-testid":"clover-canvas-place",id:e,role:"group","aria-labelledby":l.text?`${e}-name`:void 0,onKeyDown:t=>{t.key==="Escape"&&(t.preventDefault(),t.stopPropagation(),s(true))},children:[a(y,{className:"clover-canvas-caption-close",id:`close-${e}`,label:i("commonClose"),lang:m("commonClose"),onClick:()=>s(true),children:a(g,{})}),l.text&&a("p",{id:`${e}-name`,style:v,...u(l.lang),children:l.text}),o&&a(x,{navPlace:r,forwardedRef:null,landmark:false,list:false,language:n})]})}export{k as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as v,u as t,k as h,l as f,d as g,y}from"./shared-DkY2a89G.mjs";import{c as C,O as S,d as k}from"./glyphs-BFK_hvJJ.mjs";import{B as w}from"./Button-L8ZMy5lY.mjs";import{S as P}from"./layout-Djwu8f4R.mjs";import"./styles-DkkVOSUQ.mjs";function b(e,l){const[a,o]=g(e.src),s=e.src??e.service??e.fallback;return y(()=>{if(e.src)return o(e.src);let d=true;return import("./thumbnail-DecrVnpj.mjs").then(({resolveThumbnail:c})=>c(e,P,l)).then(c=>d&&o(c)),()=>{d=false}},[s]),a}function E({still:e,request:l,style:a}){const o=b(e.source,l);return o?t("img",{alt:e.alt,...f(e.alt?e.lang:void 0),src:o,style:a}):t("span",{style:a})}function O({instance:e,media:l,active:a,onToggle:o,more:s=false}){const{t:d,langOf:c}=v(),p=`placeholder-${e}`,m=l?"playerPlay":s?a?"canvasExpandControls":"canvasCollapseControls":a?"imageViewerOpen":"imageViewerClose";return t(w,{className:"clover-canvas-placeholder-toggle",id:p,label:d(m),lang:c(m),onClick:i=>{const u=document.activeElement===i.currentTarget,r=i.currentTarget.closest(".clover-canvas");o(),u&&requestAnimationFrame(()=>{var n;return(n=document.getElementById(p)??(r==null?void 0:r.querySelector('.clover-canvas-transport :is([data-button="pause"], [data-button="play"])'))??(r==null?void 0:r.querySelector(".clover-canvas-viewport")))==null?void 0:n.focus()})},children:l?t(C,{}):a?t(S,{}):t(k,{})})}const N=({instance:e,stills:l,vertical:a,media:o,active:s,lingering:d,onToggle:c,request:p})=>{const m=l.map(({width:r,height:n})=>a?n/r:r/n),i=m.reduce((r,n)=>r+n,0),u=a?1/i:i;return t(h,{children:[o&&s&&t(O,{instance:e,media:true,active:true,onToggle:c}),(s||d)&&t("div",{"aria-hidden":s?void 0:true,className:"clover-canvas-placeholder","data-lingering":!s,"data-media":o,"data-testid":"clover-canvas-placeholder","data-vertical":a,onClick:s?c:void 0,children:t("div",{className:"clover-canvas-placeholder-frame",style:{"--ratio":u},children:l.map((r,n)=>t(E,{still:r,request:p,style:{[a?"height":"width"]:`${m[n]/i*100}%`}},n))})})]})};export{O as PlaceholderToggle,N as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{D as f,u as a,e as v,c as d,a as h,l as x,v as P,
|
|
1
|
+
import{D as f,u as a,e as v,c as d,a as h,l as x,v as P,ae as T}from"./shared-DkY2a89G.mjs";import{i as C}from"./items-BnEnc5ot.mjs";import{j as I}from"./classnames-DukgfdpI.mjs";import{c as N,d as S}from"./hooks-BhtNDs_1.mjs";import"./styles-DkkVOSUQ.mjs";function b(c,i){const{clover:e}=v(i),n=N(),{direction:s}=S(),p=d(t=>t.collection),u=d(t=>{var o;return((o=t.manifest)==null?void 0:o.id)??null}),l=d(t=>{var o;return((o=t.targets)==null?void 0:o.items.length)??0}),r=d(t=>T(t.targets,t.targetIndex,t.manifest,t.canvasId));if(c==="targets")return{position:r,total:l,direction:"left-to-right",step:t=>{const o=r+t;o>=0&&o<l&&e.goToTarget(o)}};if(c==="members"){const t=C(p),o=t.findIndex(g=>g.id===u);return{position:o,total:t.length,direction:"left-to-right",step:g=>{const m=t[o+g];m&&e.goToManifest(m.id)}}}return{position:n.position,total:n.total,direction:s,step:t=>t<0?n.previous():n.next()}}const j=f(function({steps:i,as:e="span",className:n,...s},p){const{t:u,langOf:l}=h(),{position:r,total:t}=i;if(t<2||r<0)return null;const o=r+1;return a(e,{ref:p,className:I("clover-pager-position",n),...s,children:[a("span",{"aria-hidden":"true",children:[o," / ",t]}),a("span",{className:"clover-pager-room","aria-hidden":"true",hidden:true,children:[t," / ",t]}),a("span",{style:P,...x(l("canvasPosition")),children:u("canvasPosition",{index:o,total:t})})]})}),H=f(function({of:i="views",...e},n){const s=b(i,"Position");return a(j,{ref:n,...e,steps:s})});export{H as Position,j as PositionText,b as useRootSteps};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{u as s,
|
|
1
|
+
import{u as s,O as k,t as y,W as x,d as A,y as T,l as S,S as j,X as C}from"./shared-DkY2a89G.mjs";import{thumbnailSource as _,resolveThumbnail as w}from"./thumbnail-DecrVnpj.mjs";import{t as O}from"./text-BTAkxEfQ.mjs";import{j as c}from"./classnames-DukgfdpI.mjs";import{M as R,a as q}from"./Markup-DW75Jx3j.mjs";import{R as H}from"./ReadMore-De_0T7lc.mjs";import{u as I,r as L}from"./resource-Cfydiy4m.mjs";function u(t,a,r){const l=I(),n=x(i=>{var o;return(o=L(i,t))==null?void 0:o[a]},void 0);return r!==void 0?r:l?l[a]:n}const f=()=>{var t;return(t=k())==null?void 0:t.language};function F({of:t="manifest",as:a="p",value:r,className:l,...n}){const i=u(t,"summary",r),o=f();return y(i,o).text?s(H,{children:s(R,{as:a,markup:i,language:o,className:c("clover-summary",l),...n})}):null}function G({value:t,format:a,headingLevel:r,as:l="span",className:n,...i}){const o=f();return s(R,{as:l,markup:t,format:a,headingLevel:r,language:o,className:c("clover-value",n),...i})}function J({of:t="manifest",value:a,className:r,renderValue:l,...n}){const i=u(t,"metadata",a),o=f();return s(q,{metadata:i,language:o,renderValue:l,className:c("clover-metadata",r),...n})}function K({of:t="manifest",value:a,className:r,...l}){const n=u(t,"requiredStatement",a),i=f();return s(q,{metadata:n?[n]:null,language:i,className:c("clover-required-statement",r),...l})}function Q({of:t="manifest",value:a,className:r,...l}){const n=u(t,"rights",a);return n?s("a",{href:n,className:c("clover-rights",r),...l,children:n}):null}function U({of:t="manifest",value:a,className:r,...l}){const n=u(t,"id",a);return n?s("a",{href:n,target:"_blank",rel:"noopener noreferrer",className:c("clover-id",r),...l,children:n}):null}function p({property:t,className:a,of:r="manifest",value:l,...n}){const i=j(u(r,t,l)),o=f(),d=i.filter(e=>e==null?void 0:e.id);return d.length?s("ul",{className:a,...n,children:d.map(e=>{const m=y(e.label,o);return s("li",{children:[s("a",{href:e.id,target:"_blank",rel:"noopener noreferrer",hrefLang:C(e),...S(m.text?m.lang:void 0),children:m.text?O(m.text):e.id}),e.format&&s("span",{className:"clover-link-format",children:[" (",e.format,")"]})]},e.id)})}):null}const Y=({className:t,...a})=>s(p,{property:"homepage",className:c("clover-homepage",t),...a}),Z=({className:t,...a})=>s(p,{property:"rendering",className:c("clover-rendering",t),...a}),$=({className:t,...a})=>s(p,{property:"seeAlso",className:c("clover-see-also",t),...a}),tt=({className:t,...a})=>s(p,{property:"partOf",className:c("clover-part-of",t),...a});function et({of:t="manifest",value:a,size:r=400,className:l,...n}){var b;const i=x(g=>L(g,t),null),o=a??i,d=f(),e=o?_(o):null,m=(e==null?void 0:e.src)??(e==null?void 0:e.service)??(e==null?void 0:e.fallback),[N,v]=A(e==null?void 0:e.src),M=(b=k())==null?void 0:b.clover.request;if(T(()=>{if(!e)return v(void 0);if(e.src)return v(e.src);let g=true;return w(e,r,M).then(P=>g&&v(P)),()=>{g=false}},[m,r]),!N)return null;const h=y(o==null?void 0:o.label,d);return s("img",{src:N,alt:O(h.text),...S(n.alt===void 0&&h.text?h.lang:void 0),width:r,loading:"lazy",decoding:"async",className:c("clover-thumbnail",l),...n})}export{Y as Homepage,U as Id,J as Metadata,tt as PartOf,Z as Rendering,K as RequiredStatement,Q as Rights,$ as SeeAlso,F as Summary,et as Thumbnail,G as Value};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as k,W as x,O as P,S as v,u as l,l as B,k as O,t as w,x as I,Q as S,d as N,q as y,y as q,_ as z,X as R,A as T}from"./shared-DkY2a89G.mjs";import{t as W}from"./text-BTAkxEfQ.mjs";import{j}from"./classnames-DukgfdpI.mjs";import{L as _}from"./Label-f07N5Fld.mjs";import{u as $,r as A,P as F}from"./resource-Cfydiy4m.mjs";import"./styles-DkkVOSUQ.mjs";const M=typeof window>"u"?q:z,C=S(null),Q=o=>{var e;return!!((e=o.textContent)!=null&&e.trim())||o.querySelector("img, svg, picture, video, canvas, object")!==null},X=o=>!!o&&typeof o=="object"&&["label","logo","homepage"].some(e=>v(o[e]).length>0),L=o=>!!o&&typeof o.id=="string",D=o=>{const e=v(o.homepage).find(L);return e?{id:e.id,hrefLang:R(e)}:void 0},G=(o,e)=>{var s;if(!o)return null;for(const n of[o.label,(s=v(o.homepage).find(t=>t==null?void 0:t.label))==null?void 0:s.label]){const t=w(n,e);if(t.text)return{text:W(t.text),lang:t.lang}}return null};function eo({of:o="manifest",value:e,link:s=true,children:n,className:t,...d}){var f;const c=x(u=>{var p;return(p=A(u,o))==null?void 0:p.provider},void 0),g=(f=P())==null?void 0:f.language,r=v(e!==void 0?e:c).filter(X);return r.length?l("ul",{className:j("clover-provider",t),...d,children:r.map((u,p)=>{const m=s?D(u):void 0,i=!!w(u.label,g).text;return l(H,{agent:u,homepage:m,children:n??l(O,{children:[l(J,{alt:i?"":void 0}),l(_,{className:"clover-provider-label"})]})},u.id??p)})}):null}function H({agent:o,homepage:e,children:s}){const n=T(null),[t,d]=N(null),c=y(()=>{n.current&&!Q(n.current)&&d(o)},[o]);return t===o?null:l("li",{className:"clover-provider-agent",children:l(F.Provider,{value:o,children:l(C.Provider,{value:c,children:e?l("a",{ref:n,href:e.id,target:"_blank",rel:"noopener noreferrer",hrefLang:e.hrefLang,className:"clover-provider-link",children:s}):l("span",{ref:n,className:"clover-provider-content",children:s})})})})}function J({of:o="manifest",value:e,alt:s,className:n,...t}){var m;const{t:d,langOf:c}=k(),g=$(),r=x(i=>{var a;return(a=A(i,o))==null?void 0:a.provider},void 0),f=(m=P())==null?void 0:m.language,p=(e!==void 0?v(e):g?[g]:v(r)).flatMap(i=>{if(!i||typeof i!="object")return[];const a=i;if(a.type!=="Agent"&&L(a)&&!a.logo)return[{image:a,agent:null}];const b=v(a.logo).find(L);return b?[{image:b,agent:a}]:[]});return p.length?l(O,{children:p.map(({image:i,agent:a},b)=>{const h=G(a,f);return l(K,{src:i.id,alt:s??(h==null?void 0:h.text)??d("logo"),...B(s!==void 0?void 0:h?h.lang:c("logo")),width:i.width,height:i.height,loading:"lazy",decoding:"async",className:j("clover-logo",n),...t},`${i.id}-${b}`)})}):null}function K({alt:o,onError:e,...s}){const n=I(C),[t,d]=N(false),c=y(()=>d(true),[]);M(()=>{t&&(n==null||n())},[t,n]);const g=y(r=>{var f;r!=null&&r.complete&&!r.naturalWidth&&((f=r.decode)==null||f.call(r).catch(c))},[c]);return t?null:l("img",{ref:g,alt:o,onError:r=>{e==null||e(r),c()},...s})}export{J as L,eo as P};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as p,y as h,_ as R,a as L,
|
|
1
|
+
import{d as p,y as h,_ as R,a as L,a2 as M,A as O,b as w,R as v,u as g,l as E}from"./shared-DkY2a89G.mjs";const F=typeof window>"u"?h:R;function I({children:s}){const{t:r}=L(),u=M(),i=O(null),m=w(),c=v.Children.only(s),e=c.props.id??m,{open:t,cut:a,toggle:o}=A(i);return g("div",{className:"clover-read-more",children:[v.cloneElement(c,{ref:i,id:e,"data-read-more":t?"open":""}),(a||t)&&g("button",{type:"button",className:"clover-read-more-button","aria-expanded":t,"aria-controls":e,onClick:o,ref:u.ref,...E(u.langOf(t?"readLess":"readMore")),children:r(t?"readLess":"readMore")})]})}function A(s){const[r,u]=p(false),[i,m]=p(false),c=()=>{const e=s.current;e&&!r&&m(e.scrollHeight>e.clientHeight+1)};return F(c),h(()=>{var l,f;const e=s.current;if(!e)return;let t=0;const a=()=>{cancelAnimationFrame(t),t=requestAnimationFrame(c)},o=typeof ResizeObserver>"u"?null:new ResizeObserver(a);o==null||o.observe(e);const n=typeof MutationObserver>"u"?null:new MutationObserver(a);return n==null||n.observe(document.head,{childList:true,subtree:true,characterData:true}),n==null||n.observe(document.documentElement,{attributes:true,attributeFilter:["style","class"]}),n==null||n.observe(e,{attributes:true,attributeFilter:["style"]}),(f=(l=document.fonts)==null?void 0:l.addEventListener)==null||f.call(l,"loadingdone",a),()=>{var d,b;cancelAnimationFrame(t),o==null||o.disconnect(),n==null||n.disconnect(),(b=(d=document.fonts)==null?void 0:d.removeEventListener)==null||b.call(d,"loadingdone",a)}},[r,s.current]),{open:r,cut:i,toggle:()=>u(e=>!e)}}export{I as R,A as u};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{D as v,aj as h,a2 as d,u as o,a6 as m,ak as f,al as p}from"./shared-DkY2a89G.mjs";import{u as C,h as R}from"./useNearViewport-CDbHQUBk.mjs";import{j as x}from"./classnames-DukgfdpI.mjs";const k=v(function({as:r="div",className:s,children:n,highContrast:u,...c},l){const[a,g,t]=h(c),e=d(l,t.lang),i=C(u);return o(p.Provider,{value:a,children:o(m.Provider,{value:e.hostLanguage,children:o(r,{ref:e.ref,className:x("clover-root",s),"data-status":g,...R(i),...t,children:[n,o(f,{clover:a.clover,language:a.language})]})})})});export{k as R};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{O as r,u as e,z as o,P as t}from"./shared-DkY2a89G.mjs";import{S as a}from"./SceneView-DA7Yg20p.mjs";import{C as i}from"./Pending-BxGjjnqq.mjs";const l=o(()=>import("./Connected-CBQ6xyhr.mjs")),f=o(()=>import("./Loaded-oGFyBuos.mjs"));function s(n){const c=r();return n.iiifContent!==void 0&&n.scene===void 0?e(t,{fallback:e(i,{}),children:e(f,{...n})}):n.scene?e(a,{...n}):c?e(t,{fallback:e(i,{}),children:e(l,{...n})}):null}export{s as Scene,s as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{u as r,A as m,y as F,R as ze,a as Ve,a4 as We,a7 as Ge,d as ee,a2 as Xe,b as Je,au as Qe,q as z,T as et,t as Se,l as tt,v as rt,a6 as ot}from"./shared-DkY2a89G.mjs";import{i as nt,T as at,r as he,E as ct,k as st,l as it,u as lt,d as ut,m as dt,n as vt,h as ft,o as pt,C as ht,B as gt,q as mt,Z as bt,e as wt,t as yt,f as xt,g as kt}from"./pointer-YQppt0at.mjs";import{s as Ot,a as Lt,h as Ct,t as Rt,z as It,b as St}from"./models-BF2pqufA.mjs";import{B as Mt}from"./BodyAlert-C_Qh3Up_.mjs";import{I as At}from"./glyphs-BFK_hvJJ.mjs";import{u as Et}from"./useControlsVisibility-DPg8uAkW.mjs";import{u as Ft,a as Pt,h as zt}from"./useNearViewport-CDbHQUBk.mjs";import{j as Tt}from"./classnames-DukgfdpI.mjs";import{c as Dt,r as Nt}from"./contexts-ByL3eA_T.mjs";import{B as $t}from"./Button-L8ZMy5lY.mjs";import{L as Kt}from"./Loading-YxuKrDAM.mjs";import{S as A,f as Bt}from"./Tip-OCB88zwY.mjs";import{u as Me}from"./useContainerName-hKQjEt7a.mjs";import{e as qt}from"./engines-BmB81VXR.mjs";import"./styles-DkkVOSUQ.mjs";import{a as Ht}from"./index-FJEpXukG.mjs";const Ae=2*Math.PI,Ut=.01,Zt=t=>t.deltaMode===1?t.deltaY*16:t.deltaMode===2?t.deltaY*400:t.deltaY;function Te(t,u,d=()=>t.clientHeight){const a=new Map;let v=0,f=false,l={x:0,y:0};const p=()=>{const[o,g]=[...a.values()];return o&&g?Math.hypot(o.x-g.x,o.y-g.y):0},b=o=>{if(!(o.pointerType==="mouse"&&o.button!==0)&&!nt(o.target,t)){a.set(o.pointerId,{x:o.clientX,y:o.clientY});try{t.setPointerCapture(o.pointerId)}catch{}a.size===1&&(f=false,l={x:o.clientX,y:o.clientY}),a.size===2&&(v=p())}},L=o=>{const g=a.get(o.pointerId);if(!g)return;const y={x:o.clientX,y:o.clientY};if(a.set(o.pointerId,y),a.size===2){const s=p();v>0&&s>0&&u.zoom(s/v),v=s;return}if(!f){if(Math.hypot(y.x-l.x,y.y-l.y)<at)return;f=true}const E=d()||1;u.turn(-(y.x-g.x)/E*Ae,-(y.y-g.y)/E*Ae)},C=o=>{a.delete(o.pointerId),v=a.size===2?p():0},R=o=>{o.ctrlKey&&(o.preventDefault(),u.zoom(Math.exp(-Zt(o)*Ut)))};return t.addEventListener("pointerdown",b),t.addEventListener("pointermove",L),t.addEventListener("pointerup",C),t.addEventListener("pointercancel",C),t.addEventListener("wheel",R,{passive:false}),()=>{t.removeEventListener("pointerdown",b),t.removeEventListener("pointermove",L),t.removeEventListener("pointerup",C),t.removeEventListener("pointercancel",C),t.removeEventListener("wheel",R)}}const Ee={rotateUp:{place:"up",rate:[0,Math.PI/6]},rotateLeft:{place:"left",rate:[Math.PI/2,0]},rotateRight:{place:"right",rate:[-Math.PI/2,0]},rotateDown:{place:"down",rate:[0,-Math.PI/6]}},_t=400,te=({rotate:t})=>r("path",{fill:"none",strokeWidth:"64",strokeLinecap:"round",strokeLinejoin:"round",d:"M192 96l160 160-160 160",transform:`rotate(${t} 256 256)`}),q=236,Y=t=>t.toFixed(1);function re(t,u,d,a){const[v,f]=d?[`256 ${Y(256-u)}`,`256 ${Y(256+u)}`]:[`${Y(256-t)} 256`,`${Y(256+t)} 256`];return`M${v}A${Y(t)} ${Y(u)} 0 0 ${a} ${f}`}function De({theta:t,phi:u}){const d=Math.PI/2-u,a=Math.max(1,q*Math.abs(Math.sin(d))),v=Math.max(1,q*Math.abs(Math.sin(t))),f=d>=0,l=Math.sin(2*t)<0;return{equator:{front:re(q,a,false,f?0:1),back:re(q,a,false,f?1:0)},meridian:{front:re(v,q,true,l?1:0),back:re(v,q,true,l?0:1)},x:256-q*Math.sin(t),y:256+(f?1:-1)*a*Math.cos(t),facing:Math.cos(t)>0}}function Fe(t,u){const[d,a,v,f,l]=(t==null?void 0:t.children)??[];if(!l)return;const{equator:p,meridian:b,x:L,y:C,facing:R}=De(u);d.setAttribute("d",p.front),a.setAttribute("d",p.back),v.setAttribute("d",b.front),f.setAttribute("d",b.back),l.setAttribute("cx",L.toFixed(1)),l.setAttribute("cy",C.toFixed(1)),l.setAttribute("fill",R?"currentColor":"none"),l.setAttribute("opacity",R?"1":String(ge))}const ge=.3,Yt=ze.forwardRef(function(u,d){const a=De({theta:0,phi:75*Math.PI/180});return r("g",{ref:d,fill:"none",strokeWidth:"14",strokeLinecap:"round",children:[r("path",{d:a.equator.front}),r("path",{d:a.equator.back,strokeOpacity:ge}),r("path",{d:a.meridian.front}),r("path",{d:a.meridian.back,strokeOpacity:ge}),r("circle",{cx:a.x.toFixed(1),cy:a.y.toFixed(1),r:"34",fill:"currentColor"})]})});function jt({controls:t,controlButtons:u,turn:d,zoom:a,span:v,indicator:f,name:l}){const p=m(null),b=m(false),L=m(d);L.current=d;const C=m(a);C.current=a;const R=m(null),o=!!(t.rotateUp||t.rotateLeft||t.rotateRight||t.rotateDown);F(()=>{const s=R.current;if(s)return Te(s,{turn:(w,i)=>L.current(w,i),zoom:w=>C.current(w)},v)},[v,o]);const g=s=>{const w=p.current;w&&(window.clearTimeout(w.timer),cancelAnimationFrame(w.frame),p.current=null,w.held&&s&&(b.current=true))};F(()=>()=>g(false),[]);const y=(s,w)=>{if(s.button>0)return;g(false),b.current=false;const[i,ae]=Ee[w].rate,P={timer:0,frame:0,held:false};P.timer=window.setTimeout(()=>{P.held=true;let W=performance.now();const G=H=>{const ce=Math.min(.1,Math.max(0,H-W)/1e3);W=H,L.current(i*ce,ae*ce),P.frame=requestAnimationFrame(G)};P.frame=requestAnimationFrame(G)},_t),p.current=P},E=s=>{const w=t[s];return w?r("span",{className:"clover-scene-rotate-cell","data-place":Ee[s].place,onPointerDown:i=>y(i,s),onPointerUp:()=>g(true),onPointerLeave:()=>g(false),onPointerCancel:()=>g(false),onKeyDown:i=>{i.repeat&&i.key==="Enter"&&i.preventDefault()},onClickCapture:i=>{b.current&&i.detail>0&&(i.stopPropagation(),i.preventDefault()),b.current=false},children:he(w,u)},s):null};return r("div",{className:"clover-scene-rotate",role:"group",...l.props,"data-testid":"clover-scene-rotate",children:[l.node,o&&r("span",{ref:R,className:"clover-scene-rotate-disc","aria-hidden":"true","data-testid":"clover-scene-rotate-disc",children:r("svg",{viewBox:"0 0 512 512",width:"16",height:"16",focusable:"false",children:r(Yt,{ref:f})})}),E("rotateUp"),E("rotateLeft"),E("rotateRight"),E("rotateDown"),t.reset&&r("span",{className:"clover-scene-rotate-cell","data-place":"corner",children:he(t.reset,u)})]})}Ht(16,"components/Scene/Scene",'@layer clover{.clover-scene>.clover-scene-navigation{position:absolute;right:var(--clover-canvas-controls-inset);bottom:var(--clover-canvas-controls-inset);z-index:3;display:flex;align-items:flex-end;pointer-events:none;touch-action:none;-webkit-touch-callout:none;user-select:none;-webkit-user-select:none;opacity:var(--clover-controls-shown);translate:0 calc((1 - var(--clover-controls-shown)) * var(--clover-controls-tuck));transition:all var(--clover-controls-timing)}.clover-scene-navigation :is(button,.clover-scene-rotate-disc){pointer-events:var(--clover-controls-events)}.clover-scene:has(>.clover-scene-navigation :is(button,.clover-scene-rotate-disc):hover){--clover-controls-shown: 1;--clover-controls-events: auto;--clover-controls-timing: var(--clover-controls-enter)}.clover-scene:has(>.clover-scene-navigation)>.clover-canvas-viewport:before{position:absolute;inset:auto 0 0;height:calc(3 * var(--clover-control) + 2 * var(--clover-space-s) + 2 * var(--clover-canvas-controls-inset));background:linear-gradient(to top,#00000073,#0003 45%,#0000);opacity:var(--clover-controls-shown);transition:opacity var(--clover-controls-timing);pointer-events:none;content:""}.clover-scene>.clover-scene-navigation[data-compact]{--clover-control: max(1.5rem, 24px)}.clover-scene-tools{display:flex;gap:var(--clover-space-s);margin-inline-end:calc(-1 * var(--clover-control))}.clover-scene-rotate{position:relative;display:grid;grid-template-columns:repeat(3,var(--clover-control));grid-template-rows:repeat(3,var(--clover-control));gap:var(--clover-space-s);--clover-scene-rotate-rim: calc( .756 * var(--clover-control) + .874 * var(--clover-space-s) )}.clover-scene-rotate-disc{position:absolute;top:50%;left:50%;width:calc(2 * var(--clover-scene-rotate-rim));height:calc(2 * var(--clover-scene-rotate-rim));translate:-50% -50%;display:flex;align-items:center;justify-content:center;border-radius:50%;--clover-scene-ball: var(--clover-color-accent, #0065c3);background-color:var(--clover-scene-ball);background-image:radial-gradient(circle at 34% 30%,#ffffff24 0,#fff0 24%),radial-gradient(circle at 34% 30%,color-mix(in srgb,var(--clover-scene-ball) 84%,#fff) 0,var(--clover-scene-ball) 48%,color-mix(in srgb,var(--clover-scene-ball) 62%,#000) 100%);box-shadow:0 .236rem .618rem #00000038;color:var(--clover-color-control-glyph, #fff);cursor:grab;isolation:isolate;transition:scale .2s ease}:where([data-high-contrast]) .clover-scene-rotate-disc{--clover-scene-ball: var(--clover-accent-fill);transition:none}:where([data-high-contrast]) .clover-scene-rotate-disc:hover{outline:var(--clover-accent-ring-hover);outline-offset:1px}:where([data-high-contrast]) .clover-scene-rotate-disc:active{outline:var(--clover-accent-ring);outline-offset:1px}.clover-scene-rotate-disc:active{cursor:grabbing}.clover-scene-rotate-disc:before{position:absolute;inset:0;z-index:-1;border-radius:inherit;background:color-mix(in srgb,#fff 16%,transparent);opacity:0;transition:opacity .2s ease;content:""}.clover-scene-rotate-disc:is(:hover,:active):before,.clover-scene-rotate:has(:focus-visible) .clover-scene-rotate-disc:before,.clover-scene-navigation[data-turning] .clover-scene-rotate-disc:before{opacity:1}.clover-scene-rotate-disc:is(:hover,:active),.clover-scene-rotate:has(:focus-visible) .clover-scene-rotate-disc,.clover-scene-navigation[data-turning] .clover-scene-rotate-disc{scale:1.06}@media (prefers-reduced-motion: reduce){.clover-scene-rotate-disc{transition:none}}@media (forced-colors: active){.clover-scene-rotate-disc{border:1px solid CanvasText}}.clover-scene-rotate-disc svg{width:100%;height:100%;fill:currentColor;stroke:currentColor;-webkit-mask-image:radial-gradient(circle closest-side,#000 45%,transparent 90%);mask-image:radial-gradient(circle closest-side,#000 45%,transparent 90%)}.clover-scene-rotate-cell{position:relative;z-index:1;display:flex}.clover-scene-rotate-cell[data-place=up]{grid-area:1 / 2}.clover-scene-rotate-cell[data-place=left]{grid-area:2 / 1}.clover-scene-rotate-cell[data-place=corner]{grid-area:3 / 3}.clover-scene-rotate-cell[data-place=right]{grid-area:2 / 3}.clover-scene-rotate-cell[data-place=down]{grid-area:3 / 2}.clover-scene .clover-scene-navigation .clover-scene-rotate-cell:not([data-place=corner]) button.clover-canvas-button svg{scale:none;rotate:none}.clover-scene>.clover-scene-error{position:absolute;inset:auto var(--clover-canvas-controls-inset) var(--clover-canvas-controls-inset);z-index:2;background-color:var(--clover-color-secondary, #fff);border-radius:var(--clover-radius, 3px)}}');const Pe={zoom:true,fullPage:true,rotation:true,reset:true,information:true},j=Math.PI/4,oe=Math.PI/12,Vt=j/2,ne=1.5,Wt=["ArrowLeft ArrowRight ArrowUp ArrowDown",A.rotateRight.keys,A.rotateLeft.keys,A.zoomIn.keys,A.zoomOut.keys,A.reset.keys].join(" ");function fr(t){return t.scene?r(ct,{children:r(Gt,{...t,scene:t.scene})}):null}function Gt({scene:t,label:u,language:d,highContrast:a,className:v,controls:f=true,controlButtons:l,options:p,manifestId:b,engine:L="clover",onContentStateChange:C,children:R}){const{t:o}=Ve(),g=We(()=>b==="loading"?null:Ge({manifestId:b,canvasId:t.id,type:"Scene"}),C);F(()=>g(),[t.id,b,g]);const[y,E]=ee(null),s=Xe(E),w=Ft(a),i=m(null),ae=st(y),P=it(y),W=lt(),G=Et(y,p==null?void 0:p.hideDelay,i),H=Pt(y),T=`clover-scene-${Je()}`,k=f===false?null:f===true?Pe:{...Pe,...f},me=Ot(t),be=Lt(t),we=p==null?void 0:p.request,ye=JSON.stringify([t.id,me,Qe(we),L]),xe=b==="loading",[I,D]=ee({state:"waiting"}),N=m(null),se=m(null),M=m(null),h=m(null),$=m(0),[Ne,$e]=ee(0),X=m({hiddenSince:null,release:()=>{}}),J=m(false),ie=m(null),le=m(null),Ke=ut(y),U=z(()=>{$.current||!N.current||($.current=requestAnimationFrame(()=>{var e;$.current=0,h.current&&((e=N.current)==null||e.draw(h.current),Fe(le.current,h.current))}))},[]),Z=z(()=>{const e=i.current,n=e&&e.clientHeight?e.clientWidth/e.clientHeight:1;return se.current?Ct(se.current,n):null},[]),Q=z(e=>{!h.current||!M.current||(h.current=e(h.current,M.current),U())},[U]),ue=m(0),x=z((e,n)=>{Q(O=>Rt(O,e,n));const c=ie.current;c&&(c.setAttribute("data-turning",""),window.clearTimeout(ue.current),ue.current=window.setTimeout(()=>c.removeAttribute("data-turning"),400))},[Q]);F(()=>()=>window.clearTimeout(ue.current),[]);const K=z(e=>Q((n,c)=>It(n,e,c)),[Q]),Be=z(()=>{var e;return((e=i.current)==null?void 0:e.clientHeight)??0},[]),ke=z(()=>{M.current=Z(),h.current=M.current,U()},[Z,U]);F(()=>{const e=i.current;if(!e||!H)return;if(xe){D({state:"loading"});return}let n=true,c=null;const O=()=>{cancelAnimationFrame($.current),$.current=0,c==null||c.dispose(),c=null,N.current=null,Nt(X.current)};return X.current.release=()=>{O(),J.current=true,n&&D({state:"waiting"})},J.current=false,Dt(X.current)?(D({state:"loading"}),qt(L)().then(({createEngine:S})=>{if(n)return c=S(e,{onLost:()=>{O(),n&&D({state:"error",error:new Error("The browser took back the 3D view's graphics.")})}}),N.current=c,c.load(me,we).then(je=>{n&&(se.current=je,M.current=Z(),h.current??(h.current=M.current),D({state:"ready"}),U())})}).catch(S=>{n&&(O(),D({state:"error",error:S instanceof Error?S:new Error(String(S)),load:true}))}),()=>{n=false,O()}):(J.current=true,D({state:"waiting"}),()=>{n=false})},[ye,xe,H,Ne,Z,U]),F(()=>{h.current=null},[ye]),F(()=>{const e=i.current;if(!e||typeof IntersectionObserver>"u")return;const n=new IntersectionObserver(([c])=>{X.current.hiddenSince=c!=null&&c.isIntersecting?null:performance.now(),c!=null&&c.isIntersecting&&J.current&&$e(O=>O+1)});return n.observe(e),()=>n.disconnect()},[]),F(()=>{const e=i.current;if(!e||typeof ResizeObserver>"u")return;const n=new ResizeObserver(()=>{var S;const c=parseFloat(getComputedStyle(document.documentElement).fontSize)||16;if((S=ie.current)==null||S.toggleAttribute("data-compact",e.clientWidth<32*c||e.clientHeight<24*c),!N.current)return;N.current.resize();const O=h.current&&M.current&&St(h.current,M.current);M.current=Z(),O&&(h.current=M.current),cancelAnimationFrame($.current),$.current=0,h.current&&(N.current.draw(h.current),Fe(le.current,h.current))});return n.observe(e),()=>n.disconnect()},[Z]),F(()=>{const e=i.current;if(!(!e||I.state!=="ready"))return Te(e,{turn:x,zoom:K})},[I.state,x,K]);const qe=e=>{if(e.target!==e.currentTarget||e.altKey||e.metaKey||e.ctrlKey)return;const n=e.shiftKey?j:Vt,c=e.shiftKey?2*oe:oe;switch(e.key){case"ArrowLeft":x(n,0);break;case"ArrowRight":x(-n,0);break;case"ArrowUp":x(0,c);break;case"ArrowDown":x(0,-c);break;case"r":x(-j,0);break;case"R":x(j,0);break;case"+":case"=":K(ne);break;case"-":case"_":K(1/ne);break;case"0":ke();break;default:return}e.preventDefault()},de=`caption-${T}`,_=et(()=>k!=null&&k.information&&dt(t)?[t]:[],[k==null?void 0:k.information,t]),[He,Oe]=ee(false),ve=He&&_.length>0,Le=z(e=>{var n;Oe(false),e&&((n=document.getElementById(`information-${T}`))==null||n.focus())},[T]),Ue=_.length&&Se(t.label,d).text?vt(de,0):void 0,V=[u,t.label].map(e=>Se(e,d)).find(e=>e.text),Ce=Me((V==null?void 0:V.text)||o("sceneModel"),V?V.lang:s.langOf("sceneModel"),false,s.hostLanguage),Re=`keys-${T}`,Ze=s.langOf("sceneRoleDescription")?void 0:o("sceneRoleDescription"),B=(e,n,c,O,S)=>({key:e,id:`${e}-${T}`,label:o(n),lang:s.langOf(n),glyph:c,onClick:O,...S?{shortcut:S}:{}}),_e=e=>k?[...k.zoom?[B("zoomIn","imageZoomIn",r(bt,{}),()=>K(ne),A.zoomIn),B("zoomOut","imageZoomOut",r(wt,{}),()=>K(1/ne),A.zoomOut)]:[],...k.fullPage&&W?[{key:"fullPage",id:`fullPage-${T}`,label:o(e?"imageExitFullScreen":"imageFullScreen"),lang:s.langOf(e?"imageExitFullScreen":"imageFullScreen"),glyph:e?r(xt,{}):r(kt,{}),onClick:n=>void yt(n.currentTarget)}]:[]]:[],Ye=Me(o("sceneRotate"),s.langOf("sceneRotate"),false,s.hostLanguage),fe=k?{...k.rotation&&{rotateUp:B("rotateUp","sceneRotateUp",r(te,{rotate:-90}),()=>x(0,oe)),rotateLeft:B("rotateLeft","imageRotateLeft",r(te,{rotate:180}),()=>x(j,0),A.rotateLeft),rotateRight:B("rotateRight","imageRotateRight",r(te,{rotate:0}),()=>x(-j,0),A.rotateRight),rotateDown:B("rotateDown","sceneRotateDown",r(te,{rotate:90}),()=>x(0,-oe))},...k.reset&&{reset:B("reset","sceneResetView",r(ft,{}),ke,A.reset)}}:{},pe=_e(Ke),Ie=I.state==="loading"||I.state==="waiting"&&H;return r(ot.Provider,{value:s.hostLanguage,children:r("figure",{"aria-labelledby":Ue,className:Tt("clover-canvas","clover-scene",v),"data-testid":"clover-scene",...zt(w),"data-status":I.state==="ready"?"ready":I.state==="error"?"error":"loading","data-fullscreen":ae,"data-exit":P||void 0,"data-controls":G?"visible":"hidden","data-navigable":"true",ref:s.ref,onKeyDown:e=>{if(e.key==="Escape"&&ve&&!e.defaultPrevented){e.preventDefault(),Le(false);return}Bt(e,i.current)},style:{position:"relative",width:"100%",height:"100%",margin:0,overflow:"hidden",isolation:"isolate"},children:[r(pt,{hidden:!P}),(_.length>0||ze.Children.count(R)>0)&&r(ht,{children:[_.length>0&&r($t,{id:`information-${T}`,label:o("informationPanelTabsAbout"),lang:s.langOf("informationPanelTabsAbout"),onClick:()=>Oe(e=>!e),expanded:ve,controls:de,children:r(At,{})}),R]}),(pe.length>0||Object.keys(fe).length>0)&&r("div",{ref:ie,className:"clover-scene-navigation",children:[pe.length>0&&r("div",{className:"clover-scene-tools",children:pe.map(e=>he(e,l))}),Object.keys(fe).length>0&&r(jt,{controls:fe,controlButtons:l,turn:x,zoom:K,span:Be,indicator:le,name:Ye})]}),r("div",{ref:i,className:"clover-canvas-viewport",style:{position:"absolute",inset:0,overflow:"hidden",zIndex:-1,...be?{backgroundColor:be}:{}},"data-testid":"clover-scene-viewport",role:"img","aria-roledescription":Ze,...Ce.props,"aria-describedby":Re,"aria-keyshortcuts":Wt,"aria-busy":Ie,tabIndex:0,onKeyDown:qe}),Ce.node,r("span",{id:Re,style:rt,...tt(s.langOf("sceneKeys")),children:o("sceneKeys")}),r(gt,{kind:"model",shown:I.state==="error"&&!!I.load}),I.state==="error"&&!I.load&&r(Mt,{error:I.error,className:"clover-scene-error"}),Ie&&r(Kt,{overlay:true}),_.length>0&&r(mt,{id:de,canvases:_,open:ve,onClose:Le,language:d})]})})}export{fr as S};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{D as te,a as se,e as ne,c as p,
|
|
1
|
+
import{D as te,a as se,e as ne,c as p,M as re,F as ce,C as oe,b as ae,d as H,y as h,A as d,u as o,l as j,t as ie}from"./shared-DkY2a89G.mjs";import{j as le}from"./classnames-DukgfdpI.mjs";import{b as ue,s as he}from"./bringIntoView-CQH5ZgMM.mjs";import{a as de}from"./heading-Cjt0f-Eu.mjs";import{u as fe}from"./Sections-d1acn7qm.mjs";import{F as ve}from"./FieldPill-nFGsaru9.mjs";import"./styles-DkkVOSUQ.mjs";const O=40,xe=te(function({headingLevel:D=3,sticky:y=false,size:K="large",as:L="div",className:T,...U},k){const{t:B,langOf:V}=se(),{clover:r,language:G}=ne("Search"),b=p(e=>{var s;return((s=re(e.manifest))==null?void 0:s.id)??null}),t=p(e=>e.search),J=p(e=>ce(e.manifest).canvases),a=p(e=>e.annotationId),Q=oe(r.highlight.subscribe,r.highlight.get,r.highlight.get),I=ae(),[$,S]=H(t.query);h(()=>S(t.query),[t.query]);const l=d(null),v=fe(),P=d(0),q=d(false),R=d(null);h(()=>{if(t.status!=="ready"||!t.set||R.current===t.set)return;R.current=t.set;const e=t.hits[0],s=t.hits.some(n=>a&&n.entryIds.includes(a));e&&!s&&r.selectAnnotation(e.entryIds[0])},[r,t.status,t.set,t.hits,a]),h(()=>{var i;const e=(i=l.current)==null?void 0:i.closest(".clover-content-search-field"),s=e==null?void 0:e.parentElement;if(!y||!e||!s||typeof ResizeObserver>"u")return;const n=new ResizeObserver(()=>s.style.setProperty("--clover-content-search-field",`${e.offsetHeight}px`));return n.observe(e),()=>{n.disconnect(),s.style.removeProperty("--clover-content-search-field")}},[y,b]),h(()=>{var s,n;if(!q.current)return;q.current=false;const e=(n=(s=l.current)==null?void 0:s.closest(".clover-content-search"))==null?void 0:n.querySelector('.clover-content-search-hit[aria-current="true"]');e&&ue(e,"nearest")},[a]);const[M,W]=H({set:null,count:O}),w=M.set===t.set?M.count:O,x=()=>W({set:t.set,count:w+O}),z=d(null),A=a?t.hits.findIndex(e=>e.entryIds.includes(a)):-1,N=typeof IntersectionObserver<"u",u=N?Math.min(t.hits.length,Math.max(w,A+1)):t.hits.length,E=d(x);if(E.current=x,h(()=>{const e=z.current;if(!e||!N||u>=t.hits.length)return;const s=new IntersectionObserver(n=>{n.some(i=>i.isIntersecting)&&E.current()},{root:he(e),rootMargin:"0px 0px 400px 0px"});return s.observe(e),()=>s.disconnect()},[N,u,t.hits.length]),h(()=>{!v||v===P.current||!l.current||(P.current=v,l.current.focus())},[v,b]),!b)return null;const F={position:A,total:t.hits.length,step:e=>{const s=t.hits[F.position+e];s&&(q.current=true,r.selectAnnotation(s.entryIds[0]))}},g=[];t.hits.slice(0,u).forEach((e,s)=>{const n=g[g.length-1];(n==null?void 0:n.canvasId)===e.canvasId?n.hits.push({hit:e,index:s}):g.push({canvasId:e.canvasId,hits:[{hit:e,index:s}]})});const X=de(D),f=t.hits.length,m=t.status==="loading"?"contentSearchLoading":t.status==="error"?"contentSearchError":t.status==="ready"?f===0?"contentSearchResultsNone":f===1?"contentSearchResult":"contentSearchResults":null,Y=m?B(m,{count:f}):"",Z=t.status==="ready"?F:null,_=o("p",{className:"clover-content-search-status",role:"status","data-status":t.status,...j(m?V(m):void 0),children:Y});return o(L,{ref:k,className:le("clover-content-search",T),"data-status":t.status,"data-sticky":y||void 0,...U,children:[o("div",{className:"clover-content-search-field",children:o(ve,{ref:l,id:`${I}-query`,value:$,onChange:e=>{S(e),!e&&t.query&&r.search("")},onSubmit:()=>void r.search($),onClear:()=>{var e;S(""),t.query&&r.search(""),(e=l.current)==null||e.focus()},results:Z,size:K,classes:{form:"clover-content-search-form",query:"clover-content-search-query",clear:"clover-content-search-clear",submit:"clover-content-search-submit"}})}),_,g.map(({canvasId:e,hits:s},n)=>{const i=J.find(c=>c.id===e),C=ie(i==null?void 0:i.label,G);return o("section",{className:"clover-content-search-group","aria-labelledby":`${I}-${n}`,children:[o(X,{id:`${I}-${n}`,className:"clover-content-search-canvas",...j(C.text?C.lang:void 0),children:C.text||e}),o("ol",{className:"clover-content-search-hits",children:s.map(({hit:c,index:ee})=>o("li",{children:o("button",{type:"button",className:"clover-content-search-hit","aria-current":a&&c.entryIds.includes(a)?"true":void 0,"data-highlighted":c.entryIds.includes(Q??""),onClick:()=>r.selectAnnotation(c.entryIds[0]),onPointerEnter:()=>r.highlight.emit(c.entryIds[0]),onPointerLeave:()=>r.highlight.emit(null),onFocus:()=>{r.highlight.emit(c.entryIds[0]),u<f&&ee>=u-5&&x()},onBlur:()=>r.highlight.emit(null),children:[c.before,o("mark",{children:c.match}),c.after]})},c.id))})]},`${e}-${n}`)}),u<f&&o("div",{ref:z,className:"clover-content-search-more","aria-hidden":"true"})]})});export{xe as Search};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as ae,A as $,a as ie,d as G,y as z,_ as de,u as i,Q as J,l as ue,k as fe,x as Z}from"./shared-
|
|
2
|
-
`);V(()=>{const e=j.current;if(s||!e||typeof ResizeObserver>"u")return;const o=[...e.querySelectorAll(":scope > .clover-sections-item")],t=o.map(c=>c.firstElementChild),l=t[0],a=t[t.length-1],d=new Map,u=c=>(c&&d.get(c))??0,b=document.scrollingElement;let p=null,B=0;const P=()=>{const c=t.reduce((O,L)=>O+u(L),0);let C=0;o.forEach((O,L)=>{O.style.setProperty("--clover-sections-before",`${C}px`),C+=u(t[L]),O.style.setProperty("--clover-sections-after",`${c-C}px`)}),e.style.setProperty("--clover-sections-total",`${c}px`);const w=l&&getComputedStyle(l);(w==null?void 0:w.position)==="sticky"&&a&&(B=parseFloat(w.top)+parseFloat(getComputedStyle(a).bottom)||0);const x=getComputedStyle(e),ce=parseFloat(x.lineHeight)||1.2*parseFloat(x.fontSize),X=(p==null?void 0:p.clientHeight)??0;X>0&&X-B-c<2*ce?e.dataset.stacks="off":delete e.dataset.stacks},y=new ResizeObserver(c=>{var C,w;for(const x of c)t.includes(x.target)&&d.set(x.target,((w=(C=x.borderBoxSize)==null?void 0:C[0])==null?void 0:w.blockSize)??x.target.getBoundingClientRect().height);P()}),N=()=>{const c=M(e);c!==p&&(p&&p!==b&&y.unobserve(p),c&&c!==b&&y.observe(c),p=c)},A=()=>{N(),P()};N();for(const c of t)c&&y.observe(c,{box:"border-box"});return window.addEventListener("resize",A),()=>{y.disconnect(),window.removeEventListener("resize",A);for(const c of o)c.style.removeProperty("--clover-sections-before"),c.style.removeProperty("--clover-sections-after");e.style.removeProperty("--clover-sections-total"),delete e.dataset.stacks}},[s,K,h]),z(()=>{if(s)return;const e=f.current.map(t=>t==null?void 0:t.parentElement).filter(t=>!!t),o=t=>{var u;if(t.ctrlKey)return;const l=t.currentTarget,a=_(l);if(!a||a===document.scrollingElement)return;t.preventDefault();const d=t.deltaMode===1?parseFloat(getComputedStyle(l).lineHeight)||16:t.deltaMode===2?a.clientHeight:1;(u=_(a)??document.scrollingElement)==null||u.scrollBy({left:t.deltaX*d,top:t.deltaY*d,behavior:"instant"})};for(const t of e)t.addEventListener("wheel",o,{passive:false});return()=>{for(const t of e)t.removeEventListener("wheel",o)}},[s,K]);const W=e=>{e!==v&&(T.current=e,s||ne(o=>({value:e,count:o.count+1})),S==null||S(e))},se=(e,o)=>{var u;const t=n.length-1,[l,a]=s?["ArrowLeft","ArrowRight"]:["ArrowUp","ArrowDown"],d=e.key===a?(o+1)%n.length:e.key===l?(o-1+n.length)%n.length:e.key==="Home"?0:e.key==="End"?t:null;d!==null&&(e.preventDefault(),(u=f.current[d])==null||u.focus(),s&&W(n[d].value))},Y=$(false);z(()=>{if(!s)return;const e=n.findIndex(p=>p.value===v),o=f.current[e],t=o==null?void 0:o.parentElement;if(!o||!t)return;const l=getComputedStyle(t),a=t.getBoundingClientRect(),d=o.getBoundingClientRect(),u=a.left+(parseFloat(l.scrollPaddingLeft)||0),b=a.right-(parseFloat(l.scrollPaddingRight)||0);(d.left<u-1||d.right>b+1)&&m.scrollToIndex(e,{instant:!Y.current}),Y.current=true},[v,s,n.length,m.scrollToIndex]);const q=e=>{const o=e==="prev"?m.canScrollPrev:m.canScrollNext,t=e==="prev"?"sectionsScrollBack":"sectionsScrollForward";return i("button",{type:"button",className:`clover-sections-scroll-${e}`,"aria-hidden":"true",tabIndex:-1,hidden:!o,...ue(oe(t)),onMouseDown:l=>l.preventDefault(),onClick:e==="prev"?m.scrollPrev:m.scrollNext,children:[i("svg",{"aria-hidden":"true",focusable:"false",width:"
|
|
1
|
+
import{b as ae,A as $,a as ie,d as G,y as z,_ as de,u as i,Q as J,l as ue,k as fe,x as Z}from"./shared-DkY2a89G.mjs";import{a as pe}from"./heading-Cjt0f-Eu.mjs";import{T as ve}from"./Tip-OCB88zwY.mjs";import{u as he}from"./useContainerName-hKQjEt7a.mjs";import{u as ge}from"./useScrollTrack-D9l_P3_B.mjs";import{C as me}from"./Chevron-Cyr_cc9X.mjs";import"./styles-DkkVOSUQ.mjs";const V=typeof window>"u"?z:de,ee=J(null);function Pe(){return Z(ee)}const te=J(0);function Ne(){return Z(te)}function $e({items:n,layout:r="tabs",value:R,onValueChange:S,label:E,labelLang:F,headingLevel:h=3}){var Q;const g=ae(),k=he(E??"",F,E===void 0),f=$([]),s=r==="tabs",{t:I,langOf:oe}=ie(),m=ge({dragFree:true,itemCount:n.length}),v=n.some(e=>e.value===R)?R:((Q=n[0])==null?void 0:Q.value)??null,H=$(new Set);v&&H.current.add(v);const T=$(null),[D,ne]=G({value:null,count:0});z(()=>{var d;if(s||!v||T.current!==v)return;T.current=null;const e=n.findIndex(u=>u.value===v),o=document.getElementById(`${g}-panel-${e}`),t=(d=f.current[e])==null?void 0:d.parentElement;if(!o||!t)return;const l=t.getBoundingClientRect().bottom-o.getBoundingClientRect().top;if(l<=0)return;const a=M(o);a&&(a.scrollTop-=l)},[v,s,n,g]);const re=e=>{var B,P,y,N;const o=n.findIndex(A=>A.value===v),t=document.getElementById(`${g}-panel-${o}`),l=e.target;if(!t||l===t||!t.contains(l)||!ye(l))return;const a=(P=(B=f.current[o])==null?void 0:B.parentElement)==null?void 0:P.getBoundingClientRect(),d=o+1<n.length?(N=(y=f.current[o+1])==null?void 0:y.parentElement)==null?void 0:N.getBoundingClientRect():void 0;if(!a)return;const u=l.getBoundingClientRect(),b=u.top<a.bottom?Math.floor(u.top-a.bottom):d&&u.bottom>d.top?Math.ceil(Math.min(u.bottom-d.top,u.top-a.bottom)):0,p=b?M(t):null;p&&(p.scrollTop+=b)},j=$(null),K=n.map(e=>e.value).join(`
|
|
2
|
+
`);V(()=>{const e=j.current;if(s||!e||typeof ResizeObserver>"u")return;const o=[...e.querySelectorAll(":scope > .clover-sections-item")],t=o.map(c=>c.firstElementChild),l=t[0],a=t[t.length-1],d=new Map,u=c=>(c&&d.get(c))??0,b=document.scrollingElement;let p=null,B=0;const P=()=>{const c=t.reduce((O,L)=>O+u(L),0);let C=0;o.forEach((O,L)=>{O.style.setProperty("--clover-sections-before",`${C}px`),C+=u(t[L]),O.style.setProperty("--clover-sections-after",`${c-C}px`)}),e.style.setProperty("--clover-sections-total",`${c}px`);const w=l&&getComputedStyle(l);(w==null?void 0:w.position)==="sticky"&&a&&(B=parseFloat(w.top)+parseFloat(getComputedStyle(a).bottom)||0);const x=getComputedStyle(e),ce=parseFloat(x.lineHeight)||1.2*parseFloat(x.fontSize),X=(p==null?void 0:p.clientHeight)??0;X>0&&X-B-c<2*ce?e.dataset.stacks="off":delete e.dataset.stacks},y=new ResizeObserver(c=>{var C,w;for(const x of c)t.includes(x.target)&&d.set(x.target,((w=(C=x.borderBoxSize)==null?void 0:C[0])==null?void 0:w.blockSize)??x.target.getBoundingClientRect().height);P()}),N=()=>{const c=M(e);c!==p&&(p&&p!==b&&y.unobserve(p),c&&c!==b&&y.observe(c),p=c)},A=()=>{N(),P()};N();for(const c of t)c&&y.observe(c,{box:"border-box"});return window.addEventListener("resize",A),()=>{y.disconnect(),window.removeEventListener("resize",A);for(const c of o)c.style.removeProperty("--clover-sections-before"),c.style.removeProperty("--clover-sections-after");e.style.removeProperty("--clover-sections-total"),delete e.dataset.stacks}},[s,K,h]),z(()=>{if(s)return;const e=f.current.map(t=>t==null?void 0:t.parentElement).filter(t=>!!t),o=t=>{var u;if(t.ctrlKey)return;const l=t.currentTarget,a=_(l);if(!a||a===document.scrollingElement)return;t.preventDefault();const d=t.deltaMode===1?parseFloat(getComputedStyle(l).lineHeight)||16:t.deltaMode===2?a.clientHeight:1;(u=_(a)??document.scrollingElement)==null||u.scrollBy({left:t.deltaX*d,top:t.deltaY*d,behavior:"instant"})};for(const t of e)t.addEventListener("wheel",o,{passive:false});return()=>{for(const t of e)t.removeEventListener("wheel",o)}},[s,K]);const W=e=>{e!==v&&(T.current=e,s||ne(o=>({value:e,count:o.count+1})),S==null||S(e))},se=(e,o)=>{var u;const t=n.length-1,[l,a]=s?["ArrowLeft","ArrowRight"]:["ArrowUp","ArrowDown"],d=e.key===a?(o+1)%n.length:e.key===l?(o-1+n.length)%n.length:e.key==="Home"?0:e.key==="End"?t:null;d!==null&&(e.preventDefault(),(u=f.current[d])==null||u.focus(),s&&W(n[d].value))},Y=$(false);z(()=>{if(!s)return;const e=n.findIndex(p=>p.value===v),o=f.current[e],t=o==null?void 0:o.parentElement;if(!o||!t)return;const l=getComputedStyle(t),a=t.getBoundingClientRect(),d=o.getBoundingClientRect(),u=a.left+(parseFloat(l.scrollPaddingLeft)||0),b=a.right-(parseFloat(l.scrollPaddingRight)||0);(d.left<u-1||d.right>b+1)&&m.scrollToIndex(e,{instant:!Y.current}),Y.current=true},[v,s,n.length,m.scrollToIndex]);const q=e=>{const o=e==="prev"?m.canScrollPrev:m.canScrollNext,t=e==="prev"?"sectionsScrollBack":"sectionsScrollForward";return i("button",{type:"button",className:`clover-steps-step clover-sections-scroll-${e}`,"aria-hidden":"true",tabIndex:-1,hidden:!o,...ue(oe(t)),onMouseDown:l=>l.preventDefault(),onClick:e==="prev"?m.scrollPrev:m.scrollNext,children:[i("svg",{"aria-hidden":"true",focusable:"false",width:"12",height:"12",viewBox:"0 0 16 16",children:i("path",{d:e==="next"?"M6 3l5 5-5 5":"M10 3L5 8l5 5",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})}),i(ve,{label:I(t)})]})},le=pe(h,"div"),U=(e,o)=>{const t=e.value===v;return i("button",{ref:l=>{f.current[o]=l},type:"button",id:`${g}-button-${o}`,className:"clover-sections-button","data-value":e.value,"data-track-index":s?o:void 0,"aria-controls":`${g}-panel-${o}`,...s?{role:"tab","aria-selected":t,tabIndex:t?0:-1}:{"aria-expanded":t,"aria-disabled":t||void 0},onClick:()=>W(e.value),onKeyDown:l=>se(l,o),children:[i("span",{className:"clover-sections-label",children:e.label}),!s&&i(me,{open:t,className:"clover-sections-chevron"})]},e.value)};return i("div",{ref:j,className:"clover-sections","data-layout":r,onFocus:s?void 0:re,style:s?void 0:{"--clover-sections-count":n.length},children:[s&&i("div",{className:"clover-sections-tabs","data-more":[m.canScrollPrev&&"start",m.canScrollNext&&"end"].filter(Boolean).join(" ")||void 0,children:i("div",{className:"clover-sections-row",children:[i("div",{role:"tablist",ref:m.ref,...k.props,className:"clover-sections-list",children:n.map(U)}),q("prev"),q("next")]})}),s&&k.node,n.map((e,o)=>{const t=e.value===v;return i("section",{className:"clover-sections-item","data-value":e.value,"data-open":t,style:s?void 0:{"--clover-sections-index":o},children:[!s&&i(le,{className:"clover-sections-heading",children:[U(e,o),i("span",{className:"clover-sections-reach","aria-hidden":"true"})]}),i(te.Provider,{value:D.value===e.value?D.count:0,children:i(be,{id:`${g}-panel-${o}`,tabs:s,labelledBy:`${g}-button-${o}`,hidden:!t,actions:e.actions,children:H.current.has(e.value)?e.content:null})})]},e.value)})]})}function be({id:n,tabs:r,labelledBy:R,hidden:S,actions:E,children:F}){const[h,g]=G(null),k=!S||!!E;return V(()=>{const f=h==null?void 0:h.parentElement;if(!k||!h||!f||typeof ResizeObserver>"u")return;const s=new ResizeObserver(()=>{const I=h.offsetWidth;I?(f.style.setProperty("--clover-sections-actions",`${I}px`),f.setAttribute("data-actions","")):(f.style.removeProperty("--clover-sections-actions"),f.removeAttribute("data-actions"))});return s.observe(h),()=>{s.disconnect(),f.style.removeProperty("--clover-sections-actions"),f.removeAttribute("data-actions")}},[h,k]),i(fe,{children:[!r&&i("div",{ref:g,className:"clover-sections-actions",hidden:!k,children:E}),i("div",{id:n,role:r?"tabpanel":"region","aria-labelledby":R,tabIndex:r?0:void 0,className:"clover-sections-panel",hidden:S,children:i(ee.Provider,{value:r?null:h,children:[r&&E,F]})})]})}function M(n){for(let r=n.parentElement;r&&r!==document.body;r=r.parentElement)if(/auto|scroll|hidden/.test(getComputedStyle(r).overflowY))return r;return document.scrollingElement}function _(n){for(let r=n.parentElement;r&&r!==document.body;r=r.parentElement)if(/auto|scroll/.test(getComputedStyle(r).overflowY)&&r.scrollHeight>r.clientHeight)return r;return document.scrollingElement}function ye(n){try{return n.matches(":focus-visible")}catch{return true}}export{$e as S,Pe as a,Ne as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as b,A as I,y as L,
|
|
1
|
+
import{d as b,A as I,y as L,aD as P,T as V,a3 as k,u as O,X as F}from"./shared-DkY2a89G.mjs";import{s as M,P as R,a as T}from"./Items-CudZ4Lnb.mjs";import{b as X}from"./items-BnEnc5ot.mjs";function B({iiifContent:a,items:e,navigation:w,onSelect:r,request:i,header:x=true,forwardedRef:g,...u}){var p;const[s,A]=b(null),[f,c]=b(0),D=typeof a=="string"?a:a==null?void 0:a.id,m=I({iiifContent:a,request:i});m.current={iiifContent:a,request:i},L(()=>{if(e||m.current.iiifContent===void 0)return;const t=new AbortController;return P(m.current.iiifContent,{request:m.current.request,signal:t.signal}).then(o=>{t.signal.aborted||A(o)}).catch(()=>{}),()=>t.abort()},[D,e]);const n=V(()=>X(e||s),[e,s]);if(!n.length)return null;const h=!e&&(s==null?void 0:s.type)==="Manifest",d=k(s==null?void 0:s.viewingDirection),y=w??(h?"id":"homepage");if(u.layout==="pager")return O(R,{...u,forwardedRef:g,steps:M(n,f,d,(t,o)=>{r==null||r(t,o),c(n.indexOf(t))})});const l=(p=s==null?void 0:s.homepage)==null?void 0:p[0],v=l==null?void 0:l.id;return O(T,{...u,forwardedRef:g,items:n,selected:y==="id"?f:-1,navigation:y,rtl:d==="right-to-left",request:i,showSummary:!h,heading:x&&s?{label:s.label,summary:s.summary,homepage:v,homepageLang:F(l)}:void 0,onActivate:(t,o)=>{r==null||r(t,o),c(n.indexOf(t))},followFocus:t=>c(n.indexOf(t))})}export{B as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as p,u as s,v as c,l as d,k as m}from"./shared-
|
|
1
|
+
import{a as p,u as s,v as c,l as d,k as m}from"./shared-DkY2a89G.mjs";import{j as v}from"./classnames-DukgfdpI.mjs";import{b as f}from"./hooks-BhtNDs_1.mjs";import{L as h}from"./Loading-YxuKrDAM.mjs";function b({className:e,loading:t,error:l}){const{t:n,langOf:i}=p(),{status:a,error:o}=f(),r=a==="loading",u=t!==void 0&&t!==false;return s(m,{children:[s("p",{className:v("clover-status",e),"data-status":r?a:void 0,role:"status",style:r&&t!==false?void 0:c,children:[r&&(u?t:t===void 0&&s(h,{})),r&&!u&&s("span",{style:c,...d(i("statusLoading")),children:n("statusLoading")})]}),a==="error"&&o&&s("div",{className:v("clover-status",e),"data-status":a,role:"alert",children:l?l(o):s(m,{children:[s("p",{...d(i("statusError")),children:n("statusError")}),s("p",{className:"clover-status-detail",lang:"en",children:o.message})]})})]})}export{b as S};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as c,u as o,l as p,v as u}from"./shared-
|
|
1
|
+
import{a as c,u as o,l as p,v as u}from"./shared-DkY2a89G.mjs";import{j as h}from"./classnames-DukgfdpI.mjs";import{T as v}from"./Tip-OCB88zwY.mjs";import"./styles-DkkVOSUQ.mjs";function g({steps:e,sentence:t,className:a}){const{t:l,langOf:n}=c(),{position:r,total:i}=e;if(i<1)return null;const s=r+1;return o("div",{className:h("clover-steps",a),children:[o("span",{"aria-live":"polite",className:"clover-steps-position",children:[o("span",{"aria-hidden":t?"true":void 0,children:[s>0?s:"\u2013"," / ",i]}),o("span",{className:"clover-steps-room","aria-hidden":"true",hidden:true,children:[i," / ",i]}),t&&s>0&&o("span",{style:u,...p(n(t)),children:l(t,{index:s,total:i})})]}),o(d,{steps:e,step:"previous"}),o(d,{steps:e,step:"next"})]})}function d({steps:e,step:t}){const{t:a,langOf:l}=c(),n=t==="next",r=n?e.position+1<e.total:e.position>0,i=n?"commonNext":"commonPrevious";return o("button",{type:"button",className:"clover-steps-step","data-step":t,...p(l(i)),"aria-disabled":!r||void 0,tabIndex:r?void 0:-1,onClick:()=>{r&&e.step(n?1:-1)},children:[o("svg",{"aria-hidden":"true",focusable:"false",width:"12",height:"12",viewBox:"0 0 16 16",children:o("path",{d:n?"M6 3l5 5-5 5":"M10 3L5 8l5 5",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})}),o("span",{style:u,children:a(i)}),o(v,{label:a(i)})]})}export{g as S};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{e as g,c as u,
|
|
1
|
+
import{e as g,c as u,ae as v,t as f,u as d,l as h,T as p,d as x,y,F as b}from"./shared-DkY2a89G.mjs";import{s as w,P as M,a as C}from"./Items-CudZ4Lnb.mjs";import{C as P}from"./CountMenu-Dnzb7lKo.mjs";import{f as S,r as N}from"./fetchManifest-CwQC6cCh.mjs";import{S as q}from"./Steps-nlSCzbDQ.mjs";import{a as A}from"./heading-Cjt0f-Eu.mjs";function I({onSelect:s,forwardedRef:t,...i}){const{clover:l,language:o}=g("Items"),{items:a,position:e}=F(),r=(n,c)=>{s==null||s(n,c);const m=a.findIndex(T=>T.id===n.id);m>=0&&l.goToTarget(m)};return i.layout==="pager"?d(M,{...i,forwardedRef:t,steps:w(a,e,"left-to-right",r),nameKey:"informationPanelTabsTargets",position:d(P,{position:e,total:a.length,list:n=>d(I,{layout:"list",forwardedRef:null,onSelect:n})})}):d(C,{...i,forwardedRef:t,items:a,selected:e,navigation:"id",language:o,request:l.request,showSummary:true,onActivate:r})}function F(){const{language:s}=g("Items"),t=u(e=>e.targets),i=u(e=>e.manifest),l=u(e=>v(e.targets,e.targetIndex,e.manifest,e.canvasId)),o=z(t==null?void 0:t.items,i);return{items:p(()=>((t==null?void 0:t.items)??[]).map(e=>B(e,o.get(e.manifestId)??(e.manifestAs?o.get(e.manifestAs):void 0),s)),[t,o,s]),position:l}}function z(s,t){const{clover:i}=g("Items"),l=p(()=>[...new Set((s??[]).map(e=>e.manifestId))],[s]),[o,a]=x(new Map);return y(()=>{let e=true;return Promise.all(l.map(async r=>[r,await S(i,r)])).then(r=>{e&&a(new Map(r.filter(n=>!!n[1])))}),()=>{e=false}},[i,l]),p(()=>{const e=new Map(o);return t&&e.set(t.id,t),e},[o,t])}function B(s,t,i){const l=t?b(t).canvases:[],o=l.find(m=>m.id===s.canvasId)??l[0],a=t==null?void 0:t.label,e=o==null?void 0:o.label,r=f(e,i).text?e:a,n=a&&r!==a&&f(a,i).text!==f(r,i).text?a:void 0,c=o&&s.region?N(o,s.region):void 0;return{id:s.id,label:r,summary:n,parts:[{id:s.id,type:"Canvas",label:r,resource:o??{id:s.canvasId??s.manifestId},...c?{source:c}:{}}]}}function D({headingLevel:s=3}){const{clover:t,language:i}=g("Items"),l=u(n=>{var c;return(c=n.targets)==null?void 0:c.label}),o=u(n=>{var c;return((c=n.targets)==null?void 0:c.items.length)??0}),a=u(n=>v(n.targets,n.targetIndex,n.manifest,n.canvasId));if(o<2)return null;const e=f(l,i),r=A(s);return d("div",{className:"clover-about clover-collection clover-targets",children:[d("div",{className:"clover-targets-head",children:[e.text&&d(r,{className:"clover-collection-title clover-title",...h(e.lang),children:e.text}),d(q,{className:"clover-targets-steps",steps:{position:a,total:o,step:n=>{const c=a+n;c>=0&&c<o&&t.goToTarget(c)}}})]}),d(I,{layout:"list",forwardedRef:null})]})}export{D as TargetsSection,I as default,F as useTargetItems};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{O as f,u as a,z as l,P as r}from"./shared-DkY2a89G.mjs";import{C as m}from"./CanvasView-2Fj9nT06.mjs";import{p as t}from"./playerSurface-DG1XipTq.mjs";import{C as s}from"./Pending-BxGjjnqq.mjs";import{j as u}from"./classnames-DukgfdpI.mjs";const d=l(()=>import("./Connected-pyd0EBD3.mjs")),v=l(()=>import("./LoadedCanvas-IvpSzPO6.mjs"));function h({timeline:o,className:n,...e}){const c=f(),i=u("clover-timeline",n);return e.iiifContent!==void 0&&o===void 0?a(r,{fallback:a(s,{}),children:a(v,{...e,className:i,of:"Timeline",surface:t})}):o?a(m,{...e,className:i,canvases:[o],navigator:false,surface:t}):c?a(r,{fallback:a(s,{}),children:a(d,{...e,className:n})}):null}export{h as Timeline,h as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as k,A as L,y as v,u as f,l as w}from"./shared-
|
|
1
|
+
import{a as k,A as L,y as v,u as f,l as w}from"./shared-DkY2a89G.mjs";import"./styles-DkkVOSUQ.mjs";const M={zoomIn:{keys:"Plus",glyph:"+"},zoomOut:{keys:"-",glyph:"\u2212"},reset:{keys:"0",glyph:"0"},rotateRight:{keys:"R",glyph:"R"},rotateLeft:{keys:"Shift+R",glyph:"\u21E7R"},play:{keys:"K Space",glyph:"K"},mute:{keys:"M",glyph:"M"}},R=new Set(["+","=","-","_","0","r","R","k","K","m","M","j","J","l","L"]);function B({label:t,lang:e,shortcut:n,scrolls:o=false,image:r,lead:i,after:a}){const{t:c}=k(),l=L(null),u=n?c("controlShortcut",{label:t,shortcut:n.glyph}):t;return K(),v(()=>{const s=l.current;s&&y(s)&&p(s)},[u,i]),f("span",{ref:l,className:"clover-tip","aria-hidden":"true",...w(e),...o&&{tabIndex:-1,onMouseDown:s=>{var m;s.preventDefault(),(m=s.currentTarget.parentElement)==null||m.focus({preventScroll:true})}},children:[r&&f("img",{className:"clover-tip-image",src:r,alt:"",loading:"lazy",onLoad:()=>{const s=l.current;s&&y(s)&&p(s)}}),i&&f("span",{className:"clover-tip-lead",children:i}),u,a!=null&&a!==false&&f("span",{className:"clover-tip-after",children:a})]})}function d(t){const e=t.target instanceof Element&&S(t.target),n=e&&h(e);n&&p(n)}function h(t){return Array.from(t.children).find(e=>e.classList.contains("clover-tip"))}function S(t){const e=t.matches("input")?t.parentElement:null;return e&&h(e)?e:t}function y(t){var e;try{return!!((e=t.parentElement)!=null&&e.matches(":hover, :focus-visible, :has(> input:focus-visible)"))}catch{return false}}function p(t){const e=t.parentElement;if(!e)return;t.style.removeProperty("--clover-tip-room"),t.style.removeProperty("--clover-tip-shift");const n=T(e),o=parseFloat(getComputedStyle(t).paddingLeft)||0,r=n.left+o,i=n.right-o,a=e.getBoundingClientRect();let c=t.getBoundingClientRect();const l=c.right<=a.left?c.right-r:c.left>=a.right?i-c.left:i-r;c.width>l&&(t.style.setProperty("--clover-tip-room",`${Math.max(l,0)}px`),c=t.getBoundingClientRect());const u=c.left<r?r-c.left:c.right>i?i-c.right:0;u&&t.style.setProperty("--clover-tip-shift",`${u}px`)}function T(t){let e=0,n=document.documentElement.clientWidth||window.innerWidth;for(let o=t.parentElement;o&&o!==document.documentElement;o=o.parentElement){const{display:r,overflow:i,overflowX:a}=getComputedStyle(o);if(r==="inline"||r==="contents")continue;const c=a||i;if(!c||c==="visible")continue;const l=o.getBoundingClientRect();e=Math.max(e,l.left+o.clientLeft),n=Math.min(n,l.left+o.clientLeft+o.clientWidth)}return{left:e,right:n}}let g=0;function E(t){if(t.key!=="Escape")return;const e=new Set;document.querySelectorAll(":hover > .clover-tip").forEach(r=>r.parentElement&&e.add(r.parentElement));const n=document.activeElement,o=n&&S(n);o&&h(o)&&e.add(o),e.forEach(r=>b(r,"tipHidden",["pointerenter","focusout"]))}function b(t,e,n){t.dataset[e]="";const o=()=>{delete t.dataset[e],n.forEach(r=>t.removeEventListener(r,o))};n.forEach(r=>t.addEventListener(r,o))}function K(){v(()=>(g++===0&&(document.addEventListener("keydown",E,true),document.addEventListener("pointerenter",d,true),document.addEventListener("focus",d,true)),()=>{--g||(document.removeEventListener("keydown",E,true),document.removeEventListener("pointerenter",d,true),document.removeEventListener("focus",d,true))}),[])}function O(t,e){const n=t.target;!e||n===e||e.contains(n)||R.has(t.key)&&(t.altKey||t.metaKey||t.ctrlKey||n.closest("input, select, textarea, [contenteditable]")||(t.preventDefault(),e.dispatchEvent(new KeyboardEvent("keydown",{key:t.key,shiftKey:t.shiftKey,bubbles:true,cancelable:true}))))}export{M as S,B as T,O as f,b as h};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{D as Le,a as Oe,e as Ie,c as
|
|
1
|
+
import{D as Le,a as Oe,e as Ie,c as $e,n as Me,T as ie,d as C,y as m,N as Re,C as Se,A as L,b as we,u as n,t as Ee,k as le,l as M,v as Ae,$ as Pe,E as ze}from"./shared-DkY2a89G.mjs";import{c as ue,a as de}from"./layout-Djwu8f4R.mjs";import{l as Fe,a as Ve,p as He,b as Ke,c as je}from"./vtt-Dd0c7psH.mjs";import{j as qe}from"./classnames-DukgfdpI.mjs";import{u as De}from"./readingLanguages-BWOLZK2k.mjs";import{b as pe,s as Ue}from"./bringIntoView-CQH5ZgMM.mjs";import{C as Xe}from"./Cue-CUGmPS3k.mjs";import{F as Be}from"./FieldPill-nFGsaru9.mjs";import{l as Ge}from"./languageCode-cCpiU0b0.mjs";import{a as Je}from"./Sections-d1acn7qm.mjs";import{T as Qe}from"./Tip-OCB88zwY.mjs";import{u as We}from"./useContainerName-hKQjEt7a.mjs";import"./styles-DkkVOSUQ.mjs";const j=40,q=s=>s.toLocaleLowerCase();function Ye(s,i){if(!i)return s;const v=q(s),g=[];let a=0;for(let p=v.indexOf(i);p>=0;p=v.indexOf(i,p+i.length))p>a&&g.push(s.slice(a,p)),g.push(n("mark",{children:s.slice(p,p+i.length)},p)),a=p+i.length;return a<s.length&&g.push(s.slice(a)),g}const R=s=>s.read==="cues"&&s.kind!=="transcript",ft=Le(function({as:i="div",follow:v=true,find:g=true,sticky:a=false,size:p="large",className:fe,...ge},me){const{t:D,langOf:U}=Oe(),{clover:o,language:X}=Ie("Transcript"),T=$e(e=>Me(e.manifest,e.canvasId)).find(e=>ue(e).length>0||de(e).length>0),l=ie(()=>T?[...ue(T).map(e=>({...e,read:"cues"})),...de(T).map(e=>({...e,read:"text"}))]:[],[T]),[B,S]=C(0),u=l[B]??l[0],O=De(),w=(O==null?void 0:O.chosen)??X;m(()=>{if(!w)return;const e=l.findIndex(r=>r.language&&r.language!=="none"&&Re(r.language,w));if(e<0)return;S(e);const t=l[e];R(t)&&o.captions.get()!==t.id&&o.captions.emit(t.id)},[w,l,o]),m(()=>{const e=t=>{const r=l.findIndex(d=>R(d)&&d.id===t);r>=0&&S(r)};return e(o.captions.get()),o.captions.subscribe(e)},[o,l]);const[c,G]=C([]),[ve,J]=C([]);m(()=>{if(G([]),J([]),!u)return;let e=true;return(u.read==="cues"?Fe(u.id,o.request).then(t=>e&&G(He(t))):Ve(u.id,o.request).then(t=>e&&J(Ke(t)))).catch(()=>{}),()=>{e=false}},[u,o]);const h=Se(o.media.subscribe,o.media.get,o.media.get),y=Ze(h,c),E=L(null);m(()=>{var t;if(!v||y<0||!h||h.paused)return;const e=(t=E.current)==null?void 0:t.children[y];e&&pe(e,"nearest")},[y,v,h]);const[Q,W]=C(""),f=q(Q.trim()),b=ie(()=>f?c.flatMap((e,t)=>q(e.text).includes(f)?[t]:[]):[],[c,f]),[A,he]=C({query:"",at:0}),x=A.query===f?A.at:0,P=L(null),z=L(false),[Y,be]=C({cues:[],count:j}),Z=Y.cues===c?Y.count:j,F=()=>be({cues:c,count:Z+j}),_=L(F);_.current=F;const V=typeof IntersectionObserver<"u",N=V?Math.min(c.length,Math.max(Z,y+1,(b[x]??-1)+1)):c.length,ee=L(null);m(()=>{const e=ee.current;if(!e||!V||N>=c.length)return;const t=new IntersectionObserver(r=>{r.some(d=>d.isIntersecting)&&_.current()},{root:Ue(e),rootMargin:"0px 0px 400px 0px"});return t.observe(e),()=>t.disconnect()},[V,N,c.length]);const I=b[x];m(()=>{var t;if(I===void 0)return;const e=(t=E.current)==null?void 0:t.children[I];e&&pe(e,"nearest"),z.current=false},[I,f]);const Ce=c.length>0;m(()=>{var d;const e=(d=P.current)==null?void 0:d.closest(".clover-transcript-find"),t=e==null?void 0:e.parentElement;if(!a||!e||!t||typeof ResizeObserver>"u")return;const r=new ResizeObserver(()=>t.style.setProperty("--clover-transcript-find",`${e.offsetHeight}px`));return r.observe(e),()=>{r.disconnect(),t.style.removeProperty("--clover-transcript-find")}},[a,Ce,g]);const H=we(),te=Je(),ne=l.every(R)?"playerCaptions":"transcriptLabel",se=We(D(ne),U(ne));if(!T||!u)return null;const Te=l.filter(e=>e.read==="text").length,re=l.map(e=>{const t=Ge(e.language);return e.read==="cues"?t:Te>1&&t?`TXT ${t}`:"TXT"}),xe=re.map(e=>e&&re.filter(t=>t===e).length===1?e:void 0),ae=u.language&&u.language!=="none"?u.language:void 0,K=l.length>1&&!O&&n(le,{children:[se.node,n("fieldset",{...se.props,className:"clover-transcript-languages",children:l.map((e,t)=>{const r=Ee(e.label,X),d=xe[t],ke=r.text||e.language||String(t+1);return n("label",{className:"clover-transcript-language",children:[n("input",{type:"radio",name:`${H}-language`,checked:t===B,onChange:()=>{S(t),R(e)&&o.captions.emit(e.id)}}),d&&n(le,{children:[n("span",{className:"clover-transcript-code",children:d})," "]}),n("span",{style:d?Ae:void 0,...M(r.text?r.lang:void 0),children:ke}),d&&r.text&&n(Qe,{label:r.text,lang:r.lang})]},e.id)})})]}),ce=(e,t=true)=>{if(h){t?ze(h,e.start):h.currentTime=e.start;return}o.goTo(T.id,{time:e.start,...t&&{autoplay:true}})},oe=e=>{const t=c[b[e]];t&&(z.current=true,he({query:f,at:e}),ce(t,false))},Ne={position:b.length?x:-1,total:b.length,step:e=>oe(x+e)},k=b.length,$=f?k===0?"contentSearchResultsNone":k===1?"contentSearchResult":"contentSearchResults":null,ye=g&&u.read==="cues"&&c.length>0&&n("div",{className:"clover-transcript-find",children:[n(Be,{ref:P,id:`${H}-find`,value:Q,onChange:W,onSubmit:()=>{if(!k)return;const e=A.query===f&&z.current;oe(e?(x+1)%k:x)},onClear:()=>{var e;W(""),(e=P.current)==null||e.focus()},results:f?Ne:null,size:p,classes:{form:"clover-transcript-find-field"}}),n("p",{className:"clover-transcript-find-status",role:"status",...M($?U($):void 0),children:$?D($,{count:k}):""})]});return n(i,{ref:me,className:qe("clover-transcript",fe),"data-sticky":a||void 0,...ge,children:[K&&(te?Pe(K,te):K),ye,u.read==="text"?n("div",{className:"clover-transcript-body",...M(ae),children:ve.map((e,t)=>n("p",{children:e},t))}):n("ol",{ref:E,className:"clover-transcript-cues",id:`${H}-cues`,...M(ae),children:c.slice(0,N).map((e,t)=>n("li",{className:"clover-transcript-cue","aria-current":t===y?"true":void 0,"data-match":f&&b.includes(t)?t===I?"current":"true":void 0,children:n("button",{type:"button",onClick:()=>ce(e),onFocus:()=>{N<c.length&&t>=N-5&&F()},children:[n(Xe,{start:e.start,className:"clover-transcript-time"}),n("span",{className:"clover-transcript-text clover-cue-text",children:[e.voice&&n("span",{className:"clover-transcript-voice",children:[e.voice,":"," "]}),Ye(e.text,f)]})]})},`${e.start}-${t}`))}),u.read==="cues"&&N<c.length&&n("div",{ref:ee,className:"clover-transcript-more","aria-hidden":"true"})]})});function Ze(s,i){const[v,g]=C(-1);return m(()=>{if(!s||!i.length){g(-1);return}const a=()=>g(je(i,s.currentTime));return a(),s.addEventListener("timeupdate",a),s.addEventListener("seeked",a),()=>{s.removeEventListener("timeupdate",a),s.removeEventListener("seeked",a)}},[s,i]),v}export{ft as Transcript};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as g,u as o,l as b,_ as m}from"./shared-DkY2a89G.mjs";import{T as x}from"./Tip-OCB88zwY.mjs";import{f,g as k}from"./pointer-YQppt0at.mjs";import{a as y}from"./index-FJEpXukG.mjs";function T({words:r,button:e,shortcut:t,disabled:n,pressed:s,onClick:a,buttonRef:c,children:v}){const{t:i,langOf:h}=g(),d=i(r);return o("button",{"aria-label":d,...b(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>.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};
|
|
@@ -0,0 +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-DkY2a89G.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-DaIhfZqC.mjs";import{imageSource as Ae}from"./thumbnail-DecrVnpj.mjs";import{u as Ke,P as Le,E as Ue}from"./EntryThumbnail-BxQWKW6e.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-OCB88zwY.mjs";import{u as qe}from"./useContainerName-hKQjEt7a.mjs";import{u as ze,t as _e}from"./pointer-YQppt0at.mjs";import"./styles-DkkVOSUQ.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};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{S as l,az as g,ax as y,aA as u,ay as f}from"./shared-DkY2a89G.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{
|
|
1
|
+
import{t as d,Z as p}from"./shared-DkY2a89G.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-Bdtn50sf.mjs → annotations-content-Bg6aVAGC.mjs}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{loadAnnotationSets as f}from"./annotation-collection-
|
|
1
|
+
import{loadAnnotationSets as f}from"./annotation-collection-D8emkElk.mjs";import{G as i,aB as l,ar as c}from"./shared-DkY2a89G.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-DkY2a89G.mjs";import{B as h}from"./Body-Ct61yxI7.mjs";import{u as y,P as L}from"./nodes-ChQRLDGU.mjs";import{Toggle as b}from"./toggle-CZGB65VZ.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};
|
|
@@ -0,0 +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-DkY2a89G.mjs";import{C as b}from"./CanvasView-2Fj9nT06.mjs";import{r as s}from"./rendererSurface-BkbGDL_Z.mjs";import{C as i}from"./Pending-BxGjjnqq.mjs";const h=c(()=>import("./Connected-DMXG3imZ.mjs")),B=c(()=>import("./LoadedCanvas-IvpSzPO6.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};
|