@cntrl-site/components 0.1.0-alpha.23 → 0.1.0-alpha.24
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.css +1 -1
- package/dist/index.js +106 -23
- package/dist/index.mjs +107 -24
- package/package.json +1 -1
package/dist/components.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.ControlSlider-module__wrapper___sHEkd{position:relative;width:100%;height:100%}.ControlSlider-module__slider___R3i9-{width:100%;height:100%}.ControlSlider-module__sliderItems___1MgPL{display:flex;overflow:hidden;width:100%;height:100%;transition:transform .3s ease-in-out}.ControlSlider-module__sliderItem___QQSkR{width:100%;height:100%;display:flex;position:relative}.ControlSlider-module__sliderImage___9hRl-{width:100%;height:100%;object-fit:cover}.ControlSlider-module__arrow___05ghY{position:absolute;display:flex;align-items:center;justify-content:center;border:none;background-color:transparent;top:50%;left:calc(var(--is-editor, 0) * -1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -1.3888888889vw);z-index:1;transform:translate(-50%,-50%);padding:0;width:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw);height:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw)}.ControlSlider-module__arrow___05ghY.ControlSlider-module__arrowVertical___tBfVN{left:50%;top:calc(var(--is-editor, 0) * -1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -1.3888888889vw);transform:translate(-50%,-50%)}.ControlSlider-module__nextArrow___-30Yc{left:unset;right:calc(var(--is-editor, 0) * -1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -1.3888888889vw);transform:translate(50%,-50%)}.ControlSlider-module__nextArrow___-30Yc.ControlSlider-module__arrowVertical___tBfVN{left:50%;right:unset;top:unset;bottom:calc(var(--is-editor, 0) * -1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -1.3888888889vw);transform:translate(-50%,50%)}.ControlSlider-module__arrowInner___aEra3{all:unset;cursor:pointer;width:100%;height:100%}.ControlSlider-module__arrowInner___aEra3:hover .ControlSlider-module__arrowIcon___S4ztF path{fill:var(--arrow-hover-color)!important}.ControlSlider-module__arrowImg___2dwJW{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.ControlSlider-module__arrowIcon___S4ztF{width:100%;height:100%}.ControlSlider-module__arrowIcon___S4ztF path{transition:fill .15s ease-in-out}.ControlSlider-module__mirror___brd6U{transform:translate(-50%,-50%) scaleX(-1)!important}.ControlSlider-module__arrowVertical___tBfVN.ControlSlider-module__mirror___brd6U{transform:translate(-50%,-50%) scaleY(-1)!important}.ControlSlider-module__pagination___bicLF{position:absolute;z-index:1;border-radius:50%}.ControlSlider-module__paginationInner___bT-P-{display:flex;gap:calc(var(--is-editor, 0) * 1.1111111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.1111111111vw);padding-top:calc(var(--is-editor, 0) * .6944444444vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * .6944444444vw);padding-bottom:calc(var(--is-editor, 0) * .6944444444vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * .6944444444vw);padding-left:calc(var(--is-editor, 0) * 1.25vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.25vw);padding-right:calc(var(--is-editor, 0) * 1.25vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.25vw);border-radius:calc(var(--is-editor, 0) * 2.3611111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.3611111111vw)}.ControlSlider-module__paginationVertical___zYqKw{flex-direction:column}.ControlSlider-module__paginationItem___nTRbk{all:unset;flex-shrink:0;position:relative;width:calc(var(--is-editor, 0) * 1.1111111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.1111111111vw);height:calc(var(--is-editor, 0) * 1.1111111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.1111111111vw);cursor:pointer}.ControlSlider-module__paginationItem___nTRbk:hover .ControlSlider-module__dot___p1Qun{background-color:var(--pagination-hover-color)!important}.ControlSlider-module__dot___p1Qun{border-radius:50%;scale:.5;transition:background-color .3s ease-in-out,transform .3s ease-in-out;width:calc(var(--is-editor, 0) * 1.1111111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.1111111111vw);height:calc(var(--is-editor, 0) * 1.1111111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.1111111111vw)}.ControlSlider-module__activeDot___LHFaj{transform:scale(2)}.ControlSlider-module__paginationInsideBottom___R3FWn{bottom:0;left:50%;transform:translate(-50%)}.ControlSlider-module__paginationInsideTop___V-qb-{left:50%;transform:translate(-50%);top:0}.ControlSlider-module__paginationOutsideBottom___14w8D{left:50%;transform:translate(-50%);bottom:calc(var(--is-editor, 0) * -2.4305555556vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -2.4305555556vw)}.ControlSlider-module__paginationOutsideTop___SCLqB{left:50%;transform:translate(-50%);top:calc(var(--is-editor, 0) * -2.4305555556vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -2.4305555556vw)}.ControlSlider-module__paginationInsideLeft___yOBRZ{top:50%;transform:translateY(-50%);left:calc(var(--is-editor, 0) * -2.4305555556vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -2.4305555556vw)}.ControlSlider-module__paginationInsideRight___Rtt3o{top:50%;transform:translateY(-50%);right:calc(var(--is-editor, 0) * -2.4305555556vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -2.4305555556vw)}.ControlSlider-module__paginationOutsideLeft___lahaw{top:50%;transform:translateY(-50%);left:calc(var(--is-editor, 0) * -5.4861111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -5.4861111111vw)}.ControlSlider-module__paginationOutsideRight___EtuQa{top:50%;transform:translateY(-50%);right:calc(var(--is-editor, 0) * -5.4861111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -5.4861111111vw)}.ControlSlider-module__imgWrapper___UjEgB,.ControlSlider-module__wrapperInner___DLAWV{width:100%;height:100%}.ControlSlider-module__captionBlock___dJ6-j{pointer-events:none;position:absolute;top:0;z-index:1;left:0;right:0;bottom:0}.ControlSlider-module__captionTextWrapper___HFlpf{position:relative;width:100%;height:100%}.ControlSlider-module__captionText___uGBVc{pointer-events:none;max-width:100%;transition-property:opacity;transition-timing-function:ease-in-out;position:absolute;display:inline-block;white-space:pre-wrap;overflow-wrap:break-word;opacity:0}.ControlSlider-module__captionText___uGBVc.ControlSlider-module__active___WZK4G{opacity:1}.ControlSlider-module__withPointerEvents___t-18M{pointer-events:auto}.ControlSlider-module__absolute___KxmYB{position:absolute}.ControlSlider-module__topLeftAlignment___zjnGM{top:0;left:0}.ControlSlider-module__topCenterAlignment___gD1xW{top:0;left:50%;transform:translate(-50%)}.ControlSlider-module__topRightAlignment___NMapS{top:0;right:0}.ControlSlider-module__middleLeftAlignment___OnUrY{top:50%;transform:translateY(-50%);left:0}.ControlSlider-module__middleCenterAlignment___Tdkl0{top:50%;transform:translate(-50%,-50%);left:50%}.ControlSlider-module__middleRightAlignment___wEbfX{top:50%;transform:translateY(-50%);right:0}.ControlSlider-module__bottomLeftAlignment___cTP2-{bottom:0;left:0}.ControlSlider-module__bottomCenterAlignment___c54fB{bottom:0;left:50%;transform:translate(-50%)}.ControlSlider-module__bottomRightAlignment___kEwrz{bottom:0;right:0}.ControlSlider-module__clickOverlay___DZA28{position:absolute;top:0;left:0;width:100%;height:100%;cursor:pointer}.ControlSlider-module__contain___pLyq7{object-fit:contain}.ControlSlider-module__cover___KdDat{object-fit:cover}.RichTextRenderer-module__link___BWeZ2{color:inherit;cursor:pointer;pointer-events:auto;transition:color .2s ease}.RichTextRenderer-module__link___BWeZ2:hover{color:var(--link-hover-color)}.SvgImage-module__svg___q3xE-{width:100%;height:100%;color:transparent;display:inline-block;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);background-color:var(--fill);transition:background-color .2s;-webkit-mask:var(--svg) no-repeat center/contain;mask:var(--svg) no-repeat center/contain}.SvgImage-module__svg___q3xE-:hover{background-color:var(--hover-fill)}.SvgImage-module__img___VsTm-{width:100%;height:100%;object-fit:contain}.ImageRevealSlider-module__imageRevealSlider___UE5Ob{position:absolute;top:0;left:0;width:100%;height:100%;overflow:hidden}.ImageRevealSlider-module__image___Qjt-e{width:100%;height:100%;object-fit:cover;position:relative;-webkit-user-select:none;user-select:none;pointer-events:none}.ImageRevealSlider-module__link___N-iLG{width:100%;height:100%;display:block}.Lightbox-module__background___wf1Ii{position:absolute;z-index:9997;width:100%;height:100%;top:0;left:0}.Lightbox-module__backdropStyle___y7avj{position:fixed;top:0;left:0;right:0;bottom:0;width:100%;height:100%;z-index:9998}.Lightbox-module__editor___Vh82D{width:var(--cntrl-article-width)!important;margin-left:auto;margin-right:auto}.Lightbox-module__contentStyle___FzFaW{position:relative;width:100%;max-width:100vw;max-height:100vh;height:100vh;overflow:auto;background:transparent;box-sizing:border-box}.Lightbox-module__imageStyle___Qb7f5{position:relative;display:block;cursor:pointer;background-color:transparent;max-width:100%;max-height:100%;width:auto;height:auto}.Lightbox-module__imgWrapper___cdytV{position:relative;display:flex;width:100%;height:100%;overflow:hidden;box-sizing:border-box}.Lightbox-module__contain___5gATW{object-fit:contain;max-width:100%;max-height:100%}.Lightbox-module__cover___8HZy7{width:100%;height:100%;object-fit:cover}.Lightbox-module__caption___3e-22{z-index:9999;position:absolute;display:flex}.Lightbox-module__caption___3e-22:hover{color:var(--link-hover-color)!important}.Lightbox-module__captionBlock___7wXOq{pointer-events:none;position:absolute;top:0;z-index:1;left:0;right:0;bottom:0}.Lightbox-module__captionTextWrapper___uDnh6{position:relative;width:100%;height:100%}.Lightbox-module__captionText___6zbmg{pointer-events:none;max-width:100%;transition-property:opacity;transition-timing-function:ease-in-out;position:absolute;display:inline-block;white-space:pre-wrap;overflow-wrap:break-word;opacity:0}.Lightbox-module__captionText___6zbmg.Lightbox-module__active___u7Yu8{opacity:1}.Lightbox-module__lightboxSplide___yMC4v.splide,.Lightbox-module__lightboxSplide___yMC4v .splide__track{height:100%}.Lightbox-module__arrow___s3Bn2{position:absolute;display:flex;align-items:center;justify-content:center;cursor:pointer;border:none;background-color:transparent;top:50%;z-index:1;transform:translate(-50%,-50%);padding:0;left:calc(var(--is-editor, 0) * 1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.3888888889vw);width:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw);height:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw)}.Lightbox-module__arrow___s3Bn2.Lightbox-module__arrowVertical___6ztxz{left:50%;top:calc(var(--is-editor, 0) * 1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.3888888889vw);transform:translate(-50%,-50%)}.Lightbox-module__nextArrow___i23DU{left:unset;right:calc(var(--is-editor, 0) * 1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.3888888889vw);transform:translate(50%,-50%)}.Lightbox-module__nextArrow___i23DU.Lightbox-module__arrowVertical___6ztxz{left:50%;right:unset;top:unset;bottom:calc(var(--is-editor, 0) * 1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.3888888889vw);transform:translate(-50%,50%)}.Lightbox-module__arrowInner___Mm3xe{all:unset;cursor:pointer;width:100%;height:100%}.Lightbox-module__arrowInner___Mm3xe:hover .Lightbox-module__arrowIcon___UpzOt path{fill:var(--arrow-hover-color)!important}.Lightbox-module__arrowImg___UxHPR{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.Lightbox-module__mirror___50NCE{transform:translate(-50%,-50%) scaleX(-1)!important}.Lightbox-module__arrowVertical___6ztxz.Lightbox-module__mirror___50NCE{transform:translate(-50%,-50%) scaleY(-1)!important}.Lightbox-module__thumbsContainerVertical___lVaf-{flex-direction:column;display:flex}.Lightbox-module__thumbsContainer___DqOCP{position:absolute;display:flex;align-items:center;justify-content:center;pointer-events:auto}.Lightbox-module__thumbsAlignStart___uiFIV{align-items:flex-start}.Lightbox-module__thumbsAlignCenter___sbUPA{align-items:center}.Lightbox-module__thumbsAlignEnd___OA9N4{align-items:flex-end}.Lightbox-module__thumbItem___zROyu{all:unset;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;overflow:hidden;transition:transform .1s ease,opacity .1s ease}.Lightbox-module__thumbItem___zROyu:hover{opacity:var(--thumb-hover)!important}.Lightbox-module__closeButton___r3Dur{all:unset;cursor:pointer;position:absolute;width:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw);height:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw)}@keyframes Lightbox-module__lbFadeIn___3xoHQ{0%{opacity:0}to{opacity:1}}.Lightbox-module__fadeIn___sHwRK{animation-name:Lightbox-module__lbFadeIn___3xoHQ}@keyframes Lightbox-module__lbSlideInLeft___vgE9-{0%{transform:translate(-100%)}to{transform:translate(0)}}@keyframes Lightbox-module__lbSlideInRight___nByIA{0%{transform:translate(100%)}to{transform:translate(0)}}@keyframes Lightbox-module__lbSlideInTop___hI5ju{0%{transform:translateY(-100%)}to{transform:translateY(0)}}@keyframes Lightbox-module__lbSlideInBottom___M6-9o{0%{transform:translateY(100%)}to{transform:translateY(0)}}.Lightbox-module__slideInLeft___P-XRo{animation-name:Lightbox-module__lbSlideInLeft___vgE9-}.Lightbox-module__slideInRight___ZQqFi{animation-name:Lightbox-module__lbSlideInRight___nByIA}.Lightbox-module__slideInTop___XRKCs{animation-name:Lightbox-module__lbSlideInTop___hI5ju}.Lightbox-module__slideInBottom___TYOBS{animation-name:Lightbox-module__lbSlideInBottom___M6-9o}.Lightbox-module__lightboxSplide___yMC4v.splide--fade .Lightbox-module__scaleSlide___wS7d4{opacity:0!important;transform:var(--position-transform, none) scale(.9)!important;transition:opacity var(--splide-speed, .5s) ease,transform var(--splide-speed, .5s) ease!important}.Lightbox-module__lightboxSplide___yMC4v.splide--fade .splide__slide.is-active .Lightbox-module__scaleSlide___wS7d4{opacity:1!important;transform:var(--position-transform, none) scale(1)!important}.Lightbox-module__lightboxSplide___yMC4v.splide--fade .splide__slide:not(.is-active) .Lightbox-module__scaleSlide___wS7d4{opacity:0!important;transform:var(--position-transform, none) scale(1.1)!important}.splide__container{box-sizing:border-box;position:relative}.splide__list{backface-visibility:hidden;display:-ms-flexbox;display:flex;height:100%;margin:0!important;padding:0!important}.splide.is-initialized:not(.is-active) .splide__list{display:block}.splide__pagination{-ms-flex-align:center;align-items:center;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;-ms-flex-pack:center;justify-content:center;margin:0;pointer-events:none}.splide__pagination li{display:inline-block;line-height:1;list-style-type:none;margin:0;pointer-events:auto}.splide:not(.is-overflow) .splide__pagination{display:none}.splide__progress__bar{width:0}.splide{position:relative;visibility:hidden}.splide.is-initialized,.splide.is-rendered{visibility:visible}.splide__slide{backface-visibility:hidden;box-sizing:border-box;-ms-flex-negative:0;flex-shrink:0;list-style-type:none!important;margin:0;position:relative}.splide__slide img{vertical-align:bottom}.splide__spinner{animation:splide-loading 1s linear infinite;border:2px solid #999;border-left-color:transparent;border-radius:50%;bottom:0;contain:strict;display:inline-block;height:20px;left:0;margin:auto;position:absolute;right:0;top:0;width:20px}.splide__sr{clip:rect(0 0 0 0);border:0;height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px}.splide__toggle.is-active .splide__toggle__play,.splide__toggle__pause{display:none}.splide__toggle.is-active .splide__toggle__pause{display:inline}.splide__track{overflow:hidden;position:relative;z-index:0}@keyframes splide-loading{0%{transform:rotate(0)}to{transform:rotate(1turn)}}.splide__track--draggable{-webkit-touch-callout:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.splide__track--fade>.splide__list>.splide__slide{margin:0!important;opacity:0;z-index:0}.splide__track--fade>.splide__list>.splide__slide.is-active{opacity:1;z-index:1}.splide--rtl{direction:rtl}.splide__track--ttb>.splide__list{display:block}.splide__arrow{-ms-flex-align:center;align-items:center;background:#ccc;border:0;border-radius:50%;cursor:pointer;display:-ms-flexbox;display:flex;height:2em;-ms-flex-pack:center;justify-content:center;opacity:.7;padding:0;position:absolute;top:50%;transform:translateY(-50%);width:2em;z-index:1}.splide__arrow svg{fill:#000;height:1.2em;width:1.2em}.splide__arrow:hover:not(:disabled){opacity:.9}.splide__arrow:disabled{opacity:.3}.splide__arrow:focus-visible{outline:3px solid #0bf;outline-offset:3px}.splide__arrow--prev{left:1em}.splide__arrow--prev svg{transform:scaleX(-1)}.splide__arrow--next{right:1em}.splide.is-focus-in .splide__arrow:focus{outline:3px solid #0bf;outline-offset:3px}.splide__pagination{bottom:.5em;left:0;padding:0 1em;position:absolute;right:0;z-index:1}.splide__pagination__page{background:#ccc;border:0;border-radius:50%;display:inline-block;height:8px;margin:3px;opacity:.7;padding:0;position:relative;transition:transform .2s linear;width:8px}.splide__pagination__page.is-active{background:#fff;transform:scale(1.4);z-index:1}.splide__pagination__page:hover{cursor:pointer;opacity:.9}.splide__pagination__page:focus-visible{outline:3px solid #0bf;outline-offset:3px}.splide.is-focus-in .splide__pagination__page:focus{outline:3px solid #0bf;outline-offset:3px}.splide__progress__bar{background:#ccc;height:3px}.splide__slide{-webkit-tap-highlight-color:rgba(0,0,0,0)}.splide__slide:focus{outline:0}@supports (outline-offset:-3px){.splide__slide:focus-visible{outline:3px solid #0bf;outline-offset:-3px}}@media screen and (-ms-high-contrast:none){.splide__slide:focus-visible{border:3px solid #0bf}}@supports (outline-offset:-3px){.splide.is-focus-in .splide__slide:focus{outline:3px solid #0bf;outline-offset:-3px}}@media screen and (-ms-high-contrast:none){.splide.is-focus-in .splide__slide:focus{border:3px solid #0bf}.splide.is-focus-in .splide__track>.splide__list>.splide__slide:focus{border-color:#0bf}}.splide__toggle{cursor:pointer}.splide__toggle:focus-visible{outline:3px solid #0bf;outline-offset:3px}.splide.is-focus-in .splide__toggle:focus{outline:3px solid #0bf;outline-offset:3px}.splide__track--nav>.splide__list>.splide__slide{border:3px solid transparent;cursor:pointer}.splide__track--nav>.splide__list>.splide__slide.is-active{border:3px solid #000}.splide__arrows--rtl .splide__arrow--prev{left:auto;right:1em}.splide__arrows--rtl .splide__arrow--prev svg{transform:scaleX(1)}.splide__arrows--rtl .splide__arrow--next{left:1em;right:auto}.splide__arrows--rtl .splide__arrow--next svg{transform:scaleX(-1)}.splide__arrows--ttb .splide__arrow{left:50%;transform:translate(-50%)}.splide__arrows--ttb .splide__arrow--prev{top:1em}.splide__arrows--ttb .splide__arrow--prev svg{transform:rotate(-90deg)}.splide__arrows--ttb .splide__arrow--next{bottom:1em;top:auto}.splide__arrows--ttb .splide__arrow--next svg{transform:rotate(90deg)}.splide__pagination--ttb{bottom:0;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;left:auto;padding:1em 0;right:.5em;top:0}
|
|
1
|
+
.ControlSlider-module__wrapper___sHEkd{position:relative;width:100%;height:100%}.ControlSlider-module__slider___R3i9-{width:100%;height:100%}.ControlSlider-module__sliderItems___1MgPL{display:flex;overflow:hidden;width:100%;height:100%;transition:transform .3s ease-in-out}.ControlSlider-module__sliderItem___QQSkR{width:100%;height:100%;display:flex;position:relative}.ControlSlider-module__sliderImage___9hRl-{width:100%;height:100%;object-fit:cover}.ControlSlider-module__arrow___05ghY{position:absolute;display:flex;align-items:center;justify-content:center;border:none;background-color:transparent;top:50%;left:calc(var(--is-editor, 0) * -1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -1.3888888889vw);z-index:1;transform:translate(-50%,-50%);padding:0;width:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw);height:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw)}.ControlSlider-module__arrow___05ghY.ControlSlider-module__arrowVertical___tBfVN{left:50%;top:calc(var(--is-editor, 0) * -1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -1.3888888889vw);transform:translate(-50%,-50%)}.ControlSlider-module__nextArrow___-30Yc{left:unset;right:calc(var(--is-editor, 0) * -1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -1.3888888889vw);transform:translate(50%,-50%)}.ControlSlider-module__nextArrow___-30Yc.ControlSlider-module__arrowVertical___tBfVN{left:50%;right:unset;top:unset;bottom:calc(var(--is-editor, 0) * -1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -1.3888888889vw);transform:translate(-50%,50%)}.ControlSlider-module__arrowInner___aEra3{all:unset;cursor:pointer;width:100%;height:100%}.ControlSlider-module__arrowInner___aEra3:hover .ControlSlider-module__arrowIcon___S4ztF path{fill:var(--arrow-hover-color)!important}.ControlSlider-module__arrowImg___2dwJW{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.ControlSlider-module__arrowIcon___S4ztF{width:100%;height:100%}.ControlSlider-module__arrowIcon___S4ztF path{transition:fill .15s ease-in-out}.ControlSlider-module__mirror___brd6U{transform:translate(-50%,-50%) scaleX(-1)!important}.ControlSlider-module__arrowVertical___tBfVN.ControlSlider-module__mirror___brd6U{transform:translate(-50%,-50%) scaleY(-1)!important}.ControlSlider-module__pagination___bicLF{position:absolute;z-index:1;border-radius:50%}.ControlSlider-module__paginationInner___bT-P-{display:flex;gap:calc(var(--is-editor, 0) * 1.1111111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.1111111111vw);padding-top:calc(var(--is-editor, 0) * .6944444444vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * .6944444444vw);padding-bottom:calc(var(--is-editor, 0) * .6944444444vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * .6944444444vw);padding-left:calc(var(--is-editor, 0) * 1.25vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.25vw);padding-right:calc(var(--is-editor, 0) * 1.25vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.25vw);border-radius:calc(var(--is-editor, 0) * 2.3611111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.3611111111vw)}.ControlSlider-module__paginationVertical___zYqKw{flex-direction:column}.ControlSlider-module__paginationItem___nTRbk{all:unset;flex-shrink:0;position:relative;width:calc(var(--is-editor, 0) * 1.1111111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.1111111111vw);height:calc(var(--is-editor, 0) * 1.1111111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.1111111111vw);cursor:pointer}.ControlSlider-module__paginationItem___nTRbk:hover .ControlSlider-module__dot___p1Qun{background-color:var(--pagination-hover-color)!important}.ControlSlider-module__dot___p1Qun{border-radius:50%;scale:.5;transition:background-color .3s ease-in-out,transform .3s ease-in-out;width:calc(var(--is-editor, 0) * 1.1111111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.1111111111vw);height:calc(var(--is-editor, 0) * 1.1111111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.1111111111vw)}.ControlSlider-module__activeDot___LHFaj{transform:scale(2)}.ControlSlider-module__paginationInsideBottom___R3FWn{bottom:0;left:50%;transform:translate(-50%)}.ControlSlider-module__paginationInsideTop___V-qb-{left:50%;transform:translate(-50%);top:0}.ControlSlider-module__paginationOutsideBottom___14w8D{left:50%;transform:translate(-50%);bottom:calc(var(--is-editor, 0) * -2.4305555556vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -2.4305555556vw)}.ControlSlider-module__paginationOutsideTop___SCLqB{left:50%;transform:translate(-50%);top:calc(var(--is-editor, 0) * -2.4305555556vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -2.4305555556vw)}.ControlSlider-module__paginationInsideLeft___yOBRZ{top:50%;transform:translateY(-50%);left:calc(var(--is-editor, 0) * -2.4305555556vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -2.4305555556vw)}.ControlSlider-module__paginationInsideRight___Rtt3o{top:50%;transform:translateY(-50%);right:calc(var(--is-editor, 0) * -2.4305555556vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -2.4305555556vw)}.ControlSlider-module__paginationOutsideLeft___lahaw{top:50%;transform:translateY(-50%);left:calc(var(--is-editor, 0) * -5.4861111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -5.4861111111vw)}.ControlSlider-module__paginationOutsideRight___EtuQa{top:50%;transform:translateY(-50%);right:calc(var(--is-editor, 0) * -5.4861111111vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * -5.4861111111vw)}.ControlSlider-module__imgWrapper___UjEgB,.ControlSlider-module__wrapperInner___DLAWV{width:100%;height:100%}.ControlSlider-module__captionBlock___dJ6-j{pointer-events:none;position:absolute;top:0;z-index:1;left:0;right:0;bottom:0}.ControlSlider-module__captionTextWrapper___HFlpf{position:relative;width:100%;height:100%}.ControlSlider-module__captionText___uGBVc{pointer-events:none;max-width:100%;transition-property:opacity;transition-timing-function:ease-in-out;position:absolute;display:inline-block;white-space:pre-wrap;overflow-wrap:break-word;opacity:0}.ControlSlider-module__captionText___uGBVc.ControlSlider-module__active___WZK4G{opacity:1}.ControlSlider-module__withPointerEvents___t-18M{pointer-events:auto}.ControlSlider-module__absolute___KxmYB{position:absolute}.ControlSlider-module__topLeftAlignment___zjnGM{top:0;left:0}.ControlSlider-module__topCenterAlignment___gD1xW{top:0;left:50%;transform:translate(-50%)}.ControlSlider-module__topRightAlignment___NMapS{top:0;right:0}.ControlSlider-module__middleLeftAlignment___OnUrY{top:50%;transform:translateY(-50%);left:0}.ControlSlider-module__middleCenterAlignment___Tdkl0{top:50%;transform:translate(-50%,-50%);left:50%}.ControlSlider-module__middleRightAlignment___wEbfX{top:50%;transform:translateY(-50%);right:0}.ControlSlider-module__bottomLeftAlignment___cTP2-{bottom:0;left:0}.ControlSlider-module__bottomCenterAlignment___c54fB{bottom:0;left:50%;transform:translate(-50%)}.ControlSlider-module__bottomRightAlignment___kEwrz{bottom:0;right:0}.ControlSlider-module__clickOverlay___DZA28{position:absolute;top:0;left:0;width:100%;height:100%;cursor:pointer}.ControlSlider-module__contain___pLyq7{object-fit:contain}.ControlSlider-module__cover___KdDat{object-fit:cover}.RichTextRenderer-module__link___BWeZ2{color:inherit;cursor:pointer;pointer-events:auto;transition:color .2s ease}.RichTextRenderer-module__link___BWeZ2:hover{color:var(--link-hover-color)}.SvgImage-module__svg___q3xE-{width:100%;height:100%;color:transparent;display:inline-block;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);background-color:var(--fill);transition:background-color .2s;-webkit-mask:var(--svg) no-repeat center/contain;mask:var(--svg) no-repeat center/contain}.SvgImage-module__svg___q3xE-:hover{background-color:var(--hover-fill)}.SvgImage-module__img___VsTm-{width:100%;height:100%;object-fit:contain}.ImageRevealSlider-module__imageRevealSlider___UE5Ob{position:absolute;top:0;left:0;width:100%;height:100%;overflow:hidden}.ImageRevealSlider-module__image___Qjt-e{width:100%;height:100%;object-fit:cover;position:relative;-webkit-user-select:none;user-select:none;pointer-events:none}.ImageRevealSlider-module__link___N-iLG{width:100%;height:100%;display:block}.Lightbox-module__background___wf1Ii{position:absolute;z-index:9997;width:100%;height:100%;top:0;left:0}.Lightbox-module__backdropStyle___y7avj{position:fixed;top:0;left:0;right:0;bottom:0;width:100%;height:100%;z-index:9998}.Lightbox-module__editor___Vh82D{width:var(--cntrl-article-width)!important;margin-left:auto;margin-right:auto}.Lightbox-module__contentStyle___FzFaW{position:relative;width:100%;max-width:100vw;max-height:100vh;height:100vh;overflow:auto;background:transparent;box-sizing:border-box}.Lightbox-module__imageStyle___Qb7f5{position:relative;display:block;cursor:pointer;background-color:transparent;max-width:100%;max-height:100%;width:auto;height:auto}.Lightbox-module__imgWrapper___cdytV{position:relative;display:flex;width:100%;height:100%;overflow:hidden;box-sizing:border-box}.Lightbox-module__contain___5gATW{object-fit:contain;max-width:100%;max-height:100%}.Lightbox-module__cover___8HZy7{width:100%;height:100%;object-fit:cover}.Lightbox-module__caption___3e-22{z-index:9999;position:absolute;display:flex}.Lightbox-module__caption___3e-22:hover{color:var(--link-hover-color)!important}.Lightbox-module__captionBlock___7wXOq{pointer-events:none;position:absolute;top:0;z-index:1;left:0;right:0;bottom:0}.Lightbox-module__captionTextWrapper___uDnh6{position:relative;width:100%;height:100%}.Lightbox-module__captionText___6zbmg{pointer-events:none;max-width:100%;transition-property:opacity;transition-timing-function:ease-in-out;position:absolute;display:inline-block;white-space:pre-wrap;overflow-wrap:break-word;opacity:0}.Lightbox-module__captionText___6zbmg.Lightbox-module__active___u7Yu8{opacity:1}.Lightbox-module__lightboxSplide___yMC4v.splide,.Lightbox-module__lightboxSplide___yMC4v .splide__track{height:100%}.Lightbox-module__arrow___s3Bn2{position:absolute;display:flex;align-items:center;justify-content:center;cursor:pointer;border:none;background-color:transparent;top:50%;z-index:1;transform:translate(-50%,-50%);padding:0;left:calc(var(--is-editor, 0) * 1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.3888888889vw);width:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw);height:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw)}.Lightbox-module__arrow___s3Bn2.Lightbox-module__arrowVertical___6ztxz{left:50%;top:calc(var(--is-editor, 0) * 1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.3888888889vw);transform:translate(-50%,-50%)}.Lightbox-module__nextArrow___i23DU{left:unset;right:calc(var(--is-editor, 0) * 1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.3888888889vw);transform:translate(50%,-50%)}.Lightbox-module__nextArrow___i23DU.Lightbox-module__arrowVertical___6ztxz{left:50%;right:unset;top:unset;bottom:calc(var(--is-editor, 0) * 1.3888888889vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 1.3888888889vw);transform:translate(-50%,50%)}.Lightbox-module__arrowInner___Mm3xe{all:unset;cursor:pointer;width:100%;height:100%}.Lightbox-module__arrowInner___Mm3xe:hover .Lightbox-module__arrowIcon___UpzOt path{fill:var(--arrow-hover-color)!important}.Lightbox-module__arrowImg___UxHPR{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.Lightbox-module__mirror___50NCE{transform:translate(-50%,-50%) scaleX(-1)!important}.Lightbox-module__arrowVertical___6ztxz.Lightbox-module__mirror___50NCE{transform:translate(-50%,-50%) scaleY(-1)!important}.Lightbox-module__thumbsContainerVertical___lVaf-{flex-direction:column;display:flex}.Lightbox-module__thumbsContainer___DqOCP{position:absolute;display:flex;align-items:center;justify-content:center;pointer-events:auto}.Lightbox-module__thumbsAlignStart___uiFIV{align-items:flex-start}.Lightbox-module__thumbsAlignCenter___sbUPA{align-items:center}.Lightbox-module__thumbsAlignEnd___OA9N4{align-items:flex-end}.Lightbox-module__thumbItem___zROyu{all:unset;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;overflow:hidden;transition:transform .1s ease,opacity .1s ease}.Lightbox-module__thumbItem___zROyu:hover{opacity:var(--thumb-hover)!important}.Lightbox-module__closeButton___r3Dur{all:unset;cursor:pointer;position:absolute;width:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw);height:calc(var(--is-editor, 0) * 2.0833333333vw / var(--cntrl-reverse-layout-deviation, 1) + (1 - var(--is-editor, 0)) * 2.0833333333vw)}@keyframes Lightbox-module__lbFadeIn___3xoHQ{0%{opacity:0}to{opacity:1}}.Lightbox-module__fadeIn___sHwRK{animation-name:Lightbox-module__lbFadeIn___3xoHQ}@keyframes Lightbox-module__lbSlideInLeft___vgE9-{0%{transform:translate(-100%)}to{transform:translate(0)}}@keyframes Lightbox-module__lbSlideInRight___nByIA{0%{transform:translate(100%)}to{transform:translate(0)}}@keyframes Lightbox-module__lbSlideInTop___hI5ju{0%{transform:translateY(-100%)}to{transform:translateY(0)}}@keyframes Lightbox-module__lbSlideInBottom___M6-9o{0%{transform:translateY(100%)}to{transform:translateY(0)}}.Lightbox-module__slideInLeft___P-XRo{animation-name:Lightbox-module__lbSlideInLeft___vgE9-}.Lightbox-module__slideInRight___ZQqFi{animation-name:Lightbox-module__lbSlideInRight___nByIA}.Lightbox-module__slideInTop___XRKCs{animation-name:Lightbox-module__lbSlideInTop___hI5ju}.Lightbox-module__slideInBottom___TYOBS{animation-name:Lightbox-module__lbSlideInBottom___M6-9o}@keyframes Lightbox-module__lbFadeOut___0pD7Q{0%{opacity:1}to{opacity:0}}.Lightbox-module__fadeOut___h2fpQ{animation-name:Lightbox-module__lbFadeOut___0pD7Q!important}@keyframes Lightbox-module__lbSlideOutLeft___Z6pdg{0%{transform:translate(0)}to{transform:translate(-100%)}}@keyframes Lightbox-module__lbSlideOutRight___B5cYY{0%{transform:translate(0)}to{transform:translate(100%)}}@keyframes Lightbox-module__lbSlideOutTop___uZ10i{0%{transform:translateY(0)}to{transform:translateY(-100%)}}@keyframes Lightbox-module__lbSlideOutBottom___GyYfC{0%{transform:translateY(0)}to{transform:translateY(100%)}}.Lightbox-module__slideOutLeft___J-eMU{animation-name:Lightbox-module__lbSlideOutLeft___Z6pdg!important}.Lightbox-module__slideOutRight___iZUQz{animation-name:Lightbox-module__lbSlideOutRight___B5cYY!important}.Lightbox-module__slideOutTop___3TXF9{animation-name:Lightbox-module__lbSlideOutTop___uZ10i!important}.Lightbox-module__slideOutBottom___SB5ws{animation-name:Lightbox-module__lbSlideOutBottom___GyYfC!important}.Lightbox-module__lightboxSplide___yMC4v.splide--fade .Lightbox-module__scaleSlide___wS7d4{opacity:0!important;transform:var(--position-transform, none) scale(.9)!important;transition:opacity var(--splide-speed, .5s) ease,transform var(--splide-speed, .5s) ease!important}.Lightbox-module__lightboxSplide___yMC4v.splide--fade .splide__slide.is-active .Lightbox-module__scaleSlide___wS7d4{opacity:1!important;transform:var(--position-transform, none) scale(1)!important}.Lightbox-module__lightboxSplide___yMC4v.splide--fade .splide__slide:not(.is-active) .Lightbox-module__scaleSlide___wS7d4{opacity:0!important;transform:var(--position-transform, none) scale(1.1)!important}.splide__container{box-sizing:border-box;position:relative}.splide__list{backface-visibility:hidden;display:-ms-flexbox;display:flex;height:100%;margin:0!important;padding:0!important}.splide.is-initialized:not(.is-active) .splide__list{display:block}.splide__pagination{-ms-flex-align:center;align-items:center;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;-ms-flex-pack:center;justify-content:center;margin:0;pointer-events:none}.splide__pagination li{display:inline-block;line-height:1;list-style-type:none;margin:0;pointer-events:auto}.splide:not(.is-overflow) .splide__pagination{display:none}.splide__progress__bar{width:0}.splide{position:relative;visibility:hidden}.splide.is-initialized,.splide.is-rendered{visibility:visible}.splide__slide{backface-visibility:hidden;box-sizing:border-box;-ms-flex-negative:0;flex-shrink:0;list-style-type:none!important;margin:0;position:relative}.splide__slide img{vertical-align:bottom}.splide__spinner{animation:splide-loading 1s linear infinite;border:2px solid #999;border-left-color:transparent;border-radius:50%;bottom:0;contain:strict;display:inline-block;height:20px;left:0;margin:auto;position:absolute;right:0;top:0;width:20px}.splide__sr{clip:rect(0 0 0 0);border:0;height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px}.splide__toggle.is-active .splide__toggle__play,.splide__toggle__pause{display:none}.splide__toggle.is-active .splide__toggle__pause{display:inline}.splide__track{overflow:hidden;position:relative;z-index:0}@keyframes splide-loading{0%{transform:rotate(0)}to{transform:rotate(1turn)}}.splide__track--draggable{-webkit-touch-callout:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.splide__track--fade>.splide__list>.splide__slide{margin:0!important;opacity:0;z-index:0}.splide__track--fade>.splide__list>.splide__slide.is-active{opacity:1;z-index:1}.splide--rtl{direction:rtl}.splide__track--ttb>.splide__list{display:block}.splide__arrow{-ms-flex-align:center;align-items:center;background:#ccc;border:0;border-radius:50%;cursor:pointer;display:-ms-flexbox;display:flex;height:2em;-ms-flex-pack:center;justify-content:center;opacity:.7;padding:0;position:absolute;top:50%;transform:translateY(-50%);width:2em;z-index:1}.splide__arrow svg{fill:#000;height:1.2em;width:1.2em}.splide__arrow:hover:not(:disabled){opacity:.9}.splide__arrow:disabled{opacity:.3}.splide__arrow:focus-visible{outline:3px solid #0bf;outline-offset:3px}.splide__arrow--prev{left:1em}.splide__arrow--prev svg{transform:scaleX(-1)}.splide__arrow--next{right:1em}.splide.is-focus-in .splide__arrow:focus{outline:3px solid #0bf;outline-offset:3px}.splide__pagination{bottom:.5em;left:0;padding:0 1em;position:absolute;right:0;z-index:1}.splide__pagination__page{background:#ccc;border:0;border-radius:50%;display:inline-block;height:8px;margin:3px;opacity:.7;padding:0;position:relative;transition:transform .2s linear;width:8px}.splide__pagination__page.is-active{background:#fff;transform:scale(1.4);z-index:1}.splide__pagination__page:hover{cursor:pointer;opacity:.9}.splide__pagination__page:focus-visible{outline:3px solid #0bf;outline-offset:3px}.splide.is-focus-in .splide__pagination__page:focus{outline:3px solid #0bf;outline-offset:3px}.splide__progress__bar{background:#ccc;height:3px}.splide__slide{-webkit-tap-highlight-color:rgba(0,0,0,0)}.splide__slide:focus{outline:0}@supports (outline-offset:-3px){.splide__slide:focus-visible{outline:3px solid #0bf;outline-offset:-3px}}@media screen and (-ms-high-contrast:none){.splide__slide:focus-visible{border:3px solid #0bf}}@supports (outline-offset:-3px){.splide.is-focus-in .splide__slide:focus{outline:3px solid #0bf;outline-offset:-3px}}@media screen and (-ms-high-contrast:none){.splide.is-focus-in .splide__slide:focus{border:3px solid #0bf}.splide.is-focus-in .splide__track>.splide__list>.splide__slide:focus{border-color:#0bf}}.splide__toggle{cursor:pointer}.splide__toggle:focus-visible{outline:3px solid #0bf;outline-offset:3px}.splide.is-focus-in .splide__toggle:focus{outline:3px solid #0bf;outline-offset:3px}.splide__track--nav>.splide__list>.splide__slide{border:3px solid transparent;cursor:pointer}.splide__track--nav>.splide__list>.splide__slide.is-active{border:3px solid #000}.splide__arrows--rtl .splide__arrow--prev{left:auto;right:1em}.splide__arrows--rtl .splide__arrow--prev svg{transform:scaleX(1)}.splide__arrows--rtl .splide__arrow--next{left:1em;right:auto}.splide__arrows--rtl .splide__arrow--next svg{transform:scaleX(-1)}.splide__arrows--ttb .splide__arrow{left:50%;transform:translate(-50%)}.splide__arrows--ttb .splide__arrow--prev{top:1em}.splide__arrows--ttb .splide__arrow--prev svg{transform:rotate(-90deg)}.splide__arrows--ttb .splide__arrow--next{bottom:1em;top:auto}.splide__arrows--ttb .splide__arrow--next svg{transform:rotate(90deg)}.splide__pagination--ttb{bottom:0;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;left:auto;padding:1em 0;right:.5em;top:0}
|
package/dist/index.js
CHANGED
|
@@ -1509,6 +1509,11 @@ const slideInLeft = "Lightbox-module__slideInLeft___P-XRo";
|
|
|
1509
1509
|
const slideInRight = "Lightbox-module__slideInRight___ZQqFi";
|
|
1510
1510
|
const slideInTop = "Lightbox-module__slideInTop___XRKCs";
|
|
1511
1511
|
const slideInBottom = "Lightbox-module__slideInBottom___TYOBS";
|
|
1512
|
+
const fadeOut = "Lightbox-module__fadeOut___h2fpQ";
|
|
1513
|
+
const slideOutLeft = "Lightbox-module__slideOutLeft___J-eMU";
|
|
1514
|
+
const slideOutRight = "Lightbox-module__slideOutRight___iZUQz";
|
|
1515
|
+
const slideOutTop = "Lightbox-module__slideOutTop___3TXF9";
|
|
1516
|
+
const slideOutBottom = "Lightbox-module__slideOutBottom___SB5ws";
|
|
1512
1517
|
const scaleSlide = "Lightbox-module__scaleSlide___wS7d4";
|
|
1513
1518
|
const styles = {
|
|
1514
1519
|
background,
|
|
@@ -1539,6 +1544,11 @@ const styles = {
|
|
|
1539
1544
|
slideInRight,
|
|
1540
1545
|
slideInTop,
|
|
1541
1546
|
slideInBottom,
|
|
1547
|
+
fadeOut,
|
|
1548
|
+
slideOutLeft,
|
|
1549
|
+
slideOutRight,
|
|
1550
|
+
slideOutTop,
|
|
1551
|
+
slideOutBottom,
|
|
1542
1552
|
scaleSlide
|
|
1543
1553
|
};
|
|
1544
1554
|
const getPositionStyles = (position, offset, isEditor) => {
|
|
@@ -1628,21 +1638,48 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1628
1638
|
const { widthSettings, fontSettings, letterSpacing, textAlign, wordSpacing, fontSizeLineHeight, textAppearance, color } = lightboxStyles.caption;
|
|
1629
1639
|
const [currentIndex, setCurrentIndex] = React.useState(0);
|
|
1630
1640
|
const [splideKey, setSplideKey] = React.useState(0);
|
|
1641
|
+
const [isClosing, setIsClosing] = React.useState(false);
|
|
1631
1642
|
const lightboxRef = React.useRef(null);
|
|
1632
1643
|
const prevSliderTypeRef = React.useRef(null);
|
|
1633
1644
|
const imageRef = React.useRef(null);
|
|
1634
1645
|
const isClosingRef = React.useRef(false);
|
|
1646
|
+
const contentRef = React.useRef(null);
|
|
1647
|
+
const animationEndHandlerRef = React.useRef(null);
|
|
1635
1648
|
const { appear, triggers, slider, thumbnail, controls, area, caption: caption2, layout } = settings.lightboxBlock;
|
|
1649
|
+
const appearDurationMs = appear.duration ? parseInt(appear.duration) : 300;
|
|
1650
|
+
const handleClose = React.useCallback(() => {
|
|
1651
|
+
setIsClosing(true);
|
|
1652
|
+
isClosingRef.current = true;
|
|
1653
|
+
const handleAnimationEnd = (e) => {
|
|
1654
|
+
if (e.target === contentRef.current && e.animationName) {
|
|
1655
|
+
if (contentRef.current && animationEndHandlerRef.current) {
|
|
1656
|
+
contentRef.current.removeEventListener("animationend", animationEndHandlerRef.current);
|
|
1657
|
+
}
|
|
1658
|
+
animationEndHandlerRef.current = null;
|
|
1659
|
+
onClose();
|
|
1660
|
+
setIsClosing(false);
|
|
1661
|
+
}
|
|
1662
|
+
};
|
|
1663
|
+
if (contentRef.current) {
|
|
1664
|
+
animationEndHandlerRef.current = handleAnimationEnd;
|
|
1665
|
+
contentRef.current.addEventListener("animationend", handleAnimationEnd);
|
|
1666
|
+
} else {
|
|
1667
|
+
setTimeout(() => {
|
|
1668
|
+
onClose();
|
|
1669
|
+
setIsClosing(false);
|
|
1670
|
+
}, appearDurationMs);
|
|
1671
|
+
}
|
|
1672
|
+
}, [onClose, appearDurationMs]);
|
|
1636
1673
|
const handleBackdropClick = (e) => {
|
|
1637
1674
|
if (!closeOnBackdropClick) return;
|
|
1638
1675
|
if (e.target === e.currentTarget) {
|
|
1639
|
-
|
|
1676
|
+
handleClose();
|
|
1640
1677
|
}
|
|
1641
1678
|
};
|
|
1642
1679
|
const handleImageWrapperClick = (e) => {
|
|
1643
1680
|
if (!closeOnBackdropClick) return;
|
|
1644
1681
|
if (e.target === e.currentTarget) {
|
|
1645
|
-
|
|
1682
|
+
handleClose();
|
|
1646
1683
|
}
|
|
1647
1684
|
};
|
|
1648
1685
|
const handleContentClick = (e) => {
|
|
@@ -1650,7 +1687,7 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1650
1687
|
const target = e.target;
|
|
1651
1688
|
const currentTarget = e.currentTarget;
|
|
1652
1689
|
if (target === currentTarget) {
|
|
1653
|
-
|
|
1690
|
+
handleClose();
|
|
1654
1691
|
return;
|
|
1655
1692
|
}
|
|
1656
1693
|
const isImg = target.tagName === "IMG" || target.closest("img");
|
|
@@ -1659,17 +1696,16 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1659
1696
|
const isCaption = target.closest(`.${styles.caption}`);
|
|
1660
1697
|
const isThumbnail = target.closest(`.${styles.thumbsContainer}`);
|
|
1661
1698
|
if (!isImg && !isButton && !isSplide && !isCaption && !isThumbnail) {
|
|
1662
|
-
|
|
1699
|
+
handleClose();
|
|
1663
1700
|
}
|
|
1664
1701
|
};
|
|
1665
1702
|
const onImageClick = (e) => {
|
|
1666
1703
|
var _a, _b;
|
|
1704
|
+
e.stopPropagation();
|
|
1667
1705
|
if (triggers.type === "click" && triggers.switch === "image") {
|
|
1668
|
-
e.stopPropagation();
|
|
1669
1706
|
(_a = lightboxRef.current) == null ? void 0 : _a.go("+1");
|
|
1670
1707
|
}
|
|
1671
1708
|
if (triggers.type === "click" && triggers.switch === "50/50") {
|
|
1672
|
-
e.stopPropagation();
|
|
1673
1709
|
const img2 = e.currentTarget;
|
|
1674
1710
|
const rect = img2.getBoundingClientRect();
|
|
1675
1711
|
const clickX = e.clientX - rect.left;
|
|
@@ -1689,7 +1725,7 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1689
1725
|
if (!isOpen || !closeOnEsc) return;
|
|
1690
1726
|
const onKeyDown = (event) => {
|
|
1691
1727
|
if (event.key === "Escape") {
|
|
1692
|
-
|
|
1728
|
+
handleClose();
|
|
1693
1729
|
return;
|
|
1694
1730
|
}
|
|
1695
1731
|
if (event.key === "ArrowRight") {
|
|
@@ -1704,12 +1740,19 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1704
1740
|
return () => {
|
|
1705
1741
|
window.removeEventListener("keydown", onKeyDown);
|
|
1706
1742
|
};
|
|
1707
|
-
}, [isOpen, closeOnEsc,
|
|
1743
|
+
}, [isOpen, closeOnEsc, handleClose, content.length]);
|
|
1708
1744
|
React.useEffect(() => {
|
|
1709
1745
|
if (isOpen) {
|
|
1710
1746
|
setCurrentIndex(0);
|
|
1711
1747
|
isClosingRef.current = false;
|
|
1748
|
+
setIsClosing(false);
|
|
1712
1749
|
}
|
|
1750
|
+
return () => {
|
|
1751
|
+
if (contentRef.current && animationEndHandlerRef.current) {
|
|
1752
|
+
contentRef.current.removeEventListener("animationend", animationEndHandlerRef.current);
|
|
1753
|
+
animationEndHandlerRef.current = null;
|
|
1754
|
+
}
|
|
1755
|
+
};
|
|
1713
1756
|
}, [isOpen]);
|
|
1714
1757
|
React.useEffect(() => {
|
|
1715
1758
|
if (prevSliderTypeRef.current !== null && prevSliderTypeRef.current !== slider.type) {
|
|
@@ -1739,7 +1782,6 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1739
1782
|
var _a;
|
|
1740
1783
|
(_a = lightboxRef.current) == null ? void 0 : _a.go(dir);
|
|
1741
1784
|
};
|
|
1742
|
-
const appearDurationMs = appear.duration ? parseInt(appear.duration) : 300;
|
|
1743
1785
|
const backdropDurationMs = appear.type === "fade in" || appear.type === "mix" ? Math.floor(appearDurationMs * 0.7) : appearDurationMs;
|
|
1744
1786
|
const appearClass = (() => {
|
|
1745
1787
|
if (appear.type === "fade in") return styles.fadeIn;
|
|
@@ -1777,6 +1819,42 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1777
1819
|
}
|
|
1778
1820
|
return styles.fadeIn;
|
|
1779
1821
|
})();
|
|
1822
|
+
const backdropDisappearClass = (() => {
|
|
1823
|
+
if (appear.type === "fade in" || appear.type === "mix") return styles.fadeOut;
|
|
1824
|
+
if (appear.type === "slide in") {
|
|
1825
|
+
switch (appear.direction) {
|
|
1826
|
+
case "left":
|
|
1827
|
+
return styles.slideOutLeft;
|
|
1828
|
+
case "right":
|
|
1829
|
+
return styles.slideOutRight;
|
|
1830
|
+
case "top":
|
|
1831
|
+
return styles.slideOutTop;
|
|
1832
|
+
case "bottom":
|
|
1833
|
+
return styles.slideOutBottom;
|
|
1834
|
+
default:
|
|
1835
|
+
return styles.slideOutRight;
|
|
1836
|
+
}
|
|
1837
|
+
}
|
|
1838
|
+
return styles.fadeOut;
|
|
1839
|
+
})();
|
|
1840
|
+
const disappearClass = (() => {
|
|
1841
|
+
if (appear.type === "fade in") return styles.fadeOut;
|
|
1842
|
+
if (appear.type === "slide in" || appear.type === "mix") {
|
|
1843
|
+
switch (appear.direction) {
|
|
1844
|
+
case "left":
|
|
1845
|
+
return styles.slideOutLeft;
|
|
1846
|
+
case "right":
|
|
1847
|
+
return styles.slideOutRight;
|
|
1848
|
+
case "top":
|
|
1849
|
+
return styles.slideOutTop;
|
|
1850
|
+
case "bottom":
|
|
1851
|
+
return styles.slideOutBottom;
|
|
1852
|
+
default:
|
|
1853
|
+
return styles.slideOutRight;
|
|
1854
|
+
}
|
|
1855
|
+
}
|
|
1856
|
+
return styles.fadeOut;
|
|
1857
|
+
})();
|
|
1780
1858
|
React.useEffect(() => {
|
|
1781
1859
|
if (!isOpen || !closeOnBackdropClick) return;
|
|
1782
1860
|
const handleTouchEnd = (e) => {
|
|
@@ -1792,30 +1870,33 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1792
1870
|
if (!inside) {
|
|
1793
1871
|
e.stopPropagation();
|
|
1794
1872
|
isClosingRef.current = true;
|
|
1795
|
-
|
|
1873
|
+
const blockNextClick = (clickEvent) => {
|
|
1874
|
+
clickEvent.stopPropagation();
|
|
1875
|
+
clickEvent.preventDefault();
|
|
1876
|
+
document.removeEventListener("click", blockNextClick, true);
|
|
1877
|
+
};
|
|
1878
|
+
document.addEventListener("click", blockNextClick, true);
|
|
1879
|
+
handleClose();
|
|
1796
1880
|
}
|
|
1797
1881
|
}
|
|
1798
1882
|
};
|
|
1799
|
-
|
|
1800
|
-
document.addEventListener("touchend", handleTouchEnd, { passive: true });
|
|
1801
|
-
}, 100);
|
|
1883
|
+
document.addEventListener("touchend", handleTouchEnd, { passive: true });
|
|
1802
1884
|
return () => {
|
|
1803
|
-
clearTimeout(timeoutId);
|
|
1804
1885
|
document.removeEventListener("touchend", handleTouchEnd);
|
|
1805
1886
|
};
|
|
1806
|
-
}, [isOpen, closeOnBackdropClick,
|
|
1807
|
-
if (!isOpen) return null;
|
|
1887
|
+
}, [isOpen, closeOnBackdropClick, handleClose, currentIndex]);
|
|
1888
|
+
if (!isOpen && !isClosing) return null;
|
|
1808
1889
|
return reactDom.createPortal(
|
|
1809
1890
|
/* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
1810
1891
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1811
1892
|
"div",
|
|
1812
1893
|
{
|
|
1813
|
-
className: cn(styles.background, backdropAppearClass),
|
|
1894
|
+
className: cn(styles.background, isClosing ? backdropDisappearClass : backdropAppearClass),
|
|
1814
1895
|
style: {
|
|
1815
1896
|
...isEditor && { display: "none" },
|
|
1816
1897
|
backgroundColor: area.color,
|
|
1817
1898
|
backdropFilter: `blur(${area.blur}px)`,
|
|
1818
|
-
animationDuration: `${
|
|
1899
|
+
animationDuration: `${appearDurationMs}ms`,
|
|
1819
1900
|
animationTimingFunction: "ease",
|
|
1820
1901
|
animationFillMode: "both"
|
|
1821
1902
|
}
|
|
@@ -1824,11 +1905,11 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1824
1905
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1825
1906
|
"div",
|
|
1826
1907
|
{
|
|
1827
|
-
className: cn(styles.backdropStyle, { [styles.editor]: isEditor, [backdropAppearClass]: isEditor }),
|
|
1908
|
+
className: cn(styles.backdropStyle, { [styles.editor]: isEditor, [isClosing ? backdropDisappearClass : backdropAppearClass]: isEditor }),
|
|
1828
1909
|
style: { ...isEditor && {
|
|
1829
1910
|
backgroundColor: area.color,
|
|
1830
1911
|
backdropFilter: `blur(${area.blur}px)`,
|
|
1831
|
-
animationDuration: `${
|
|
1912
|
+
animationDuration: `${appearDurationMs}ms`,
|
|
1832
1913
|
animationTimingFunction: "ease",
|
|
1833
1914
|
animationFillMode: "both"
|
|
1834
1915
|
} },
|
|
@@ -1838,13 +1919,15 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1838
1919
|
children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1839
1920
|
"div",
|
|
1840
1921
|
{
|
|
1841
|
-
|
|
1922
|
+
ref: contentRef,
|
|
1923
|
+
className: cn(styles.contentStyle, isClosing ? disappearClass : appearClass),
|
|
1842
1924
|
onClick: handleContentClick,
|
|
1843
1925
|
style: {
|
|
1844
1926
|
animationDuration: `${appearDurationMs}ms`,
|
|
1845
1927
|
animationTimingFunction: "ease",
|
|
1846
1928
|
animationFillMode: "both",
|
|
1847
|
-
...appear.type === "mix" && { animationDelay: `${backdropDurationMs / 2}ms` },
|
|
1929
|
+
...appear.type === "mix" && !isClosing && { animationDelay: `${backdropDurationMs / 2}ms` },
|
|
1930
|
+
...appear.type === "mix" && isClosing && { animationDelay: "0ms" },
|
|
1848
1931
|
"--splide-speed": slider.duration || "500ms"
|
|
1849
1932
|
},
|
|
1850
1933
|
children: [
|
|
@@ -1977,7 +2060,7 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1977
2060
|
...positionStyles,
|
|
1978
2061
|
transform: combinedTransform
|
|
1979
2062
|
},
|
|
1980
|
-
onClick:
|
|
2063
|
+
onClick: handleClose,
|
|
1981
2064
|
children: /* @__PURE__ */ jsxRuntime.jsx(SvgImage, { url: area.closeIconUrl })
|
|
1982
2065
|
}
|
|
1983
2066
|
);
|
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx, Fragment, jsxs } from "react/jsx-runtime";
|
|
2
|
-
import React, { useState, useEffect, useRef, useMemo } from "react";
|
|
2
|
+
import React, { useState, useEffect, useRef, useMemo, useCallback } from "react";
|
|
3
3
|
import { Splide, SplideSlide } from "@splidejs/react-splide";
|
|
4
4
|
import cn from "classnames";
|
|
5
5
|
import { createPortal } from "react-dom";
|
|
@@ -1507,6 +1507,11 @@ const slideInLeft = "Lightbox-module__slideInLeft___P-XRo";
|
|
|
1507
1507
|
const slideInRight = "Lightbox-module__slideInRight___ZQqFi";
|
|
1508
1508
|
const slideInTop = "Lightbox-module__slideInTop___XRKCs";
|
|
1509
1509
|
const slideInBottom = "Lightbox-module__slideInBottom___TYOBS";
|
|
1510
|
+
const fadeOut = "Lightbox-module__fadeOut___h2fpQ";
|
|
1511
|
+
const slideOutLeft = "Lightbox-module__slideOutLeft___J-eMU";
|
|
1512
|
+
const slideOutRight = "Lightbox-module__slideOutRight___iZUQz";
|
|
1513
|
+
const slideOutTop = "Lightbox-module__slideOutTop___3TXF9";
|
|
1514
|
+
const slideOutBottom = "Lightbox-module__slideOutBottom___SB5ws";
|
|
1510
1515
|
const scaleSlide = "Lightbox-module__scaleSlide___wS7d4";
|
|
1511
1516
|
const styles = {
|
|
1512
1517
|
background,
|
|
@@ -1537,6 +1542,11 @@ const styles = {
|
|
|
1537
1542
|
slideInRight,
|
|
1538
1543
|
slideInTop,
|
|
1539
1544
|
slideInBottom,
|
|
1545
|
+
fadeOut,
|
|
1546
|
+
slideOutLeft,
|
|
1547
|
+
slideOutRight,
|
|
1548
|
+
slideOutTop,
|
|
1549
|
+
slideOutBottom,
|
|
1540
1550
|
scaleSlide
|
|
1541
1551
|
};
|
|
1542
1552
|
const getPositionStyles = (position, offset, isEditor) => {
|
|
@@ -1626,21 +1636,48 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1626
1636
|
const { widthSettings, fontSettings, letterSpacing, textAlign, wordSpacing, fontSizeLineHeight, textAppearance, color } = lightboxStyles.caption;
|
|
1627
1637
|
const [currentIndex, setCurrentIndex] = React.useState(0);
|
|
1628
1638
|
const [splideKey, setSplideKey] = React.useState(0);
|
|
1639
|
+
const [isClosing, setIsClosing] = React.useState(false);
|
|
1629
1640
|
const lightboxRef = useRef(null);
|
|
1630
1641
|
const prevSliderTypeRef = useRef(null);
|
|
1631
1642
|
const imageRef = useRef(null);
|
|
1632
1643
|
const isClosingRef = useRef(false);
|
|
1644
|
+
const contentRef = useRef(null);
|
|
1645
|
+
const animationEndHandlerRef = useRef(null);
|
|
1633
1646
|
const { appear, triggers, slider, thumbnail, controls, area, caption: caption2, layout } = settings.lightboxBlock;
|
|
1647
|
+
const appearDurationMs = appear.duration ? parseInt(appear.duration) : 300;
|
|
1648
|
+
const handleClose = useCallback(() => {
|
|
1649
|
+
setIsClosing(true);
|
|
1650
|
+
isClosingRef.current = true;
|
|
1651
|
+
const handleAnimationEnd = (e) => {
|
|
1652
|
+
if (e.target === contentRef.current && e.animationName) {
|
|
1653
|
+
if (contentRef.current && animationEndHandlerRef.current) {
|
|
1654
|
+
contentRef.current.removeEventListener("animationend", animationEndHandlerRef.current);
|
|
1655
|
+
}
|
|
1656
|
+
animationEndHandlerRef.current = null;
|
|
1657
|
+
onClose();
|
|
1658
|
+
setIsClosing(false);
|
|
1659
|
+
}
|
|
1660
|
+
};
|
|
1661
|
+
if (contentRef.current) {
|
|
1662
|
+
animationEndHandlerRef.current = handleAnimationEnd;
|
|
1663
|
+
contentRef.current.addEventListener("animationend", handleAnimationEnd);
|
|
1664
|
+
} else {
|
|
1665
|
+
setTimeout(() => {
|
|
1666
|
+
onClose();
|
|
1667
|
+
setIsClosing(false);
|
|
1668
|
+
}, appearDurationMs);
|
|
1669
|
+
}
|
|
1670
|
+
}, [onClose, appearDurationMs]);
|
|
1634
1671
|
const handleBackdropClick = (e) => {
|
|
1635
1672
|
if (!closeOnBackdropClick) return;
|
|
1636
1673
|
if (e.target === e.currentTarget) {
|
|
1637
|
-
|
|
1674
|
+
handleClose();
|
|
1638
1675
|
}
|
|
1639
1676
|
};
|
|
1640
1677
|
const handleImageWrapperClick = (e) => {
|
|
1641
1678
|
if (!closeOnBackdropClick) return;
|
|
1642
1679
|
if (e.target === e.currentTarget) {
|
|
1643
|
-
|
|
1680
|
+
handleClose();
|
|
1644
1681
|
}
|
|
1645
1682
|
};
|
|
1646
1683
|
const handleContentClick = (e) => {
|
|
@@ -1648,7 +1685,7 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1648
1685
|
const target = e.target;
|
|
1649
1686
|
const currentTarget = e.currentTarget;
|
|
1650
1687
|
if (target === currentTarget) {
|
|
1651
|
-
|
|
1688
|
+
handleClose();
|
|
1652
1689
|
return;
|
|
1653
1690
|
}
|
|
1654
1691
|
const isImg = target.tagName === "IMG" || target.closest("img");
|
|
@@ -1657,17 +1694,16 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1657
1694
|
const isCaption = target.closest(`.${styles.caption}`);
|
|
1658
1695
|
const isThumbnail = target.closest(`.${styles.thumbsContainer}`);
|
|
1659
1696
|
if (!isImg && !isButton && !isSplide && !isCaption && !isThumbnail) {
|
|
1660
|
-
|
|
1697
|
+
handleClose();
|
|
1661
1698
|
}
|
|
1662
1699
|
};
|
|
1663
1700
|
const onImageClick = (e) => {
|
|
1664
1701
|
var _a, _b;
|
|
1702
|
+
e.stopPropagation();
|
|
1665
1703
|
if (triggers.type === "click" && triggers.switch === "image") {
|
|
1666
|
-
e.stopPropagation();
|
|
1667
1704
|
(_a = lightboxRef.current) == null ? void 0 : _a.go("+1");
|
|
1668
1705
|
}
|
|
1669
1706
|
if (triggers.type === "click" && triggers.switch === "50/50") {
|
|
1670
|
-
e.stopPropagation();
|
|
1671
1707
|
const img2 = e.currentTarget;
|
|
1672
1708
|
const rect = img2.getBoundingClientRect();
|
|
1673
1709
|
const clickX = e.clientX - rect.left;
|
|
@@ -1687,7 +1723,7 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1687
1723
|
if (!isOpen || !closeOnEsc) return;
|
|
1688
1724
|
const onKeyDown = (event) => {
|
|
1689
1725
|
if (event.key === "Escape") {
|
|
1690
|
-
|
|
1726
|
+
handleClose();
|
|
1691
1727
|
return;
|
|
1692
1728
|
}
|
|
1693
1729
|
if (event.key === "ArrowRight") {
|
|
@@ -1702,12 +1738,19 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1702
1738
|
return () => {
|
|
1703
1739
|
window.removeEventListener("keydown", onKeyDown);
|
|
1704
1740
|
};
|
|
1705
|
-
}, [isOpen, closeOnEsc,
|
|
1741
|
+
}, [isOpen, closeOnEsc, handleClose, content.length]);
|
|
1706
1742
|
useEffect(() => {
|
|
1707
1743
|
if (isOpen) {
|
|
1708
1744
|
setCurrentIndex(0);
|
|
1709
1745
|
isClosingRef.current = false;
|
|
1746
|
+
setIsClosing(false);
|
|
1710
1747
|
}
|
|
1748
|
+
return () => {
|
|
1749
|
+
if (contentRef.current && animationEndHandlerRef.current) {
|
|
1750
|
+
contentRef.current.removeEventListener("animationend", animationEndHandlerRef.current);
|
|
1751
|
+
animationEndHandlerRef.current = null;
|
|
1752
|
+
}
|
|
1753
|
+
};
|
|
1711
1754
|
}, [isOpen]);
|
|
1712
1755
|
useEffect(() => {
|
|
1713
1756
|
if (prevSliderTypeRef.current !== null && prevSliderTypeRef.current !== slider.type) {
|
|
@@ -1737,7 +1780,6 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1737
1780
|
var _a;
|
|
1738
1781
|
(_a = lightboxRef.current) == null ? void 0 : _a.go(dir);
|
|
1739
1782
|
};
|
|
1740
|
-
const appearDurationMs = appear.duration ? parseInt(appear.duration) : 300;
|
|
1741
1783
|
const backdropDurationMs = appear.type === "fade in" || appear.type === "mix" ? Math.floor(appearDurationMs * 0.7) : appearDurationMs;
|
|
1742
1784
|
const appearClass = (() => {
|
|
1743
1785
|
if (appear.type === "fade in") return styles.fadeIn;
|
|
@@ -1775,6 +1817,42 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1775
1817
|
}
|
|
1776
1818
|
return styles.fadeIn;
|
|
1777
1819
|
})();
|
|
1820
|
+
const backdropDisappearClass = (() => {
|
|
1821
|
+
if (appear.type === "fade in" || appear.type === "mix") return styles.fadeOut;
|
|
1822
|
+
if (appear.type === "slide in") {
|
|
1823
|
+
switch (appear.direction) {
|
|
1824
|
+
case "left":
|
|
1825
|
+
return styles.slideOutLeft;
|
|
1826
|
+
case "right":
|
|
1827
|
+
return styles.slideOutRight;
|
|
1828
|
+
case "top":
|
|
1829
|
+
return styles.slideOutTop;
|
|
1830
|
+
case "bottom":
|
|
1831
|
+
return styles.slideOutBottom;
|
|
1832
|
+
default:
|
|
1833
|
+
return styles.slideOutRight;
|
|
1834
|
+
}
|
|
1835
|
+
}
|
|
1836
|
+
return styles.fadeOut;
|
|
1837
|
+
})();
|
|
1838
|
+
const disappearClass = (() => {
|
|
1839
|
+
if (appear.type === "fade in") return styles.fadeOut;
|
|
1840
|
+
if (appear.type === "slide in" || appear.type === "mix") {
|
|
1841
|
+
switch (appear.direction) {
|
|
1842
|
+
case "left":
|
|
1843
|
+
return styles.slideOutLeft;
|
|
1844
|
+
case "right":
|
|
1845
|
+
return styles.slideOutRight;
|
|
1846
|
+
case "top":
|
|
1847
|
+
return styles.slideOutTop;
|
|
1848
|
+
case "bottom":
|
|
1849
|
+
return styles.slideOutBottom;
|
|
1850
|
+
default:
|
|
1851
|
+
return styles.slideOutRight;
|
|
1852
|
+
}
|
|
1853
|
+
}
|
|
1854
|
+
return styles.fadeOut;
|
|
1855
|
+
})();
|
|
1778
1856
|
useEffect(() => {
|
|
1779
1857
|
if (!isOpen || !closeOnBackdropClick) return;
|
|
1780
1858
|
const handleTouchEnd = (e) => {
|
|
@@ -1790,30 +1868,33 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1790
1868
|
if (!inside) {
|
|
1791
1869
|
e.stopPropagation();
|
|
1792
1870
|
isClosingRef.current = true;
|
|
1793
|
-
|
|
1871
|
+
const blockNextClick = (clickEvent) => {
|
|
1872
|
+
clickEvent.stopPropagation();
|
|
1873
|
+
clickEvent.preventDefault();
|
|
1874
|
+
document.removeEventListener("click", blockNextClick, true);
|
|
1875
|
+
};
|
|
1876
|
+
document.addEventListener("click", blockNextClick, true);
|
|
1877
|
+
handleClose();
|
|
1794
1878
|
}
|
|
1795
1879
|
}
|
|
1796
1880
|
};
|
|
1797
|
-
|
|
1798
|
-
document.addEventListener("touchend", handleTouchEnd, { passive: true });
|
|
1799
|
-
}, 100);
|
|
1881
|
+
document.addEventListener("touchend", handleTouchEnd, { passive: true });
|
|
1800
1882
|
return () => {
|
|
1801
|
-
clearTimeout(timeoutId);
|
|
1802
1883
|
document.removeEventListener("touchend", handleTouchEnd);
|
|
1803
1884
|
};
|
|
1804
|
-
}, [isOpen, closeOnBackdropClick,
|
|
1805
|
-
if (!isOpen) return null;
|
|
1885
|
+
}, [isOpen, closeOnBackdropClick, handleClose, currentIndex]);
|
|
1886
|
+
if (!isOpen && !isClosing) return null;
|
|
1806
1887
|
return createPortal(
|
|
1807
1888
|
/* @__PURE__ */ jsxs(Fragment, { children: [
|
|
1808
1889
|
/* @__PURE__ */ jsx(
|
|
1809
1890
|
"div",
|
|
1810
1891
|
{
|
|
1811
|
-
className: cn(styles.background, backdropAppearClass),
|
|
1892
|
+
className: cn(styles.background, isClosing ? backdropDisappearClass : backdropAppearClass),
|
|
1812
1893
|
style: {
|
|
1813
1894
|
...isEditor && { display: "none" },
|
|
1814
1895
|
backgroundColor: area.color,
|
|
1815
1896
|
backdropFilter: `blur(${area.blur}px)`,
|
|
1816
|
-
animationDuration: `${
|
|
1897
|
+
animationDuration: `${appearDurationMs}ms`,
|
|
1817
1898
|
animationTimingFunction: "ease",
|
|
1818
1899
|
animationFillMode: "both"
|
|
1819
1900
|
}
|
|
@@ -1822,11 +1903,11 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1822
1903
|
/* @__PURE__ */ jsx(
|
|
1823
1904
|
"div",
|
|
1824
1905
|
{
|
|
1825
|
-
className: cn(styles.backdropStyle, { [styles.editor]: isEditor, [backdropAppearClass]: isEditor }),
|
|
1906
|
+
className: cn(styles.backdropStyle, { [styles.editor]: isEditor, [isClosing ? backdropDisappearClass : backdropAppearClass]: isEditor }),
|
|
1826
1907
|
style: { ...isEditor && {
|
|
1827
1908
|
backgroundColor: area.color,
|
|
1828
1909
|
backdropFilter: `blur(${area.blur}px)`,
|
|
1829
|
-
animationDuration: `${
|
|
1910
|
+
animationDuration: `${appearDurationMs}ms`,
|
|
1830
1911
|
animationTimingFunction: "ease",
|
|
1831
1912
|
animationFillMode: "both"
|
|
1832
1913
|
} },
|
|
@@ -1836,13 +1917,15 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1836
1917
|
children: /* @__PURE__ */ jsxs(
|
|
1837
1918
|
"div",
|
|
1838
1919
|
{
|
|
1839
|
-
|
|
1920
|
+
ref: contentRef,
|
|
1921
|
+
className: cn(styles.contentStyle, isClosing ? disappearClass : appearClass),
|
|
1840
1922
|
onClick: handleContentClick,
|
|
1841
1923
|
style: {
|
|
1842
1924
|
animationDuration: `${appearDurationMs}ms`,
|
|
1843
1925
|
animationTimingFunction: "ease",
|
|
1844
1926
|
animationFillMode: "both",
|
|
1845
|
-
...appear.type === "mix" && { animationDelay: `${backdropDurationMs / 2}ms` },
|
|
1927
|
+
...appear.type === "mix" && !isClosing && { animationDelay: `${backdropDurationMs / 2}ms` },
|
|
1928
|
+
...appear.type === "mix" && isClosing && { animationDelay: "0ms" },
|
|
1846
1929
|
"--splide-speed": slider.duration || "500ms"
|
|
1847
1930
|
},
|
|
1848
1931
|
children: [
|
|
@@ -1975,7 +2058,7 @@ const Lightbox = ({ isOpen, onClose, content, styles: lightboxStyles, settings,
|
|
|
1975
2058
|
...positionStyles,
|
|
1976
2059
|
transform: combinedTransform
|
|
1977
2060
|
},
|
|
1978
|
-
onClick:
|
|
2061
|
+
onClick: handleClose,
|
|
1979
2062
|
children: /* @__PURE__ */ jsx(SvgImage, { url: area.closeIconUrl })
|
|
1980
2063
|
}
|
|
1981
2064
|
);
|