!function(t,i){"object"==typeof exports&&"undefined"!=typeof module?module.exports=i():"function"==typeof define&&define.amd?define(i):(t="undefined"!=typeof globalThis?globalThis:t||self).SplideRenderer=i()}(this,function(){"use strict";var n="rtl",r="ttb",o={marginRight:["marginBottom","marginLeft"],autoWidth:["autoHeight"],fixedWidth:["fixedHeight"],paddingLeft:["paddingTop","paddingRight"],paddingRight:["paddingBottom","paddingLeft"],width:["height"],left:["top","right"],right:["bottom","left"],x:["y"],X:["Y"],Y:["X"],ArrowLeft:["ArrowUp","ArrowRight"],ArrowRight:["ArrowDown","ArrowLeft"]};function a(t,i,s){return{resolve:function(t,i){var e=s.direction;return o[t][e!==n||i?e===r?0:-1:1]||t},orient:function(t){return t*(s.direction===n?1:-1)}}}var e="splide",s=e,u=e+"__track",l=e+"__list",c=e+"__slide",h=c+"--clone",t=e+"__arrow",i=e+"__pagination",d="is-active",f={type:"slide",role:"region",speed:400,waitForTransition:!0,perPage:1,cloneStatus:!0,arrows:!0,pagination:!0,interval:5e3,pauseOnHover:!0,pauseOnFocus:!0,resetProgress:!0,keyboard:!0,easing:"cubic-bezier(0.25, 1, 0.5, 1)",drag:!0,direction:"ltr",slideFocus:!0,trimSpace:!0,focusableNodes:"a, button, textarea, input, select, iframe",live:!0,classes:{slide:c,clone:h,arrows:e+"__arrows",arrow:t,prev:t+"--prev",next:t+"--next",pagination:i,page:i+"__page",spinner:e+"__spinner"},i18n:{prev:"Previous slide",next:"Next slide",first:"Go to first slide",last:"Go to last slide",slideX:"Go to slide %s",pageX:"Go to page %s",play:"Start autoplay",pause:"Pause autoplay",carousel:"carousel",slide:"slide",select:"Select slide to show",slideLabel:"%s of %s"}};function p(t,i,e){return Array.prototype.slice.call(t,i,e)}function v(t){return t.bind.apply(t,[null].concat(p(arguments,1)))}function g(t,i){return typeof i===t}function y(t){return null!==t&&g("object",t)}var b=Array.isArray;v(g,"function");var m=v(g,"string");function S(t){return b(t)?t:[t]}function w(t,i){S(t).forEach(i)}function C(t,i){return t.push.apply(t,S(i)),t}function x(t,i){return t instanceof HTMLElement&&(t.msMatchesSelector||t.matches).call(t,i)}function _(t,i){return i?(e=i,((i=t)?p(i.children).filter(function(t){return x(t,e)}):[])[0]):t.firstElementChild;var e}function k(t,i,e){if(t)for(var s=Object.keys(t),s=e?s.reverse():s,n=0;n img","display",t.cover?"none":"inline",i)})},i.buildTranslate=function(t){var i=this.Direction,e=i.resolve,s=i.orient,i=[];return i.push(this.cssOffsetClones(t)),i.push(this.cssOffsetGaps(t)),this.isCenter(t)&&(i.push(this.buildCssValue(s(-50),"%")),i.push.apply(i,this.cssOffsetCenter(t))),i.filter(Boolean).map(function(t){return"translate"+e("X")+"("+t+")"}).join(" ")},i.cssOffsetClones=function(t){var i=this.Direction,e=i.resolve,s=i.orient,n=this.getCloneCount();if(this.isFixedWidth(t)){i=this.parseCssValue(t[e("fixedWidth")]),e=i.value,i=i.unit;return this.buildCssValue(s(e)*n,i)}return s(100*n/t.perPage)+"%"},i.cssOffsetCenter=function(t){var i=this.Direction,e=i.resolve,i=i.orient;if(this.isFixedWidth(t)){var s=this.parseCssValue(t[e("fixedWidth")]),n=s.value,r=s.unit;return[this.buildCssValue(i(n/2),r)]}var s=[],n=t.perPage,r=t.gap;return s.push(i(50/n)+"%"),r&&(r=(t=this.parseCssValue(r)).value,t=t.unit,s.push(this.buildCssValue(i((r/n-r)/2),t))),s},i.cssOffsetGaps=function(t){var i=this.getCloneCount();if(i&&t.gap){var e=this.Direction.orient,s=this.parseCssValue(t.gap),n=s.value,s=s.unit;if(this.isFixedWidth(t))return this.buildCssValue(e(n*i),s);t=t.perPage;return this.buildCssValue(e(i/t*n),s)}return""},i.resolve=function(t){return H(this.Direction.resolve(t))},i.cssPadding=function(t,i){t=t.padding,i=this.Direction.resolve(i?"right":"left",!0);return t&&P(t[i]||(y(t)?0:t))||"0px"},i.cssTrackHeight=function(t){var i="";return this.isVertical()&&(T(i=this.cssHeight(t),'"height" is missing.'),i="calc("+i+" - "+this.cssPadding(t,!1)+" - "+this.cssPadding(t,!0)+")"),i},i.cssHeight=function(t){return P(t.height)},i.cssSlideWidth=function(t){return t.autoWidth?"":P(t.fixedWidth)||(this.isVertical()?"":this.cssSlideSize(t))},i.cssSlideHeight=function(t){return P(t.fixedHeight)||(this.isVertical()?t.autoHeight?"":this.cssSlideSize(t):this.cssHeight(t))},i.cssSlideSize=function(t){var i=P(t.gap);return"calc((100%"+(i&&" + "+i)+")/"+(t.perPage||1)+(i&&" - "+i)+")"},i.cssAspectRatio=function(t){t=t.heightRatio;return t?""+1/t:""},i.buildCssValue=function(t,i){return""+t+i},i.parseCssValue=function(t){return m(t)?{value:parseFloat(t)||0,unit:t.replace(/\d*(\.\d*)?/,"")||"px"}:{value:t,unit:"px"}},i.parseBreakpoints=function(){var e=this,t=this.options.breakpoints;this.breakpoints.push(["default",this.options]),t&&k(t,function(t,i){e.breakpoints.push([i,L(L({},e.options),t)])})},i.isFixedWidth=function(t){return!!t[this.Direction.resolve("fixedWidth")]},i.isLoop=function(){return"loop"===this.options.type},i.isCenter=function(t){if("center"===t.focus){if(this.isLoop())return!0;if("slide"===this.options.type)return!this.options.trimSpace}return!1},i.isVertical=function(){return this.options.direction===r},i.buildClasses=function(){var t=this.options;return[s,s+"--"+t.type,s+"--"+t.direction,t.drag&&s+"--draggable",t.isNavigation&&s+"--nav",d,!this.config.hidden&&"is-rendered"].filter(Boolean).join(" ")},i.buildAttrs=function(t){var e="";return k(t,function(t,i){e+=t?" "+H(i)+'="'+t+'"':""}),e.trim()},i.buildStyles=function(t){var e="";return k(t,function(t,i){e+=" "+H(i)+":"+t+";"}),e.trim()},i.renderSlides=function(){var i=this,e=this.config.slideTag;return this.slides.map(function(t){return"<"+e+" "+i.buildAttrs(t.attrs)+">"+(t.html||"")+""}).join("")},i.cover=function(t){var i=t.styles,t=t.html,t=void 0===t?"":t;!this.options.cover||this.options.lazyLoad||(t=t.match(//))&&t[2]&&(i.background="center/cover no-repeat url('"+t[2]+"')")},i.generateClones=function(s){for(var n=this.options.classes,r=this.getCloneCount(),t=s.slice();t.length',t+=this.renderArrow(!0),t+=this.renderArrow(!1),t+=""},i.renderArrow=function(t){var i=this.options,e=i.classes,i=i.i18n,i={class:e.arrow+" "+(t?e.prev:e.next),type:"button",ariaLabel:t?i.prev:i.next};return"'},i.html=function(){var t=this.config,i=t.rootClass,e=t.listTag,s=t.arrows,n=t.beforeTrack,r=t.afterTrack,o=t.slider,a=t.beforeSlider,u=t.afterSlider,t="";return t+='
',t+="",o&&(t+=a||"",t+='
'),t+=n||"",s&&(t+=this.renderArrows()),t+='
',t+="<"+e+' class="splide__list">',t+=this.renderSlides(),t+="",t+="
",t+=r||"",o&&(t+="
",t+=u||""),t+="
"},t}()}); //# sourceMappingURL=splide-renderer.min.js.map