PageSourceSearch

https://mei-arch.eu/wp-content/themes/mei-architecten/dist/main.js…=882c208863c6552f7a1be3e4cf6cd5cf8c3790eb

js mei-arch.eu collected 2026-10-02 10:53:17 UTC 391,406 bytes, 1 lines download raw bytes

1!function(){var t={7475:function(t,e,i){var n,s,o;!function(r){"use strict";s=[i(5311)],n=function(t){var e,i=window.Slick||{};(e=0,i=function(i,n){var s,o=this;o.defaults={adaptiveHeight:!1,appendArrows:t(i),appendDots:t(i),arrows:!0,arrowsPlacement:null,asNavFor:null,prevArrow:'<button class="slick-prev" type="button"><span class="slick-prev-icon" aria-hidden="true"></span><span class="slick-sr-only">Previous</span></button>',nextArrow:'<button class="slick-next" type="button"><span class="slick-next-icon" aria-hidden="true"></span><span class="slick-sr-only">Next</span></button>',autoplay:!1,autoplaySpeed:3e3,centerMode:!1,centerPadding:"50px",cssEase:"ease",customPaging:function(e,i){return t('<button type="button"><span class="slick-dot-icon" aria-hidden="true"></span><span class="slick-sr-only">Go to slide '+(i+1)+"</span></button>")},dots:!1,dotsClass:"slick-dots",draggable:!0,easing:"linear",edgeFriction:.35,fade:!1,infinite:!0,initialSlide:0,instructionsText:null,lazyLoad:"ondemand",mobileFirst:!1,playIcon:'<span class="slick-play-icon" aria-hidden="true"></span>',pauseIcon:'<span class="slick-pause-icon" aria-hidden="true"></span>',pauseOnHover:!0,pauseOnFocus:!0,pauseOnDotsHover:!1,regionLabel:"carousel",respondTo:"window",responsive:null,rows:1,rtl:!1,slide:"",slidesPerRow:1,slidesToShow:1,slidesToScroll:1,speed:500,swipe:!0,swipeToSlide:!1,touchMove:!0,touchThreshold:5,useAutoplayToggleButton:!0,useCSS:!0,useGroupRole:!0,useTransform:!0,variableWidth:!1,vertical:!1,verticalSwiping:!1,waitForAnimate:!0,zIndex:1e3},o.initials={animating:!1,dragging:!1,autoPlayTimer:null,currentDirection:0,currentLeft:null,currentSlide:0,direction:1,$dots:null,$instructionsText:null,listWidth:null,listHeight:null,loadIndex:0,$nextArrow:null,$pauseButton:null,$pauseIcon:null,$playIcon:null,$prevArrow:null,scrolling:!1,slideCount:null,slideWidth:null,$slideTrack:null,$slides:null,sliding:!1,slideOffset:0,swipeLeft:null,swiping:!1,$list:null,touchObject:{},transformsEnabled:!1,unslicked:!1},t.extend(o,o.initials),o.activeBreakpoint=null,o.animType=null,o.animProp=null,o.breakpoints=[],o.breakpointSettings=[],o.cssTransitions=!1,o.focussed=!1,o.interrupted=!1,o.hidden="hidden",o.paused=!0,o.positionProp=null,o.respondTo=null,o.rowCount=1,o.shouldClick=!0,o.$slider=t(i),o.$slidesCache=null,o.transformType=null,o.transitionType=null,o.visibilityChange="visibilitychange",o.windowWidth=0,o.windowTimer=null,s=t(i).data("slick")||{},o.options=t.extend({},o.defaults,n,s),o.currentSlide=o.options.initialSlide,o.originalSettings=o.options,void 0!==document.mozHidden?(o.hidden="mozHidden",o.visibilityChange="mozvisibilitychange"):void 0!==document.webkitHidden&&(o.hidden="webkitHidden",o.visibilityChange="webkitvisibilitychange"),o.autoPlay=t.proxy(o.autoPlay,o),o.autoPlayClear=t.proxy(o.autoPlayClear,o),o.autoPlayIterator=t.proxy(o.autoPlayIterator,o),o.autoPlayToggleHandler=t.proxy(o.autoPlayToggleHandler,o),o.changeSlide=t.proxy(o.changeSlide,o),o.clickHandler=t.proxy(o.clickHandler,o),o.selectHandler=t.proxy(o.selectHandler,o),o.setPosition=t.proxy(o.setPosition,o),o.swipeHandler=t.proxy(o.swipeHandler,o),o.dragHandler=t.proxy(o.dragHandler,o),o.instanceUid=e++,o.htmlExpr=/^(?:\s*(<[\w\W]+>)[^>]*)$/,o.registerBreakpoints(),o.init(!0)}).prototype.addSlide=i.prototype.slickAdd=function(e,i,n){var s=this;if("boolean"==typeof i)n=i,i=null;else if(i<0||i>=s.slideCount)return!1;s.unload(),"number"==typeof i?0===i&&0===s.$slides.length?t(e).appendTo(s.$slideTrack):n?t(e).insertBefore(s.$slides.eq(i)):t(e).insertAfter(s.$slides.eq(i)):!0===n?t(e).prependTo(s.$slideTrack):t(e).appendTo(s.$slideTrack),s.$slides=s.$slideTrack.children(this.options.slide),s.$slideTrack.children(this.options.slide).detach(),s.$slideTrack.append(s.$slides),s.$slides.each((function(e,i){t(i).attr("data-slick-index",e),t(i).attr("role","group"),t(i).attr("aria-label","slide "+e)})),s.$slidesCache=s.$slides,s.reinit()},i.prototype.animateHeight=function(){var t=this;if(1===t.options.slidesToShow&&!0===t.options.adaptiveHeight&&!1===t.options.vertical){var e=t.$slides.eq(t.currentSlide).outerHeight(!0);t.$list.animate({height:e},t.options.speed)}},i.prototype.animateSlide=function(e,i){var n={},s=this;s.animateHeight(),!0===s.options.rtl&&!1===s.options.vertical&&(e=-e),!1===s.transformsEnabled?!1===s.options.vertical?s.$slideTrack.animate({left:e},s.options.speed,s.options.easing,i):s.$slideTrack.animate({top:e},s.options.speed,s.options.easing,i):!1===s.cssTransitions?(!0===s.options.rtl&&(s.currentLeft=-s.currentLeft),t({animStart:s.currentLeft}).animate({animStart:e},{duration:s.options.speed,easing:s.options.easing,step:function(t){t=Math.ceil(t),!1===s.options.vertical?(n[s.animType]="translate("+t+"px, 0px)",s.$slideTrack.css(n)):(n[s.animType]="translate(0px,"+t+"px)",s.$slideTrack.css(n))},complete:function(){i&&i.call()}})):(s.applyTransition(),e=Math.ceil(e),!1===s.options.vertical?n[s.animType]="translate3d("+e+"px, 0px, 0px)":n[s.animType]="translate3d(0px,"+e+"px, 0px)",s.$slideTrack.css(n),i&&setTimeout((function(){s.disableTransition(),i.call()}),s.options.speed))},i.prototype.getNavTarget=function(){var e=this.options.asNavFor;return e&&null!==e&&(e=t(e).not(this.$slider)),e},i.prototype.asNavFor=function(e){var i=this.getNavTarget();null!==i&&"object"==typeof i&&i.each((function(){var i=t(this).slick("getSlick");i.unslicked||i.slideHandler(e,!0)}))},i.prototype.applyTransition=function(t){var e=this,i={};!1===e.options.fade?i[e.transitionType]=e.transformType+" "+e.options.speed+"ms "+e.options.cssEase:i[e.transitionType]="opacity "+e.options.speed+"ms "+e.options.cssEase,!1===e.options.fade?e.$slideTrack.css(i):e.$slides.eq(t).css(i)},i.prototype.autoPlay=function(){var t=this;t.autoPlayClear(),t.slideCount>t.options.slidesToShow&&(t.autoPlayTimer=setInterval(t.autoPlayIterator,t.options.autoplaySpeed))},i.prototype.autoPlayClear=function(){this.autoPlayTimer&&clearInterval(this.autoPlayTimer)},i.prototype.autoPlayIterator=function(){var t=this,e=t.currentSlide+t.options.slidesToScroll;
vendor: 3,422 bytes, line 1
1t.paused||t.interrupted||t.focussed||(!1===t.options.infinite&&(1===t.direction&&t.currentSlide+1===t.slideCount-1?t.direction=0:0===t.direction&&(e=t.currentSlide-t.options.slidesToScroll,t.currentSlide-1==0&&(t.direction=1))),t.slideHandler(e))},i.prototype.autoPlayToggleHandler=function(){var t=this;t.paused?(t.$playIcon.css("display","none"),t.$pauseIcon.css("display","inline"),t.$pauseButton.find(".slick-play-text").attr("style","display: none"),t.$pauseButton.find(".slick-pause-text").removeAttr("style"),t.slickPlay()):(t.$playIcon.css("display","inline"),t.$pauseIcon.css("display","none"),t.$pauseButton.find(".slick-play-text").removeAttr("style"),t.$pauseButton.find(".slick-pause-text").attr("style","display: none"),t.slickPause())},i.prototype.buildArrows=function(){var e=this;if(!0===e.options.arrows)if(e.$prevArrow=t(e.options.prevArrow).addClass("slick-arrow"),e.$nextArrow=t(e.options.nextArrow).addClass("slick-arrow"),e.slideCount>e.options.slidesToShow){if(e.htmlExpr.test(e.options.prevArrow))if(null!=e.options.arrowsPlacement)switch(e.options.arrowsPlacement){case"beforeSlides":case"split":console.log("test"),e.$prevArrow.prependTo(e.options.appendArrows);break;case"afterSlides":e.$prevArrow.appendTo(e.options.appendArrows)}else e.$prevArrow.prependTo(e.options.appendArrows);if(e.htmlExpr.test(e.options.nextArrow))if(null!=e.options.arrowsPlacement)switch(e.options.arrowsPlacement){case"beforeSlides":console.log("test2"),e.$prevArrow.after(e.$nextArrow);break;case"afterSlides":case"split":e.$nextArrow.appendTo(e.options.appendArrows)}else e.$nextArrow.appendTo(e.options.appendArrows);!0!==e.options.infinite&&e.$prevArrow.addClass("slick-disabled").prop("disabled",!0)}else e.$prevArrow.add(e.$nextArrow).addClass("slick-hidden").prop("disabled",!0)},i.prototype.buildDots=function(){var e,i,n=this;if(!0===n.options.dots&&n.slideCount>n.options.slidesToShow){for(n.$slider.addClass("slick-dotted"),i=t("<ul />").addClass(n.options.dotsClass),e=0;e<=n.getDotCount();e+=1)i.append(t("<li />").append(n.options.customPaging.call(this,n,e)));n.$dots=i.appendTo(n.options.appendDots),n.$dots.find("li").first().addClass("slick-active")}},i.prototype.buildOut=function(){var e=this;e.$slides=e.$slider.children(e.options.slide+":not(.slick-cloned)").addClass("slick-slide"),e.slideCount=e.$slides.length,e.$slides.each((function(i,n){t(n).attr("data-slick-index",i).data("originalStyling",t(n).attr("style")||""),e.options.useGroupRole&&t(n).attr("role","group").attr("aria-label","slide "+(i+1))})),e.$slider.addClass("slick-slider"),e.$slider.attr("role","region"),e.$slider.attr("aria-label",e.options.regionLabel),e.$slideTrack=0===e.slideCount?t('<div class="slick-track"/>').appendTo(e.$slider):e.$slides.wrapAll('<div class="slick-track"/>').parent(),e.$list=e.$slideTrack.wrap('<div class="slick-list"/>').parent(),e.$slideTrack.css("opacity",0),!0!==e.options.centerMode&&!0!==e.options.swipeToSlide||(e.options.slidesToScroll=1),t("img[data-lazy]",e.$slider).not("[src]").addClass("slick-loading"),e.setupInfinite(),e.buildArrows(),e.buildDots(),e.updateDots(),e.setSlideClasses("number"==typeof e.currentSlide?e.currentSlide:0),!0===e.options.draggable&&e.$list.addClass("draggable"),e.options.autoplay&&e.options.useAutoplayToggleButton&&(e.$pauseIcon=t(e.options.pauseIcon).attr("aria-hidden",!0),e.$playIcon=t(e.options.playIcon).attr("aria-hidden",!0),e.$pauseButton=t('
1<button type="button" class="slick-autoplay-toggle-button">'),e.$pauseButton.append(e.$pauseIcon),e.$pauseButton.append(e.$playIcon.css("display","none")),e.$pauseButton.append(t('<span class="slick-pause-text slick-sr-only">Pause</span>')),e.$pauseButton.append(t('<span class="slick-play-text slick-sr-only" style="display: none">Play</span>')),e.$pauseButton.prependTo(e.$slider)),null!=e.options.instructionsText&&""!=e.options.instructionsText&&(e.$instructionsText=t('<p class="slick-instructions slick-sr-only">'+e.options.instructionsText+"</p>"),e.$instructionsText.prependTo(e.$slider))},i.prototype.buildRows=function(){var t,e,i,n,s,o,r,a=this;if(n=document.createDocumentFragment(),o=a.$slider.children(),a.options.rows>0){for(r=a.options.slidesPerRow*a.options.rows,s=Math.ceil(o.length/r),t=0;t<s;t++){var l=document.createElement("div");for(e=0;e<a.options.rows;e++){var h=document.createElement("div");for(i=0;i<a.options.slidesPerRow;i++){var d=t*r+(e*a.options.slidesPerRow+i);o.get(d)&&h.appendChild(o.get(d))}l.appendChild(h)}n.appendChild(l)}a.$slider.empty().append(n),a.$slider.children().children().children().css({width:100/a.options.slidesPerRow+"%",display:"inline-block"})}},i.prototype.checkResponsive=function(e,i){var n,s,o,r=this,a=!1,l=r.$slider.width(),h=window.innerWidth||t(window).width();if("window"===r.respondTo?o=h:"slider"===r.respondTo?o=l:"min"===r.respondTo&&(o=Math.min(h,l)),r.options.responsive&&r.options.responsive.length&&null!==r.options.responsive){for(n in s=null,r.breakpoints)r.breakpoints.hasOwnProperty(n)&&(!1===r.originalSettings.mobileFirst?o<r.breakpoints[n]&&(s=r.breakpoints[n]):o>r.breakpoints[n]&&(s=r.breakpoints[n]));null!==s?null!==r.activeBreakpoint?(s!==r.activeBreakpoint||i)&&(r.activeBreakpoint=s,"unslick"===r.breakpointSettings[s]?r.unslick(s):(r.options=t.extend({},r.originalSettings,r.breakpointSettings[s]),!0===e&&(r.currentSlide=r.options.initialSlide),r.refresh(e)),a=s):(r.activeBreakpoint=s,"unslick"===r.breakpointSettings[s]?r.unslick(s):(r.options=t.extend({},r.originalSettings,r.breakpointSettings[s]),!0===e&&(r.currentSlide=r.options.initialSlide),r.refresh(e)),a=s):null!==r.activeBreakpoint&&(r.activeBreakpoint=null,r.options=r.originalSettings,!0===e&&(r.currentSlide=r.options.initialSlide),r.refresh(e),a=s),e||!1===a||r.$slider.trigger("breakpoint",[r,a])}},i.prototype.changeSlide=function(e,i){var n,s,o=this,r=t(e.currentTarget);switch(r.is("a")&&e.preventDefault(),r.is("li")||(r=r.closest("li")),n=o.slideCount%o.options.slidesToScroll!=0?0:(o.slideCount-o.currentSlide)%o.options.slidesToScroll,e.data.message){case"previous":s=0===n?o.options.slidesToScroll:o.options.slidesToShow-n,o.slideCount>o.options.slidesToShow&&o.slideHandler(o.currentSlide-s,!1,i);break;case"next":s=0===n?o.options.slidesToScroll:n,o.slideCount>o.options.slidesToShow&&o.slideHandler(o.currentSlide+s,!1,i);break;case"index":var a=0===e.data.index?0:e.data.index||r.index()*o.options.slidesToScroll;o.slideHandler(o.checkNavigable(a),!1,i),r.children().trigger("focus");break;default:return}},i.prototype.checkNavigable=function(t){var e,i;if(i=0,t>(e=this.getNavigableIndexes())[e.length-1])t=e[e.length-1];else for(var n in e){if(t<e[n]){t=i;break}i=e[n]}return t},i.prototype.cleanUpEvents=function(){var e=this;e.options.autoplay&&e.options.useAutoplayToggleButton&&e.$pauseButton.off("click.slick",e.autoPlayToggleHandler),e.options.dots&&null!==e.$dots&&t("li",e.$dots).off("click.slick",e.changeSlide).off("mouseenter.slick",t.proxy(e.interrupt,e,!0)).off("mouseleave.slick",t.proxy(e.interrupt,e,!1)),e.$slider.off("focus.slick blur.slick"),!0===e.options.arrows&&e.slideCount>e.options.slidesToShow&&(e.$prevArrow&&e.$prevArrow.off("click.slick",e.changeSlide),e.$nextArrow&&e.$nextArrow.off("click.slick",e.changeSlide)),e.$list.off("touchstart.slick mousedown.slick",e.swipeHandler),e.$list.off("touchmove.slick mousemove.slick",e.swipeHandler),e.$list.off("touchend.slick mouseup.slick",e.swipeHandler),e.$list.off("touchcancel.slick mouseleave.
1slick",e.swipeHandler),e.$list.off("click.slick",e.clickHandler),t(document).off(e.visibilityChange,e.visibility),e.cleanUpSlideEvents(),t(window).off("orientationchange.slick.slick-"+e.instanceUid,e.orientationChange),t(window).off("resize.slick.slick-"+e.instanceUid,e.resize),t("[draggable!=true]",e.$slideTrack).off("dragstart",e.preventDefault),t(window).off("load.slick.slick-"+e.instanceUid,e.setPosition)},i.prototype.cleanUpSlideEvents=function(){var e=this;e.$list.off("mouseenter.slick",t.proxy(e.interrupt,e,!0)),e.$list.off("mouseleave.slick",t.proxy(e.interrupt,e,!1))},i.prototype.cleanUpRows=function(){var t,e=this;e.options.rows>0&&((t=e.$slides.children().children()).removeAttr("style"),e.$slider.empty().append(t))},i.prototype.clickHandler=function(t){!1===this.shouldClick&&(t.stopImmediatePropagation(),t.stopPropagation(),t.preventDefault())},i.prototype.destroy=function(e){var i=this;i.autoPlayClear(),i.touchObject={},i.cleanUpEvents(),t(".slick-cloned",i.$slider).detach(),i.options.autoplay&&i.options.useAutoplayToggleButton&&i.$pauseButton.remove(),i.$dots&&i.$dots.remove(),i.$prevArrow&&i.$prevArrow.length&&(i.$prevArrow.removeClass("slick-disabled slick-arrow slick-hidden").prop("disabled",!1).css("display",""),i.htmlExpr.test(i.options.prevArrow)&&i.$prevArrow.remove()),i.$nextArrow&&i.$nextArrow.length&&(i.$nextArrow.removeClass("slick-disabled slick-arrow slick-hidden").prop("disabled",!1).css("display",""),i.htmlExpr.test(i.options.nextArrow)&&i.$nextArrow.remove()),i.$slides&&(i.$slides.removeClass("slick-slide slick-active slick-center slick-visible slick-current").removeAttr("aria-hidden").removeAttr("data-slick-index").each((function(){t(this).attr("style",t(this).data("originalStyling"))})),i.$slideTrack.children(this.options.slide).detach(),i.$slideTrack.detach(),i.$list.detach(),i.$slider.append(i.$slides)),i.cleanUpRows(),i.$slider.removeClass("slick-slider"),i.$slider.removeClass("slick-initialized"),i.$slider.removeClass("slick-dotted"),i.unslicked=!0,e||i.$slider.trigger("destroy",[i])},i.prototype.disableTransition=function(t){var e=this,i={};i[e.transitionType]="",!1===e.options.fade?e.$slideTrack.css(i):e.$slides.eq(t).css(i)},i.prototype.fadeSlide=function(t,e){var i=this;!1===i.cssTransitions?(i.$slides.eq(t).css({zIndex:i.options.zIndex}),i.$slides.eq(t).animate({opacity:1},i.options.speed,i.options.easing,e)):(i.applyTransition(t),i.$slides.eq(t).css({opacity:1,zIndex:i.options.zIndex}),e&&setTimeout((function(){i.disableTransition(t),e.call()}),i.options.speed))},i.prototype.fadeSlideOut=function(t){var e=this;!1===e.cssTransitions?e.$slides.eq(t).animate({opacity:0,zIndex:e.options.zIndex-2},e.options.speed,e.options.easing):(e.applyTransition(t),e.$slides.eq(t).css({opacity:0,zIndex:e.options.zIndex-2}))},i.prototype.filterSlides=i.prototype.slickFilter=function(t){var e=this;null!==t&&(e.$slidesCache=e.$slides,e.unload(),e.$slideTrack.children(this.options.slide).detach(),e.$slidesCache.filter(t).appendTo(e.$slideTrack),e.reinit())},i.prototype.focusHandler=function(){var e=this;e.$slider.off("focus.slick blur.slick").on("focus.slick","*",(function(i){var n=t(this);setTimeout((function(){e.options.pauseOnFocus&&n.is(":focus")&&(e.focussed=!0,e.autoPlay())}),0)})).on("blur.slick","*",(function(i){t(this),e.options.pauseOnFocus&&(e.focussed=!1,e.autoPlay())}))},i.prototype.getCurrent=i.prototype.slickCurrentSlide=function(){return this.currentSlide},i.prototype.getDotCount=function(){var t=this,e=0,i=0,n=0;if(!0===t.options.infinite)if(t.slideCount<=t.options.slidesToShow)++n;else for(;e<t.slideCount;)++n,e=i+t.options.slidesToScroll,i+=t.options.slidesToScroll<=t.options.slidesToShow?t.options.slidesToScroll:t.options.slidesToShow;else if(!0===t.options.centerMode)n=t.slideCount;else if(t.options.asNavFor)for(;e<t.slideCount;)++n,e=i+t.options.slidesToScroll,i+=t.options.slidesToScroll<=t.options.slidesToShow?t.options.slidesToScroll:t.options.slidesToShow;else n=1+Math.ceil((t.slideCount-t.options.slidesToShow)/t.options.slidesToScroll);return n-1},i.prototype.getLeft=function(t){var e,i,n,s,o=this,r=0;return o.slideOffset=0,i=o.$slides.first().outerHeight(!0),!0===o.options.infinite?(o.slideCount>o.options.slidesToShow&&(o.slideOffset=o.slideWidth*o.options.slidesToShow*-1,s=-1,!0===o.options.vertical&&!0===o.options.centerMode&&(2===o.options.slidesToShow?s=-1.5:1===o.options.slidesToShow&&(s=-2)),r=i*o.options.slidesToShow*s),o.slideCount%o.options.slidesToScroll!=0&&t+o.options.slidesToScroll>o.slideCount&&o.slideCount>o.options.slidesToShow&&(t>o.slideCount?(o.slideOffset=(o.options.slidesToShow-(t-o.slideCount))*o.slideWidth*-1,r=(o.options.slidesToShow-(t-o.slideCount))*i*-1):(o.slideOffset=o.slideCount%o.options.slidesToScroll*o.slideWidth*-1,r=o.slideCount%o.options.slidesToScroll*i*-1))):t+o.options.slidesToShow>o.slideCount&&(o.slideOffset=(t+o.options.slidesToShow-o.slideCount)*o.slideWidth,r=(t+o.options.slidesToShow-o.slideCount)*i),o.slideCount<=o.options.slidesToShow&&(o.slideOffset=0,r=0),!0===o.options.centerMode&&o.slideCount<=o.options.slidesToShow?o.slideOffset=o.slideWidth*Math.floor(o.options.slidesToShow)/2-o.slideWidth*o.slideCount/2:!0===o.options.centerMode&&!0===o.options.infinite?o.slideOffset+=o.slideWidth*Math.floor(o.options.slidesToShow/2)-o.slideWidth:!0===o.options.centerMode&&(o.slideOffset=0,o.slideOffset+=o.slideWidth*Math.floor(o.options.slidesToShow/2)),e=!1===o.options.vertical?t*o.slideWidth*-1+o.slideOffset:t*i*-1+r,!0===o.options.variableWidth&&(n=o.slideCount<=o.options.slidesToShow||!1===o.options.infinite?o.$slideTrack.children(".slick-slide").eq(t):o.$slideTrack.children(".slick-slide").eq(t+o.options.slidesToShow),e=!0===o.options.rtl?n[0]?-1*(o.$slideTrack.width()-n[0].offsetLeft-n.width()):0:n[0]?-1*n[0].offsetLeft:0,!0===o.options.centerMode&&(n=o.slideCount<=o.options.slidesToShow||!1===o.options.infinite?o.$slideTrack.children(".slick-slide").eq(t):o.$slideTrack.children(".slick-slide").eq(t+o.options.slidesToShow+1),e=!0===o.options.rtl?n[0]?-1*(o.$slideTrack.width()-n[0].offsetLeft-n.width()):0:n[0]?-1*n[0].offsetLeft:0,e+=(o.$list.width()-n.outerWidth())/2)),e},i.prototype.getOption=i.prototype.slickGetOption=function(t){return this.options[t]},i.prototype.getNavigableIndexes=function(){var t,e=this,i=0,n=0,s=[];for(!1===e.options.infinite?t=e.slideCount:(i=-1*e.options.slidesToScroll,n=-1*e.options.slidesToScroll,t=2*e.slideCount);i<t;)s.push(i),i=n+e.options.slidesToScroll,n+=e.options.slidesToScroll<=e.options.slidesToShow?e.options.slidesToScroll:e.options.slidesToShow;return s},i.prototype.getSlick=function(){return this},i.prototype.getSlideCount=function(){var e,i,n,s=this;return n=!0===s.options.centerMode?Math.floor(s.$list.width()/2):0,i=-1*s.swipeLeft+n,!0===s.options.swipeToSlide?(s.$slideTrack.find(".slick-slide").each((function(n,o){var r,a;if(r=t(o).outerWidth(),a=o.offsetLeft,!0!==s.options.centerMode&&(a+=r/2),i<a+r)return e=o,!1})),Math.abs(t(e).attr("data-slick-index")-s.currentSlide)||1):s.options.slidesToScroll},i.prototype.goTo=i.prototype.slickGoTo=function(t,e){this.changeSlide({data:{message:"index",index:
vendor: 7,575 bytes, line 1
1parseInt(t)}},e)},i.prototype.init=function(e){var i=this;t(i.$slider).hasClass("slick-initialized")||(t(i.$slider).addClass("slick-initialized"),i.buildRows(),i.buildOut(),i.setProps(),i.startLoad(),i.loadSlider(),i.initializeEvents(),i.updateArrows(),i.updateDots(),i.checkResponsive(!0),i.focusHandler()),e&&i.$slider.trigger("init",[i]),i.options.autoplay&&(i.paused=!1,i.autoPlay()),i.updateSlideVisibility(),null!=i.options.accessibility&&console.warn("accessibility setting is no longer supported."),null!=i.options.focusOnChange&&console.warn("focusOnChange is no longer supported."),null!=i.options.focusOnSelect&&console.warn("focusOnSelect is no longer supported.")},i.prototype.initArrowEvents=function(){var t=this;!0===t.options.arrows&&t.slideCount>t.options.slidesToShow&&(t.$prevArrow.off("click.slick").on("click.slick",{message:"previous"},t.changeSlide),t.$nextArrow.off("click.slick").on("click.slick",{message:"next"},t.changeSlide))},i.prototype.initDotEvents=function(){var e=this;!0===e.options.dots&&e.slideCount>e.options.slidesToShow&&t("li",e.$dots).on("click.slick",{message:"index"},e.changeSlide),!0===e.options.dots&&!0===e.options.pauseOnDotsHover&&e.slideCount>e.options.slidesToShow&&t("li",e.$dots).on("mouseenter.slick",t.proxy(e.interrupt,e,!0)).on("mouseleave.slick",t.proxy(e.interrupt,e,!1))},i.prototype.initSlideEvents=function(){var e=this;e.options.pauseOnHover&&(e.$list.on("mouseenter.slick",t.proxy(e.interrupt,e,!0)),e.$list.on("mouseleave.slick",t.proxy(e.interrupt,e,!1)))},i.prototype.initializeEvents=function(){var e=this;e.initArrowEvents(),e.initDotEvents(),e.initSlideEvents(),e.options.autoplay&&e.options.useAutoplayToggleButton&&e.$pauseButton.on("click.slick",e.autoPlayToggleHandler),e.$list.on("touchstart.slick mousedown.slick",{action:"start"},e.swipeHandler),e.$list.on("touchmove.slick mousemove.slick",{action:"move"},e.swipeHandler),e.$list.on("touchend.slick mouseup.slick",{action:"end"},e.swipeHandler),e.$list.on("touchcancel.slick mouseleave.slick",{action:"end"},e.swipeHandler),e.$list.on("click.slick",e.clickHandler),t(document).on(e.visibilityChange,t.proxy(e.visibility,e)),t(window).on("orientationchange.slick.slick-"+e.instanceUid,t.proxy(e.orientationChange,e)),t(window).on("resize.slick.slick-"+e.instanceUid,t.proxy(e.resize,e)),t("[draggable!=true]",e.$slideTrack).on("dragstart",e.preventDefault),t(window).on("load.slick.slick-"+e.instanceUid,e.setPosition),t(e.setPosition)},i.prototype.initUI=function(){var t=this;!0===t.options.arrows&&t.slideCount>t.options.slidesToShow&&(t.$prevArrow.show(),t.$nextArrow.show()),!0===t.options.dots&&t.slideCount>t.options.slidesToShow&&t.$dots.show()},i.prototype.lazyLoad=function(){var e,i,n,s=this;function o(e){t("img[data-lazy]",e).each((function(){var e=t(this),i=t(this).attr("data-lazy"),n=t(this).attr("data-srcset"),o=t(this).attr("data-sizes")||s.$slider.attr("data-sizes"),r=document.createElement("img");r.onload=function(){e.animate({opacity:0},100,(function(){n&&(e.attr("srcset",n),o&&e.attr("sizes",o)),e.attr("src",i).animate({opacity:1},200,(function(){e.removeAttr("data-lazy data-srcset data-sizes").removeClass("slick-loading")})),s.$slider.trigger("lazyLoaded",[s,e,i])}))},r.onerror=function(){e.removeAttr("data-lazy").removeClass("slick-loading").addClass("slick-lazyload-error"),s.$slider.trigger("lazyLoadError",[s,e,i])},r.src=i}))}if(!0===s.options.centerMode?!0===s.options.infinite?n=(i=s.currentSlide+(s.options.slidesToShow/2+1))+s.options.slidesToShow+2:(i=Math.max(0,s.currentSlide-(s.options.slidesToShow/2+1)),n=s.options.slidesToShow/2+1+2+s.currentSlide):(i=s.options.infinite?s.options.slidesToShow+s.currentSlide:s.currentSlide,n=Math.ceil(i+s.options.slidesToShow),!0===s.options.fade&&(i>0&&i--,n<=s.slideCount&&n++)),e=s.$slider.find(".slick-slide").slice(i,n),"anticipated"===s.options.lazyLoad)for(var r=i-1,a=n,l=s.$slider.find(".slick-slide"),h=0;h<s.options.slidesToScroll;h++)r<0&&(r=s.slideCount-1),e=(e=e.add(l.eq(r))).add(l.eq(a)),r--,a++;o(e),s.slideCount<=s.options.slidesToShow?o(s.$slider.find(".slick-slide")):s.currentSlide>=s.slideCount-s.options.slidesToShow?o(s.$slider.find(".slick-cloned").slice(0,s.options.slidesToShow)):0===s.currentSlide&&o(s.$slider.find(".slick-cloned").slice(-1*s.options.slidesToShow))},i.prototype.loadSlider=function(){var t=this;t.setPosition(),t.$slideTrack.css({opacity:1}),t.$slider.removeClass("slick-loading"),t.initUI(),"progressive"===t.options.lazyLoad&&t.progressiveLazyLoad()},i.prototype.next=i.prototype.slickNext=function(){this.changeSlide({data:{message:"next"}})},i.prototype.orientationChange=function(){this.checkResponsive(),this.setPosition()},i.prototype.pause=i.prototype.slickPause=function(){this.autoPlayClear(),this.paused=!0},i.prototype.play=i.prototype.slickPlay=function(){var t=this;t.autoPlay(),t.options.autoplay=!0,t.paused=!1,t.focussed=!1,t.interrupted=!1},i.prototype.postSlide=function(t){var e=this;e.unslicked||(e.$slider.trigger("afterChange",[e,t]),e.animating=!1,e.slideCount>e.options.slidesToShow&&e.setPosition(),e.swipeLeft=null,e.options.autoplay&&e.autoPlay(),e.updateSlideVisibility())},i.prototype.prev=i.prototype.slickPrev=function(){this.changeSlide({data:{message:"previous"}})},i.prototype.preventDefault=function(t){t.preventDefault()},i.prototype.progressiveLazyLoad=function(e){e=e||1;var i,n,s,o,r,a=this,l=t("img[data-lazy]",a.$slider);l.length?(i=l.first(),n=i.attr("data-lazy"),s=i.attr("data-srcset"),o=i.attr("data-sizes")||a.$slider.attr("data-sizes"),(r=document.createElement("img")).onload=function(){s&&(i.attr("srcset",s),o&&i.attr("sizes",o)),i.attr("src",n).removeAttr("data-lazy data-srcset data-sizes").removeClass("slick-loading"),!0===a.options.adaptiveHeight&&a.setPosition(),a.$slider.trigger("lazyLoaded",[a,i,n]),a.progressiveLazyLoad()},r.onerror=function(){e<3?setTimeout((function(){a.progressiveLazyLoad(e+1)}),500):(i.removeAttr("data-lazy").removeClass("slick-loading").addClass("slick-lazyload-error"),a.$slider.trigger("lazyLoadError",[a,i,n]),a.progressiveLazyLoad())},r.src=n):a.$slider.trigger("allImagesLoaded",[a])},i.prototype.refresh=function(e){var i,n,s=this;n=s.slideCount-s.options.slidesToShow,!s.options.infinite&&s.currentSlide>n&&(s.currentSlide=n),s.slideCount<=s.options.slidesToShow&&(s.currentSlide=0),i=s.currentSlide,s.destroy(!0),t.extend(s,s.initials,{currentSlide:i}),s.init(),e||s.changeSlide({data:{message:"index",index:i}},!1)},i.prototype.registerBreakpoints=function(){var e,i,n,s=this,o=s.options.responsive||null;if("array"===t.type(o)&&o.length){for(e in s.respondTo=s.options.respondTo||"window",o)if(n=s.breakpoints.length-1,o.hasOwnProperty(e)){for(i=o[e].breakpoint;n>=0;)s.breakpoints[n]&&s.breakpoints[n]===i&&s.breakpoints.splice(n,1),n--;s.breakpoints.push(i),s.breakpointSettings[i]=o[e].settings}s.breakpoints.sort((function(t,e){return s.options.mobileFirst?t-e:e-t}))}},i.prototype.reinit=function(){var t=this;t.$slides=t.$slideTrack.children(t.options.slide).addClass("slick-slide"),t.slideCount=t.$slides.length,t.currentSlide>=t.slideCount&&0!==t.currentSlide&&(t.currentSlide=t.currentSlide-t.options.slidesToScroll),t.slideCount<=t.options.slidesToShow&&(t.currentSlide=0),t.registerBreakpoints(),t.setProps(),t.setupInfinite(),t.buildArrows(),t.updateArrows(),t.initArrowEvents(),t.buildDots(),t.updateDots(),t.initDotEvents(),t.cleanUpSlideEvents(),t.initSlideEvents(),t.checkResponsive(!1,!0),t.setSlideClasses("number"==typeof t.currentSlide?t.currentSlide:0),t.setPosition(),t.focusHandler(),t.paused=!t.o
1ptions.autoplay,t.autoPlay(),t.$slider.trigger("reInit",[t])},i.prototype.resize=function(){var e=this;t(window).width()!==e.windowWidth&&(clearTimeout(e.windowDelay),e.windowDelay=window.setTimeout((function(){e.windowWidth=t(window).width(),e.checkResponsive(),e.unslicked||e.setPosition()}),50))},i.prototype.removeSlide=i.prototype.slickRemove=function(t,e,i){var n=this;if(t="boolean"==typeof t?!0===(e=t)?0:n.slideCount-1:!0===e?--t:t,n.slideCount<1||t<0||t>n.slideCount-1)return!1;n.unload(),!0===i?n.$slideTrack.children().remove():n.$slideTrack.children(this.options.slide).eq(t).remove(),n.$slides=n.$slideTrack.children(this.options.slide),n.$slideTrack.children(this.options.slide).detach(),n.$slideTrack.append(n.$slides),n.$slidesCache=n.$slides,n.reinit()},i.prototype.setCSS=function(t){var e,i,n=this,s={};!0===n.options.rtl&&(t=-t),e="left"==n.positionProp?Math.ceil(t)+"px":"0px",i="top"==n.positionProp?Math.ceil(t)+"px":"0px",s[n.positionProp]=t,!1===n.transformsEnabled?n.$slideTrack.css(s):(s={},!1===n.cssTransitions?(s[n.animType]="translate("+e+", "+i+")",n.$slideTrack.css(s)):(s[n.animType]="translate3d("+e+", "+i+", 0px)",n.$slideTrack.css(s)))},i.prototype.setDimensions=function(){var t=this;!1===t.options.vertical?!0===t.options.centerMode&&t.$list.css({padding:"0px "+t.options.centerPadding}):(t.$list.height(t.$slides.first().outerHeight(!0)*t.options.slidesToShow),!0===t.options.centerMode&&t.$list.css({padding:t.options.centerPadding+" 0px"})),t.listWidth=t.$list.width(),t.listHeight=t.$list.height(),!1===t.options.vertical&&!1===t.options.variableWidth?(t.slideWidth=Math.ceil(t.listWidth/t.options.slidesToShow),t.$slideTrack.width(Math.ceil(t.slideWidth*t.$slideTrack.children(".slick-slide").length))):!0===t.options.variableWidth?t.$slideTrack.width(5e3*t.slideCount):(t.slideWidth=Math.ceil(t.listWidth),t.$slideTrack.height(Math.ceil(t.$slides.first().outerHeight(!0)*t.$slideTrack.children(".slick-slide").length)));var e=t.$slides.first().outerWidth(!0)-t.$slides.first().width();!1===t.options.variableWidth&&t.$slideTrack.children(".slick-slide").width(t.slideWidth-e)},i.prototype.setFade=function(){var e,i=this;i.$slides.each((function(n,s){e=i.slideWidth*n*-1,!0===i.options.rtl?t(s).css({position:"relative",right:e,top:0,zIndex:i.options.zIndex-2,opacity:0}
1):t(s).css({position:"relative",left:e,top:0,zIndex:i.options.zIndex-2,opacity:0})})),i.$slides.eq(i.currentSlide).css({zIndex:i.options.zIndex-1,opacity:1})},i.prototype.setHeight=function(){var t=this;if(1===t.options.slidesToShow&&!0===t.options.adaptiveHeight&&!1===t.options.vertical){var e=t.$slides.eq(t.currentSlide).outerHeight(!0);t.$list.css("height",e)}},i.prototype.setOption=i.prototype.slickSetOption=function(){var e,i,n,s,o,r=this,a=!1;if("object"===t.type(arguments[0])?(n=arguments[0],a=arguments[1],o="multiple"):"string"===t.type(arguments[0])&&(n=arguments[0],s=arguments[1],a=arguments[2],"responsive"===arguments[0]&&"array"===t.type(arguments[1])?o="responsive":void 0!==arguments[1]&&(o="single")),"single"===o)r.options[n]=s;else if("multiple"===o)t.each(n,(function(t,e){r.options[t]=e}));else if("responsive"===o)for(i in s)if("array"!==t.type(r.options.responsive))r.options.responsive=[s[i]];else{for(e=r.options.responsive.length-1;e>=0;)r.options.responsive[e].breakpoint===s[i].breakpoint&&r.options.responsive.splice(e,1),e--;r.options.responsive.push(s[i])}a&&(r.unload(),r.reinit())},i.prototype.setPosition=function(){var t=this;t.setDimensions(),t.setHeight(),!1===t.options.fade?t.setCSS(t.getLeft(t.currentSlide)):t.setFade(),t.$slider.trigger("setPosition",[t])},i.prototype.setProps=function(){var t=this,e=document.body.style;t.positionProp=!0===t.options.vertical?"top":"left","top"===t.positionProp?t.$slider.addClass("slick-vertical"):t.$slider.removeClass("slick-vertical"),void 0===e.WebkitTransition&&void 0===e.MozTransition&&void 0===e.msTransition||!0===t.options.useCSS&&(t.cssTransitions=!0),t.options.fade&&("number"==typeof t.options.zIndex?t.options.zIndex<3&&(t.options.zIndex=3):t.options.zIndex=t.defaults.zIndex),void 0!==e.OTransform&&(t.animType="OTransform",t.transformType="-o-transform",t.transitionType="OTransition",void 0===e.perspectiveProperty&&void 0===e.webkitPerspective&&(t.animType=!1)),void 0!==e.MozTransform&&(t.animType="MozTransform",t.transformType="-moz-transform",t.transitionType="MozTransition",void 0===e.perspectiveProperty&&void 0===e.MozPerspective&&(t.animType=!1)),void 0!==e.webkitTransform&&(t.animType="webkitTransform",t.transformType="-webkit-transform",t.transitionType="webkitTransition",void 0===e.perspectiveProperty&&void 0===e.webkitPerspective&&(t.animType=!1)),void 0!==e.msTransform&&(t.animType="msTransform",t.transformType="-ms-transform",t.transitionType="msTransition",void 0===e.msTransform&&(t.animType=!1)),void 0!==e.transform&&!1!==t.animType&&(t.animType="transform",t.transformType="transform",t.transitionType="transition"),t.transformsEnabled=t.options.useTransform&&null!==t.animType&&!1!==t.animType},i.prototype.setSlideClasses=function(e){var i,n,s,o,r=this;if(n=r.$slider.find(".slick-slide").removeClass("slick-active slick-center slick-current").attr("aria-hidden","true").attr("aria-label",(function(){return t(this).attr("aria-label").replace(" (centered)","")})),r.$slides.eq(e).addClass("slick-current"),!0===r.options.centerMode){var a=r.options.slidesToShow%2==0?1:0;i=Math.floor(r.options.slidesToShow/2),!0===r.options.infinite&&(e>=i&&e<=r.slideCount-1-i?r.$slides.slice(e-i+a,e+i+1).addClass("slick-active").removeAttr("aria-hidden"):(s=r.options.slidesToShow+e,n.slice(s-i+1+a,s+i+2).addClass("slick-active").removeAttr("aria-hidden")),0===e?n.eq(r.options.slidesToShow+r.slideCount+1).addClass("slick-center").attr("aria-label",(function(){return t(this).attr("aria-label")+" (centered)"})):e===r.slideCount-1&&n.eq(r.options.slidesToShow).addClass("slick-center").attr("aria-label",(function(){return t(this).attr("aria-label")+" (centered)"}))),r.$slides.eq(e).addClass("slick-center").attr("aria-label",(function(){return t(this).attr("aria-label")+" (centered)"}))}else e>=0&&e<=r.slideCount-r.options.slidesToShow?r.$slides.slice(e,e+r.options.slidesToShow).addClass("slick-active").removeAttr("aria-hidden"):n.length<=r.options.slidesToShow?n.addClass("slick-active").removeAttr("aria-hidden"):(o=r.slideCount%r.options.slidesToShow,s=!0===r.options.infinite?r.options.slidesToShow+e:e,r.options.slidesToShow==r.options.slidesToScroll&&r.slideCount-e<r.o
1ptions.slidesToShow?n.slice(s-(r.options.slidesToShow-o),s+o).addClass("slick-active").removeAttr("aria-hidden"):n.slice(s,s+r.options.slidesToShow).addClass("slick-active").removeAttr("aria-hidden"));"ondemand"!==r.options.lazyLoad&&"anticipated"!==r.options.lazyLoad||r.lazyLoad()},i.prototype.setupInfinite=function(){var e,i,n,s=this;if(!0===s.options.fade&&(s.options.centerMode=!1),!0===s.options.infinite&&!1===s.options.fade&&(i=null,s.slideCount>s.options.slidesToShow)){for(n=!0===s.options.centerMode?s.options.slidesToShow+1:s.options.slidesToShow,e=s.slideCount;e>s.slideCount-n;e-=1)i=e-1,t(s.$slides[i]).clone(!0).attr("id","").attr("data-slick-index",i-s.slideCount).prependTo(s.$slideTrack).addClass("slick-cloned");for(e=0;e<n+s.slideCount;e+=1)i=e,t(s.$slides[i]).clone(!0).attr("id","").attr("data-slick-index",i+s.slideCount).appendTo(s.$slideTrack).addClass("slick-cloned");s.$slideTrack.find(".slick-cloned").find("[id]").each((function(){t(this).attr("id","")}))}},i.prototype.interrupt=function(t){t||this.autoPlay(),this.interrupted=t},i.prototype.selectHandler=function(e){var i=this,n=t(e.target).is(".slick-slide")?t(e.target):t(e.target).parents(".slick-slide"),s=parseInt(n.attr("data-slick-index"));s||(s=0),i.slideCount<=i.options.slidesToShow?i.slideHandler(s,!1,!0):i.slideHandler(s)},i.prototype.slideHandler=function(t,e,i){var n,s,o,r,a,l=null,h=this;if(e=e||!1,!(!0===h.animating&&!0===h.options.waitForAnimate||!0===h.options.fade&&h.currentSlide===t))if(!1===e&&h.asNavFor(t),n=t,l=h.getLeft(n),r=h.getLeft(h.currentSlide),h.currentLeft=null===h.swipeLeft?r:h.swipeLeft,!1===h.options.infinite&&!1===h.options.centerMode&&(t<0||t>h.getDotCount()*h.options.slidesToScroll))!1===h.options.fade&&(n=h.currentSlide,!0!==i&&h.slideCount>h.options.slidesToShow?h.animateSlide(r,(function(){h.postSlide(n)})):h.postSlide(n));else if(!1===h.options.infinite&&!0===h.options.centerMode&&(t<0||t>h.slideCount-h.options.slidesToScroll))!1===h.options.fade&&(n=h.currentSlide,!0!==i&&h.slideCount>h.options.slidesToShow?h.animateSlide(r,(function(){h.postSlide(n)})):h.postSlide(n));else{if(h.options.autoplay&&clearInterval(h.autoPlayTimer),s=n<0?h.slideCount%h.options.slidesToScroll!=0?h.slideCount-h.slideCount%h.options.slidesToScroll:h.slideCount+n:n>=h.slideCount?h.slideCount%h.options.slidesToScroll!=0?0:n-h.slideCount:n,h.animating=!0,h.$slider.trigger("beforeChange",[h,h.currentSlide,s]),o=h.currentSlide,h.currentSlide=s,h.setSlideClasses(h.currentSlide),h.options.asNavFor&&(a=(a=h.getNavTarget()).slick("getSlick")).slideCount<=a.options.slidesToShow&&a.setSlideClasses(h.currentSlide),h.updateDots(),h.updateArrows(),!0===h.options.fade)return!0!==i?(h.fadeSlideOut(o),h.fadeSlide(s,(function(){h.postSlide(s)}))):h.postSlide(s),void h.animateHeight();!0!==i&&h.slideCount>h.options.slidesToShow?h.animateSlide(l,(function(){h.postSlide(s)})):h.postSlide(s)}},i.prototype.startLoad=function(){var t=this;!0===t.options.arrows&&t.slideCount>t.options.slidesToShow&&(t.$prevArrow.hide(),t.$nextArrow.hide()),!0===t.options.dots&&t.slideCount>t.options.slidesToShow&&t.$dots.hide(),t.$slider.addClass("slick-loading")},i.prototype.swipeDirection=function(){var t,e,i,n,s=this;return t=s.touchObject.startX-s.touchObject.curX,e=s.touchObject.startY-s.touchObject.curY,i=Math.atan2(e,t),(n=Math.round(180*i/Math.PI))<0&&(n=360-Math.abs(n)),n<=45&&n>=0||n<=360&&n>=315?!1===s.options.rtl?"left":"right":n>=135&&n<=225?!1===s.options.rtl?"right":"left":!0===s.options.verticalSwiping?n>=35&&n<=135?"down":"up":"vertical"},i.prototype.swipeEnd=function(t){var e,i,n=this;if(n.dragging=!1,n.swiping=!1,n.scrolling)return n.scrolling=!1,!1;if(n.interrupted=!1,n.shouldClick=!(n.touchObject.swipeLength>10),void 0===n.touchObject.curX)return!1;if(!0===n.touchObject.edgeHit&&n.$slider.trigger("edge",[n,n.swipeDirection()]),n.touchObject.swipeLength>=n.touchObject.minSwipe){switch(i=n.swipeDirection()){case"left":case"down":e=n.options.swipeToSlide?n.checkNavigable(n.currentSlide+n.getSlideCount()):n.currentSlide+n.getSlideCount(),n.currentDirection=0;break;case"right":case"up":e=n.options.swipeToSlide?n.checkNavigable(n.currentSlide-n.getSlideCount()):n.currentSlide-n.getSlideCount(),n.currentDirection=1}"vertical"!=i&&(n.slideHandler(e),n.touchObject={},n.$slider.trigger("swipe",[n,i]))}else n.touchObject.startX!==n.touchObject.curX&&(n.slideHandler(n.currentSlide),n.touchObject={})},i.prototype.swipeHandler=function(t){var e=this;if(!(!1===e.options.swipe||"ontouchend"in document&&!1===e.options.swipe||!1===e.options.draggable&&-1!==t.type.indexOf("mou
1se")))switch(e.touchObject.fingerCount=t.originalEvent&&void 0!==t.originalEvent.touches?t.originalEvent.touches.length:1,e.touchObject.minSwipe=e.listWidth/e.options.touchThreshold,!0===e.options.verticalSwiping&&(e.touchObject.minSwipe=e.listHeight/e.options.touchThreshold),t.data.action){case"start":e.swipeStart(t);break;case"move":e.swipeMove(t);break;case"end":e.swipeEnd(t)}},i.prototype.swipeMove=function(t){var e,i,n,s,o,r,a=this;return o=void 0!==t.originalEvent?t.originalEvent.touches:null,!(!a.dragging||a.scrolling||o&&1!==o.length)&&(e=a.getLeft(a.currentSlide),a.touchObject.curX=void 0!==o?o[0].pageX:t.clientX,a.touchObject.curY=void 0!==o?o[0].pageY:t.clientY,a.touchObject.swipeLength=Math.round(Math.sqrt(Math.pow(a.touchObject.curX-a.touchObject.startX,2))),r=Math.round(Math.sqrt(Math.pow(a.touchObject.curY-a.touchObject.startY,2))),!a.options.verticalSwiping&&!a.swiping&&r>4?(a.scrolling=!0,!1):(!0===a.options.verticalSwiping&&(a.touchObject.swipeLength=r),i=a.swipeDirection(),void 0!==t.originalEvent&&a.touchObject.swipeLength>4&&(a.swiping=!0,t.preventDefault()),s=(!1===a.options.rtl?1:-1)*(a.touchObject.curX>a.touchObject.startX?1:-1),!0===a.options.verticalSwiping&&(s=a.touchObject.curY>a.touchObject.startY?1:-1),n=a.touchObject.swipeLength,a.touchObject.edgeHit=!1,!1===a.options.infinite&&(0===a.currentSlide&&"right"===i||a.currentSlide>=a.getDotCount()&&"left"===i)&&(n=a.touchObject.swipeLength*a.options.edgeFriction,a.touchObject.edgeHit=!0),!1===a.options.vertical?a.swipeLeft=e+n*s:a.swipeLeft=e+n*(a.$list.height()/a.listWidth)*s,!0===a.options.verticalSwiping&&(a.swipeLeft=e+n*s),!0!==a.options.fade&&!1!==a.options.touchMove&&(!0===a.animating?(a.swipeLeft=null,!1):void a.setCSS(a.swipeLeft))))},i.prototype.swipeStart=function(t){var e,i=this;if(i.interrupted=!0,1!==i.touchObject.fingerCount||i.slideCount<=i.options.slidesToShow)return i.touchObject={},!1;void 0!==t.originalEvent&&void 0!==t.originalEvent.touches&&(e=t.originalEvent.touches[0]),i.touchObject.startX=i.touchObject.curX=void 0!==e?e.pageX:t.clientX,i.touchObject.startY=i.touchObject.curY=void 0!==e?e.pageY:t.clientY,i.dragging=!0},i.prototype.unfilterSlides=i.prototype.slickUnfilter=function(){var t=this;null!==t.$slidesCache&&(t.unload(),t.$slideTrack.children(this.options.slide).detach(),t.$slidesCache.appendTo(t.$slideTrack),t.reinit())},i.prototype.unload=function(){var e=this;t(".slick-cloned",e.$slider).remove(),e.$dots&&e.$dots.remove(),e.$prevArrow&&e.htmlExpr.test(e.options.prevArrow)&&e.$prevArrow.remove(),e.$nextArrow&&e.htmlExpr.test(e.options.nextArrow)&&e.$nextArrow.remove(),e.$slides.removeClass("slick-slide slick-active slick-visible slick-current").attr("aria-hidden","true").css("width","")},i.prototype.unslick=function(t){var e=this;e.$slider.trigger("unslick",[e,t]),e.destroy()},i.prototype.updateArrows=function(){var t=this;Math.floor(t.options.slidesToShow/2),!0===t.options.arrows&&t.slideCount>t.options.slidesToShow&&!t.options.infinite&&(t.$prevArrow.removeClass("slick-disabled").prop("disabled",!1),t.$nextArrow.removeClass("slick-disabled").prop("disabled",!1),0===t.currentSlide?(t.$prevArrow.addClass("slick-disabled").prop("disabled",!0),t.$nextArrow.removeClass("slick-disabled").prop("disabled",!1)):(t.currentSlide>=t.slideCount-t.options.slidesToShow&&!1===t.options.centerMode||t.currentSlide>=t.slideCount-1&&!0===t.options.centerMode)&&(t.$nextArrow.addClass("slick-disabled").prop("disabled",!0),t.$prevArrow.removeClass("slick-disabled").prop("disabled",!1)))},i.prototype.updateDots=function(){var t=this;null!==t.$dots&&(t.$dots.find("li").removeClass("slick-active").find("button").removeAttr("aria-current").end().end(),t.$dots.find("li").eq(Math.floor(t.currentSlide/t.options.slidesToScroll)).addClass("slick-active").find("button").attr("aria-current",!0).end().end())},i.prototype.updateSlideVisibility=function(){this.$slideTrack.find(".slick-slide").attr("aria-hidden","true").find("a, input, button, select").attr("tabindex","-1"),this.$slideTrack.find(".slick-active").removeAttr("aria-hidden").find("a, input, button, select").removeAttr("tabindex")},i.prototype.visibility=function(){var t=this;t.options.autoplay&&(document[t.hidden]?t.interrupted=!0:t.interrupted=!1)},t.fn.slick=function(){var t,e,n=this,s=arguments[0],o=Array.prototype.slice.call(arguments,1
1),r=n.length;for(t=0;t<r;t++)if("object"==typeof s||void 0===s?n[t].slick=new i(n[t],s):e=n[t].slick[s].apply(n[t].slick,o),void 0!==e)return e;return n}},void 0===(o=n.apply(e,s))||(t.exports=o)}()},4557:function(t,e,i){var n,s=i(5311);n=s,(window.app=window.app||{}).colorFadePost=function(t){var e=n(t),i=e.find(".entry-header-post");function s(){var t="js-fade-grey-to-light",s=i.outerHeight()/3,o=n(window).height(),r=e.find(".teaser-next").first(),a=e.find("footer").first();n(window).on("scroll",(function(){var i=n(window).scrollTop();i<=s&&e.removeClass(t),i>=s&&e.addClass(t),r.length?o+i>r.position().top+r.outerHeight()/3&&e.removeClass(t):o+i>a.position().top+a.outerHeight()/3&&e.removeClass(t)}))}s(),n(window).on("resize onorientationchange",s)}},3557:function(t,e,i){var n,s=i(5311);n=s,(window.app=window.app||{}).colorFadeProject=function(t){var e=n(t),i=e.find(".entry-header-project");function s(){var t="js-fade-dark-to-light",s=i.outerHeight()/3,o=n(window).height(),r=e.find(".teaser-next").first(),a=e.find("footer").first();n(window).on("scroll",(function(){var i=n(window).scrollTop();i<=s&&e.removeClass(t),i>=s&&e.addClass(t),r.length?o+i>r.position().top+r.outerHeight()/3&&e.removeClass(t):o+i>a.position().top+a.outerHeight()/3&&e.removeClass(t)}))}s(),n(window).on("resize onorientationchange",s)}},8704:function(t,e,i){var n,s=i(5311);n=s,(window.app=window.app||{}).hello=function(t){var e,i=n(t),s=i.data("config"),o=i.find(".random-greeting");i.on("click",(function(t){n(t.currentTarget).is(":button")&&i.find(".btn__text").text(s.clicked)})),setInterval((function(){s&&s.greetings&&(e=s.greetings[Math.floor(Math.random()*s.greetings.length)],o.html(e))}),500)}},2282:function(t,e,i){var n,s=i(5311);n=s,(window.app=window.app||{}).homeLogo=function(t){var e=n(t),i="js--hidden";function s(){var t=.95*window.getComputedStyle(document.body).getPropertyValue("--header-home-brand").match(/\d/g).join("");n(document).scrollTop()>=t?(e.removeClass(i),e.removeAttr("disabled"),e.removeAttr("tabindex")):(e.addClass(i),e.attr("disabled",!0),e.attr("tabindex","-1"))}n("body").hasClass("home")&&(e.addClass(i),e.attr("disabled",!0),e.attr("tabindex","-1"),n(document).on("scroll",(function(){s()})),n(window).on("resize",(function(){s()})))}},2671:function(t,e,i){var n,s=i(5311);n=s,(window.app=window.app||{}).oembed=function(t){var e=n(t),i=e.find(".js-consent-button"),s=e.data("cookiebot"),o=e.data("source"),r=e.data("type");function a(t){void 0===t&&(t=e);var i=t.find("template");t.find(".oembed-component__content").html(i.html()),"video"===r?function(t){var e=t.find(".oembed-video");e.on("click",(function(){!function(t){var e=t.find("iframe"),i=e.attr("data-src");e.attr("src",i+"&autoplay=1&disablekb=1"),t.find(".btn--js-video-play").remove(),t.find(".oembed-video__thumbnail").remove()}(e)}))}(t):"audio"===r&&function(t){var e=t.find(".oembed-audio"),i=e.find("iframe").attr("title");void 0!==i&&i.length>0&&e.find(".oembed-audio--js-title").text(i),e.on("click",(function(){!function(t){var e=t.find("iframe"),i=e.attr("data-src");e.attr("src",i),t.find(".btn--js-audio-play").remove(),t.find(".oembed-audio--js-title").remove()}(e)}))}(t)}s&&"undefined"!=typeof Cookiebot?Cookiebot.consent.marketing?a():(n(window).on("CookiebotOnAccept",(function(){a()})),i.on("click",(function(){Cookiebot.show()}))):(i.on("click",(function(){window.localStorage.setItem(o,!0),a(),n('[data-source="'.concat(o,'"]')).each((function(){a(n(this))}))})),window.localStorage.getItem(o)&&a())}},2:function(t,e,i){var n,s=i(5311);n=s,(window.app=window.app||{}).skiplink=function(t){n(t).on("click",(function(){var t=n(this).attr("href");n("html, body").animate({scrollTop:n(t).offset().top},200)}))}},1074:function(t,e,i){var n,s=i(5311);n=s,(window.app=window.app||{}).slidingText=function(t){var e=n(t),i=e.find(".sliding-text__inner");function s(){var t;e.css("--sliding-text-animation-duration","".concat((t=e.width(),i.first().width()/t*40),"s"))}s(),n(window).on("resize",(function(){s()}))}},5291:function(t,e,i){var n,s=i(5311);n=s,(window.app=window.app||{}).socials=function(t){var e=n(t).find(".js--share"),i="http://twitter.com/share?url=",s="https://www.facebook.com/sharer/sharer.php?u=",o="https://plus.google.com/share?url=",r="https://www.linkedin.com/shareArticle?mini=true&url=",a="https://api.whatsapp.com/se
1nd?text=";e.on("click",(function(t){var e=n(this).data("config")||{},l=e.type,h=e.shareText||i18n.socialShare,d="".concat(window.location.href,"&text=").concat(h),c={twitter:"".concat(i).concat(d),facebook:"".concat(s).concat(d),googleplus:"".concat(o).concat(d),linkedin:"".concat(r).concat(d),whatsapp:"".concat(a).concat(h,": ").concat(window.location.href)};if("email"===l)n(this).attr("href","mailto:?subject=".concat(h,"&body=").concat(window.location.href));else if(void 0!==c[l]){var u=window.screen.height/2-225;window.open(c[l],c[l].charAt(0).toUpperCase()+c[l].slice(1),"height=".concat(450,", width=").concat(550," top=").concat(u," toolbar=0, location=0, menubar=0, directories=0, scrollbars=0")),t.preventDefault()}}))}},7090:function(t,e,i){var n,s=i(5311);function o(t,e){var i="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!i){if(Array.isArray(t)||(i=function(t,e){if(t){if("string"==typeof t)return r(t,e);var i=Object.prototype.toString.call(t).slice(8,-1);return"Object"===i&&t.constructor&&(i=t.constructor.name),"Map"===i||"Set"===i?Array.from(t):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?r(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){i&&(t=i);var n=0,s=function(){};return{s,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:s}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,l=!1;return{s:function(){i=i.call(t)},n:function(){var t=i.next();return a=t.done,t},e:function(t){l=!0,o=t},f:function(){try{a||null==i.return||i.return()}finally{if(l)throw o}}}}function r(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,n=new Array(e);i<e;i++)n[i]=t[i];return n}n=s,(window.app=window.app||{}).table=function(t){var e=n(t),i=e.find("th"),s=e.find("tbody tr, tfoot tr");!function(){var t,e=[],r=o(i);try{for(r.s();!(t=r.n()).done;){var a=t.value;e.push(n(a).text())}}catch(t){r.e(t)}finally{r.f()}var l,h=o(s);try{for(h.s();!(l=h.n()).done;)for(var d=l.value,c=n(d).find("td"),u=0;u<c.length;u++)n(c[u]).attr("data-th",e[u])}catch(t){h.e(t)}finally{h.f()}}()}},5290:function(t,e,i){var n,s=i(5311);n=s,(window.app=window.app||{}).tabs=function(t){var e=n(t),i=e.find(".tab-list__link"),s=e.find(".tab-list__section");function o(t,e){e.focus(),e.attr("aria-selected",!0),e.attr("tabindex",0),t.removeAttr("aria-selected"),t.attr("tabindex",-1),s.attr("aria-hidden",!0);var i=e.attr("href");s.each((function(t,e){"#".concat(n(e).attr("id"))===i&&n(this).attr("aria-hidden",!1)}))}i.on("click",(function(t){if(t.preventDefault(),!n(this).attr("aria-selected")){var i=e.find("[aria-selected]");t.currentTarget!==i&&o(i,n(t.currentTarget))}})),i.on("keydown",(function(t){var e=n(t.currentTarget);if(37===t.which){var i=e.parent().prev();i.hasClass("tab-list__item")&&(e.blur(),i.find(".tab-list__link").focus(),o(e,i.find(".tab-list__link")))}if(39===t.which){var s=e.parent().next();s.hasClass("tab-list__item")&&(e.blur(),s.find(".tab-list__link").focus(),o(e,s.find(".tab-list__link")))}}))}},8509:function(t,e,i){"use strict";i.r(e),i.d(e,{clearAllBodyScrollLocks:function(){return f},disableBodyScroll:function(){return g},enableBodyScroll:function(){return m}});var n=!1;if("undefined"!=typeof window){var s={get passive(){n=!0}};window.addEventListener("testPassive",null,s),window.removeEventListener("testPassive",null,s)}var o="undefined"!=typeof window&&window.navigator&&window.navigator.platform&&(/iP(ad|hone|od)/.test(window.navigator.platform)||"MacIntel"===window.navigator.platform&&window.navigator.maxTouchPoints>1),r=[],a=!1,l=-1,h=void 0,d=void 0,c=function(t){return r.some((function(e){return!(!e.options.allowTouchMove||!e.options.allowTouchMove(t))}))},u=function(t){var e=t||window.event;return!!c(e.target)||e.touches.length>1||(e.preventDefault&&e.preventDefault(),!1)},p=function(){void 0!==d&&(document.body.style.paddingRight=d,d=void 0),void 0!==h&&(document.body.style.overflow=h,h=void 0)},g=function(t,e){if(t){if(!r.some((function(e){return e.targetElement===t}
1))){var i={targetElement:t,options:e||{}};r=[].concat(function(t){if(Array.isArray(t)){for(var e=0,i=Array(t.length);e<t.length;e++)i[e]=t[e];return i}return Array.from(t)}(r),[i]),o?(t.ontouchstart=function(t){1===t.targetTouches.length&&(l=t.targetTouches[0].clientY)},t.ontouchmove=function(e){1===e.targetTouches.length&&function(t,e){var i=t.targetTouches[0].clientY-l;!c(t.target)&&(e&&0===e.scrollTop&&i>0||function(t){return!!t&&t.scrollHeight-t.scrollTop<=t.clientHeight}(e)&&i<0?u(t):t.stopPropagation())}(e,t)},a||(document.addEventListener("touchmove",u,n?{passive:!1}:void 0),a=!0)):function(t){if(void 0===d){var e=!!t&&!0===t.reserveScrollBarGap,i=window.innerWidth-document.documentElement.clientWidth;e&&i>0&&(d=document.body.style.paddingRight,document.body.style.paddingRight=i+"px")}void 0===h&&(h=document.body.style.overflow,document.body.style.overflow="hidden")}(e)}}else console.error("disableBodyScroll unsuccessful - targetElement must be provided when calling disableBodyScroll on IOS devices.")},f=function(){o?(r.forEach((function(t){t.targetElement.ontouchstart=null,t.targetElement.ontouchmove=null})),a&&(document.removeEventListener("touchmove",u,n?{passive:!1}:void 0),a=!1),l=-1):p(),r=[]},m=function(t){t?(r=r.filter((function(e){return e.targetElement!==t})),o?(t.ontouchstart=null,t.ontouchmove=null,a&&0===r.length&&(document.removeEventListener("touchmove",u,n?{passive:!1}:void 0),a=!1)):r.length||p()):console.error("enableBodyScroll unsuccessful - targetElement must be provided when calling enableBodyScroll on IOS devices.")}},2582:function(t){t.exports=function(){"use strict";function t(t,n,s,o,r){!function t(i,n,s,o,r){for(;o>s;){if(o-s>600){var a=o-s+1,l=n-s+1,h=Math.log(a),d=.5*Math.exp(2*h/3),c=.5*Math.sqrt(h*d*(a-d)/a)*(l-a/2<0?-1:1);t(i,n,Math.max(s,Math.floor(n-l*d/a+c)),Math.min(o,Math.floor(n+(a-l)*d/a+c)),r)}var u=i[n],p=s,g=o;for(e(i,s,n),r(i[o],u)>0&&e(i,s,o);p<g;){for(e(i,p,g),p++,g--;r(i[p],u)<0;)p++;for(;r(i[g],u)>0;)g--}0===r(i[s],u)?e(i,s,g):e(i,++g,o),g<=n&&(s=g+1),n<=g&&(o=g-1)}}(t,n,s||0,o||t.length-1,r||i)}function e(t,e,i){var n=t[e];t[e]=t[i],t[i]=n}function i(t,e){return t<e?-1:t>e?1:0}var n=function(t){void 0===t&&(t=9),this._maxEntries=Math.max(4,t),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),this.clear()};function s(t,e,i){if(!i)return e.indexOf(t);for(var n=0;n<e.length;n++)if(i(t,e[n]))return n;return-1}function o(t,e){r(t,0,t.children.length,e,t)}function r(t,e,i,n,s){s||(s=g(null)),s.minX=1/0,s.minY=1/0,s.maxX=-1/0,s.maxY=-1/0;for(var o=e;o<i;o++){var r=t.children[o];a(s,t.leaf?n(r):r)}return s}function a(t,e){return t.minX=Math.min(t.minX,e.minX),t.minY=Math.min(t.minY,e.minY),t.maxX=Math.max(t.maxX,e.maxX),t.maxY=Math.max(t.maxY,e.maxY),t}function l(t,e){return t.minX-e.minX}function h(t,e){return t.minY-e.minY}function d(t){return(t.maxX-t.minX)*(t.maxY-t.minY)}function c(t){return t.maxX-t.minX+(t.maxY-t.minY)}function u(t,e){return t.minX<=e.minX&&t.minY<=e.minY&&e.maxX<=t.maxX&&e.maxY<=t.maxY}function p(t,e){return e.minX<=t.maxX&&e.minY<=t.maxY&&e.maxX>=t.minX&&e.maxY>=t.minY}function g(t){return{children:t,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function f(e,i,n,s,o){for(var r=[i,n];r.length;)if(!((n=r.pop())-(i=r.pop())<=s)){var a=i+Math.ceil((n-i)/s/2)*s;t(e,a,i,n,o),r.push(i,a,a,n)}}return n.prototype.all=function(){return this._all(this.data,[])},n.prototype.search=function(t){var e=this.data,i=[];if(!p(t,e))return i;for(var n=this.toBBox,s=[];e;){for(var o=0;o<e.children.length;o++){var r=e.children[o],a=e.leaf?n(r):r;p(t,a)&&(e.leaf?i.push(r):u(t,a)?this._all(r,i):s.push(r))}e=s.pop()}return i},n.prototype.collides=function(t){var e=this.data;if(!p(t,e))return!1;for(var i=[];e;){for(var n=0;n<e.children.length;n++){var s=e.children[n],o=e.leaf?this.toBBox(s):s;
vendor: 4,093 bytes, line 1
1if(p(t,o)){if(e.leaf||u(t,o))return!0;i.push(s)}}e=i.pop()}return!1},n.prototype.load=function(t){if(!t||!t.length)return this;if(t.length<this._minEntries){for(var e=0;e<t.length;e++)this.insert(t[e]);return this}var i=this._build(t.slice(),0,t.length-1,0);if(this.data.children.length)if(this.data.height===i.height)this._splitRoot(this.data,i);else{if(this.data.height<i.height){var n=this.data;this.data=i,i=n}this._insert(i,this.data.height-i.height-1,!0)}else this.data=i;return this},n.prototype.insert=function(t){return t&&this._insert(t,this.data.height-1),this},n.prototype.clear=function(){return this.data=g([]),this},n.prototype.remove=function(t,e){if(!t)return this;for(var i,n,o,r=this.data,a=this.toBBox(t),l=[],h=[];r||l.length;){if(r||(r=l.pop(),n=l[l.length-1],i=h.pop(),o=!0),r.leaf){var d=s(t,r.children,e);if(-1!==d)return r.children.splice(d,1),l.push(r),this._condense(l),this}o||r.leaf||!u(r,a)?n?(i++,r=n.children[i],o=!1):r=null:(l.push(r),h.push(i),i=0,n=r,r=r.children[0])}return this},n.prototype.toBBox=function(t){return t},n.prototype.compareMinX=function(t,e){return t.minX-e.minX},n.prototype.compareMinY=function(t,e){return t.minY-e.minY},n.prototype.toJSON=function(){return this.data},n.prototype.fromJSON=function(t){return this.data=t,this},n.prototype._all=function(t,e){for(var i=[];t;)t.leaf?e.push.apply(e,t.children):i.push.apply(i,t.children),t=i.pop();return e},n.prototype._build=function(t,e,i,n){var s,r=i-e+1,a=this._maxEntries;if(r<=a)return o(s=g(t.slice(e,i+1)),this.toBBox),s;n||(n=Math.ceil(Math.log(r)/Math.log(a)),a=Math.ceil(r/Math.pow(a,n-1))),(s=g([])).leaf=!1,s.height=n;var l=Math.ceil(r/a),h=l*Math.ceil(Math.sqrt(a));f(t,e,i,h,this.compareMinX);for(var d=e;d<=i;d+=h){var c=Math.min(d+h-1,i);f(t,d,c,l,this.compareMinY);for(var u=d;u<=c;u+=l){var p=Math.min(u+l-1,c);s.children.push(this._build(t,u,p,n-1))}}return o(s,this.toBBox),s},n.prototype._chooseSubtree=function(t,e,i,n){for(;n.push(e),!e.leaf&&n.length-1!==i;){for(var s=1/0,o=1/0,r=void 0,a=0;a<e.children.length;a++){var l=e.children[a],h=d(l),c=(u=t,p=l,(Math.max(p.maxX,u.maxX)-Math.min(p.minX,u.minX))*(Math.max(p.maxY,u.maxY)-Math.min(p.minY,u.minY))-h);c<o?(o=c,s=h<s?h:s,r=l):c===o&&h<s&&(s=h,r=l)}e=r||e.children[0]}var u,p;return e},n.prototype._insert=function(t,e,i){var n=i?t:this.toBBox(t),s=[],o=this._chooseSubtree(n,this.data,e,s);for(o.children.push(t),a(o,n);e>=0&&s[e].children.length>this._maxEntries;)this._split(s,e),e--;this._adjustParentBBoxes(n,s,e)},n.prototype._split=function(t,e){var i=t[e],n=i.children.length,s=this._minEntries;this._chooseSplitAxis(i,s,n);var r=this._chooseSplitIndex(i,s,n),a=g(i.children.splice(r,i.children.length-r));a.height=i.height,a.leaf=i.leaf,o(i,this.toBBox),o(a,this.toBBox),e?t[e-1].children.push(a):this._splitRoot(i,a)},n.prototype._splitRoot=function(t,e){this.data=g([t,e]),this.data.height=t.height+1,this.data.leaf=!1,o(this.data,this.toBBox)},n.prototype._chooseSplitIndex=function(t,e,i){for(var n,s,o,a,l,h,c,u=1/0,p=1/0,g=e;g<=i-e;g++){var f=r(t,0,g,this.toBBox),m=r(t,g,i,this.toBBox),_=(s=f,o=m,void 0,void 0,void 0,void 0,a=Math.max(s.minX,o.minX),l=Math.max(s.minY,o.minY),h=Math.min(s.maxX,o.maxX),c=Math.min(s.maxY,o.maxY),Math.max(0,h-a)*Math.max(0,c-l)),y=d(f)+d(m);_<u?(u=_,n=g,p=y<p?y:p):_===u&&y<p&&(p=y,n=g)}return n||i-e},n.prototype._chooseSplitAxis=function(t,e,i){var n=t.leaf?this.compareMinX:l,s=t.leaf?this.compareMinY:h;this._allDistMargin(t,e,i,n)<this._allDistMargin(t,e,i,s)&&t.children.sort(n)},n.prototype._allDistMargin=function(t,e,i,n){t.children.sort(n);for(var s=this.toBBox,o=r(t,0,e,s),l=r(t,i-e,i,s),h=c(o)+c(l),d=e;d<i-e;d++){var u=t.children[d];a(o,t.leaf?s(u):u),h+=c(o)}for(var p=i-e-1;p>=e;p--){var g=t.children[p];a(l,t.leaf?s(g):g),h+=c(l)}return h},n.prototype._adjustParentBBoxes=function(t,e,i){for(var n=i;n>=0;n--)a(e[n],t)},n.prototype._condense=function(t){for(var e=t.length-1,i=void 0;e>=0;e--)0===t[e].children.length?e>0?(i=t[e-1].children).splice(i.indexOf(t[e]),1):this.clear():o(t[e],this.toBBox)},n}()},8280:function(t,e,i){"use strict";
vendor: 61,958 bytes, line 1
1Object.defineProperty(e,"__esModule",{value:!0}),e.ZodError=e.quotelessJson=e.ZodIssueCode=void 0;const n=i(9110);e.ZodIssueCode=n.util.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),e.quotelessJson=t=>JSON.stringify(t,null,2).replace(/"([^"]+)":/g,"$1:");class s extends Error{constructor(t){super(),this.issues=[],this.addIssue=t=>{this.issues=[...this.issues,t]},this.addIssues=(t=[])=>{this.issues=[...this.issues,...t]};const e=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,e):this.__proto__=e,this.name="ZodError",this.issues=t}get errors(){return this.issues}format(t){const e=t||function(t){return t.message},i={_errors:[]},n=t=>{for(const s of t.issues)if("invalid_union"===s.code)s.unionErrors.map(n);else if("invalid_return_type"===s.code)n(s.returnTypeError);else if("invalid_arguments"===s.code)n(s.argumentsError);else if(0===s.path.length)i._errors.push(e(s));else{let t=i,n=0;for(;n<s.path.length;){const i=s.path[n];n===s.path.length-1?(t[i]=t[i]||{_errors:[]},t[i]._errors.push(e(s))):t[i]=t[i]||{_errors:[]},t=t[i],n++}}};return n(this),i}toString(){return this.message}get message(){return JSON.stringify(this.issues,n.util.jsonStringifyReplacer,2)}get isEmpty(){return 0===this.issues.length}flatten(t=(t=>t.message)){const e={},i=[];for(const n of this.issues)n.path.length>0?(e[n.path[0]]=e[n.path[0]]||[],e[n.path[0]].push(t(n))):i.push(t(n));return{formErrors:i,fieldErrors:e}}get formErrors(){return this.flatten()}}e.ZodError=s,s.create=t=>new s(t)},6996:function(t,e,i){"use strict";var n=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.getErrorMap=e.setErrorMap=e.defaultErrorMap=void 0;const s=n(i(9349));e.defaultErrorMap=s.default;let o=s.default;e.setErrorMap=function(t){o=t},e.getErrorMap=function(){return o}},6349:function(t,e,i){"use strict";var n=this&&this.__createBinding||(Object.create?function(t,e,i,n){void 0===n&&(n=i),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[i]}})}:function(t,e,i,n){void 0===n&&(n=i),t[n]=e[i]}),s=this&&this.__exportStar||function(t,e){for(var i in t)"default"===i||Object.prototype.hasOwnProperty.call(e,i)||n(e,t,i)};Object.defineProperty(e,"__esModule",{value:!0}),s(i(6996),e),s(i(3187),e),s(i(116),e),s(i(9110),e),s(i(5433),e),s(i(8280),e)},8762:function(t,e){"use strict";var i;Object.defineProperty(e,"__esModule",{value:!0}),e.errorUtil=void 0,(i=e.errorUtil||(e.errorUtil={})).errToObj=t=>"string"==typeof t?{message:t}:t||{},i.toString=t=>"string"==typeof t?t:null==t?void 0:t.message},3187:function(t,e,i){"use strict";var n=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.isAsync=e.isValid=e.isDirty=e.isAborted=e.OK=e.DIRTY=e.INVALID=e.ParseStatus=e.addIssueToContext=e.EMPTY_PATH=e.makeIssue=void 0;const s=i(6996),o=n(i(9349));e.makeIssue=t=>{const{data:e,path:i,errorMaps:n,issueData:s}=t,o=[...i,...s.path||[]],r={...s,path:o};let a="";const l=n.filter((t=>!!t)).slice().reverse();for(const t of l)a=t(r,{data:e,defaultError:a}).message;return{...s,path:o,message:s.message||a}},e.EMPTY_PATH=[],e.addIssueToContext=function(t,i){const n=(0,e.makeIssue)({issueData:i,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,(0,s.getErrorMap)(),o.default].filter((t=>!!t))});t.common.issues.push(n)};class r{constructor(){this.value="valid"}dirty(){"valid"===this.value&&(this.value="dirty")}abort(){"aborted"!==this.value&&(this.value="aborted")}static mergeArray(t,i){const n=[];for(const s of i){if("aborted"===s.status)return e.INVALID;"dirty"===s.status&&t.dirty(),n.push(s.value)}return{status:t.value,value:n}}static async mergeObjectAsync(t,e){const i=[];for(const t of e)i.push({key:await t.key,value:await t.value});return r.mergeObjectSync(t,i)}static mergeObjectSync(t,i){const n={};for(const s of i){const{key:i,value:o}=s;if("aborted"===i.status)return e.INVALID;if("aborted"===o.status)return e.INVALID;"dirty"===i.status&&t.dirty(),"dirty"===o.status&&t.dirty(),"__proto__"===i.value||void 0===o.value&&!s.alwaysSet||(n[i.value]=o.value)}return{status:t.value,value:n}}}e.ParseStatus=r,e.INVALID=Object.freeze({status:"aborted"}),e.DIRTY=t=>({status:"dirty",value:t}),e.OK=t=>({status:"valid",value:t}),e.isAborted=t=>"aborted"===t.status,e.isDirty=t=>"dirty"===t.status,e.isValid=t=>"valid"===t.status,e.isAsync=t=>"undefined"!=typeof Promise&&t instanceof Promise},116:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},9110:function(t,e){"use strict";var i;Object.defineProperty(e,"__esModule",{value:!0}),e.getParsedType=e.ZodParsedType=e.objectUtil=e.util=void 0,function(t){t.assertEqual=t=>t,t.assertIs=function(t){},t.assertNever=function(t){throw new Error},t.arrayToEnum=t=>{const e={};for(const i of t)e[i]=i;return e},t.getValidEnumValues=e=>{const i=t.objectKeys(e).filter((t=>"number"!=typeof e[e[t]])),n={};for(const t of i)n[t]=e[t];return t.objectValues(n)},t.objectValues=e=>t.objectKeys(e).map((function(t){return e[t]})),t.objectKeys="function"==typeof Object.keys?t=>Object.keys(t):t=>{const e=[];for(const i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.push(i);return e},t.find=(t,e)=>{for(const i of t)if(e(i))return i},t.isInteger="function"==typeof Number.isInteger?t=>Number.isInteger(t):t=>"number"==typeof t&&isFinite(t)&&Math.floor(t)===t,t.joinValues=function(t,e=" | "){return t.map((t=>"string"==typeof t?`'${t}'`:t)).join(e)},t.jsonStringifyReplacer=(t,e)=>"bigint"==typeof e?e.toString():e}(i=e.util||(e.util={})),(e.objectUtil||(e.objectUtil={})).mergeShapes=(t,e)=>({...t,...e}),e.ZodParsedType=i.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),e.getParsedType=t=>{switch(typeof t){case"undefined":return e.ZodParsedType.undefined;case"string":return e.ZodParsedType.string;case"number":return isNaN(t)?e.ZodParsedType.nan:e.ZodParsedType.number;case"boolean":return e.ZodParsedType.boolean;case"function":return e.ZodParsedType.function;case"bigint":return e.ZodParsedType.bigint;case"symbol":return e.ZodParsedType.symbol;case"object":return Array.isArray(t)?e.ZodParsedType.array:null===t?e.ZodParsedType.null:t.then&&"function"==typeof t.then&&t.catch&&"function"==typeof t.catch?e.ZodParsedType.promise:"undefined"!=typeof Map&&t instanceof Map?e.ZodParsedType.map:"undefined"!=typeof Set&&t instanceof Set?e.ZodParsedType.set:"undefined"!=typeof Date&&t instanceof Date?e.ZodParsedType.date:e.ZodParsedType.object;default:return e.ZodParsedType.unknown}}},8754:function(t,e,i){"use strict";var n=this&&this.__createBinding||(Object.create?function(t,e,i,n){void 0===n&&(n=i),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[i]}})}:function(t,e,i,n){void 0===n&&(n=i),t[n]=e[i]}),s=this&&this.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),o=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var i in t)"default"!==i&&Object.prototype.hasOwnProperty.call(t,i)&&n(e,t,i);return s(e,t),e},r=this&&this.__exportStar||function(t,e){for(var i in t)"default"===i||Object.prototype.hasOwnProperty.call(e,i)||n(e,t,i)};Object.defineProperty(e,"__esModule",{value:!0}),e.z=void 0;const a=o(i(6349));e.z=a,r(i(6349),e),e.default=a},9349:function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=i(9110),s=i(8280);e.default=(t,e)=>{let i;switch(t.code){case s.ZodIssueCode.invalid_type:i=t.received===n.ZodParsedType.undefined?"Required":`Expected ${t.expected}, received ${t.received}`;break;case s.ZodIssueCode.invalid_literal:i=`Invalid literal value, expected ${JSON.stringify(t.expected,n.util.jsonStringifyReplacer)}`;break;case s.ZodIssueCode.unrecognized_keys:i=`Unrecognized key(s) in object: ${n.util.joinValues(t.keys,", ")}`;break;case s.ZodIssueCode.invalid_union:i="Invalid input";break;case s.ZodIssueCode.invalid_union_discriminator:i=`Invalid discriminator value. Expected ${n.util.joinValues(t.options)}`;break;case s.ZodIssueCode.invalid_enum_value:i=`Invalid enum value. Expected ${n.util.joinValues(t.options)}, received '${t.received}'`;break;case s.ZodIssueCode.invalid_arguments:i="Invalid function arguments";break;case s.ZodIssueCode.invalid_return_type:i="Invalid function return type";break;case s.ZodIssueCode.invalid_date:i="Invalid date";break;case s.ZodIssueCode.invalid_string:"object"==typeof t.validation?"includes"in t.validation?(i=`Invalid input: must include "${t.validation.includes}"`,"number"==typeof t.validation.position&&(i=`${i} at one or more positions greater than or equal to ${t.validation.position}`)):"startsWith"in t.validation?i=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?i=`Invalid input: must end with "${t.validation.endsWith}"`:n.util.assertNever(t.validation):i="regex"!==t.validation?`Invalid ${t.validation}`:"Invalid";break;case s.ZodIssueCode.too_small:i="array"===t.type?`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:"string"===t.type?`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:"number"===t.type?`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:"date"===t.type?`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`:"Invalid input";break;case s.ZodIssueCode.too_big:i="array"===t.type?`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:"string"===t.type?`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:"number"===t.type?`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:"bigint"===t.type?`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:"date"===t.type?`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`:"Invalid input";break;case s.ZodIssueCode.custom:i="Invalid input";break;case s.ZodIssueCode.invalid_intersection_types:i="Intersection results could not be merged";break;case s.ZodIssueCode.not_multiple_of:i=`Number must be a multiple of ${t.multipleOf}`;break;case s.ZodIssueCode.not_finite:i="Number must be finite";break;default:i=e.defaultError,n.util.assertNever(t)}return{message:i}}},5433:function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.date=e.boolean=e.bigint=e.array=e.any=e.coerce=e.ZodFirstPartyTypeKind=e.late=e.ZodSchema=e.Schema=e.custom=e.ZodReadonly=e.ZodPipeline=e.ZodBranded=e.BRAND=e.ZodNaN=e.ZodCatch=e.ZodDefault=e.ZodNullable=e.ZodOptional=e.ZodTransformer=e.ZodEffects=e.ZodPromise=e.ZodNativeEnum=e.ZodEnum=e.ZodLiteral=e.ZodLazy=e.ZodFunction=e.ZodSet=e.ZodMap=e.ZodRecord=e.ZodTuple=e.ZodIntersection=e.ZodDiscriminatedUnion=e.ZodUnion=e.ZodObject=e.ZodArray=e.ZodVoid=e.ZodNever=e.ZodUnknown=e.ZodAny=e.ZodNull=e.ZodUndefined=e.ZodSymbol=e.ZodDate=e.ZodBoolean=e.ZodBigInt=e.ZodNumber=e.ZodString=e.ZodType=void 0,e.NEVER=e.void=e.unknown=e.union=e.undefined=e.tuple=e.transformer=e.symbol=e.string=e.strictObject=e.set=e.record=e.promise=e.preprocess=e.pipeline=e.ostring=e.optional=e.onumber=e.oboolean=e.object=e.number=e.nullable=e.null=e.never=e.nativeEnum=e.nan=e.map=e.literal=e.lazy=e.intersection=e.instanceof=e.function=e.enum=e.effect=e.discriminatedUnion=void 0;const n=i(6996),s=i(8762),o=i(3187),r=i(9110),a=i(8280);class l{constructor(t,e,i,n){this._cachedPath=[],this.parent=t,this.data=e,this._path=i,this._key=n}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const h=(t,e)=>{if((0,o.isValid)(e))return{success:!0,data:e.value};if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const e=new a.ZodError(t.common.issues);return this._error=e,this._error}}};function d(t){if(!t)return{};const{errorMap:e,invalid_type_error:i,required_error:n,description:s}=t;if(e&&(i||n))throw new Error('Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.');return e?{errorMap:e,description:s}:{errorMap:(t,e)=>"invalid_type"!==t.code?{message:e.defaultError}:void 0===e.data?{message:null!=n?n:e.defaultError}:{message:null!=i?i:e.defaultError},description:s}}class c{constructor(t){this.spa=this.safeParseAsync,this._def=t,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this)}get description(){return this._def.description}_getType(t){return(0,r.getParsedType)(t.data)}_getOrReturnCtx(t,e){return e||{common:t.parent.common,data:t.data,parsedType:(0,r.getParsedType)(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new o.ParseStatus,ctx:{common:t.parent.common,data:t.data,parsedType:(0,r.getParsedType)(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){const e=this._parse(t);if((0,o.isAsync)(e))throw new Error("Synchronous parse encountered promise.");return e}_parseAsync(t){const e=this._parse(t);return Promise.resolve(e)}parse(t,e){const i=this.safeParse(t,e);if(i.success)return i.data;throw i.error}safeParse(t,e){var i;const n={common:{issues:[],async:null!==(i=null==e?void 0:e.async)&&void 0!==i&&i,contextualErrorMap:null==e?void 0:e.errorMap},path:(null==e?void 0:e.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:(0,r.getParsedType)(t)},s=this._parseSync({data:t,path:n.path,parent:n});return h(n,s)}async parseAsync(t,e){const i=await this.safeParseAsync(t,e);if(i.success)return i.data;throw i.error}async safeParseAsync(t,e){const i={common:{issues:[],contextualErrorMap:null==e?void 0:e.errorMap,async:!0},path:(null==e?void 0:e.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:(0,r.getParsedType)(t)},n=this._parse({data:t,path:i.path,parent:i}),s=await((0,o.isAsync)(n)?n:Promise.resolve(n));return h(i,s)}refine(t,e){const i=t=>"string"==typeof e||void 0===e?{message:e}:"function"==typeof e?e(t):e;return this._refinement(((e,n)=>{const s=t(e),o=()=>n.addIssue({code:a.ZodIssueCode.custom,...i(e)});return"undefined"!=typeof Promise&&s instanceof Promise?s.then((t=>!!t||(o(),!1))):!!s||(o(),!1)}))}refinement(t,e){return this._refinement(((i,n)=>!!t(i)||(n.addIssue("function"==typeof e?e(i,n):e),!1)))}_refinement(t){return new J({schema:this,typeName:at.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}optional(){return Q.create(this,this._def)}nullable(){return tt.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return L.create(this,this._def)}promise(){return q.create(this,this._def)}or(t){return D.create([this,t],this._def)}and(t){return j.create(this,t,this._def)}transform(t){return new J({...d(this._def),schema:this,typeName:at.ZodEffects,effect:{type:"transform",transform:t}})}default(t){const e="function"==typeof t?t:()=>t;return new et({...d(this._def),innerType:this,defaultValue:e,typeName:at.ZodDefault})}brand(){return new st({typeName:at.ZodBranded,type:this,...d(this._def)})}catch(t){const e="function"==typeof t?t:()=>t;return new it({...d(this._def),innerType:this,catchValue:e,typeName:at.ZodCatch})}describe(t){return new(0,this.constructor)({...this._def,description:t})}pipe(t){return ot.create(this,t)}readonly(){return rt.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}e.ZodType=c,e.Schema=c,e.ZodSchema=c;const u=/^c[^\s-]{8,}$/i,p=/^[a-z][a-z0-9]*$/,g=/^[0-9A-HJKMNP-TV-Z]{26}$/,f=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,m=/^(?!\.)(?!.*\.\.)([A-Z0-9_+-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i;let _;const y=/^(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))$/,v=/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/;class x extends c{_parse(t){if(this._def.coerce&&(t.data=String(t.data)),this._getType(t)!==r.ZodParsedType.string){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.string,received:e.parsedType}),o.INVALID}const e=new o.ParseStatus;let i;for(const h of this._def.checks)if("min"===h.kind)t.data.length<h.value&&(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.too_small,minimum:h.value,type:"string",inclusive:!0,exact:!1,message:h.message}),e.dirty());else if("max"===h.kind)t.data.length>h.value&&(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.too_big,maximum:h.value,type:"string",inclusive:!0,exact:!1,message:h.message}),e.dirty());else if("length"===h.kind){const n=t.data.length>h.value,s=t.data.length<h.value;(n||s)&&(i=this._getOrReturnCtx(t,i),n?(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.too_big,maximum:h.value,type:"string",inclusive:!0,exact:!0,message:h.message}):s&&(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.too_small,minimum:h.value,type:"string",inclusive:!0,exact:!0,message:h.message}),e.dirty())}else if("email"===h.kind)m.test(t.data)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{validation:"email",code:a.ZodIssueCode.invalid_string,message:h.message}),e.dirty());else if("emoji"===h.kind)_||(_=new RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),_.test(t.data)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{validation:"emoji",code:a.ZodIssueCode.invalid_string,message:h.message}),e.dirty());else if("uuid"===h.kind)f.test(t.data)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{validation:"uuid",code:a.ZodIssueCode.invalid_string,message:h.message}),e.dirty());else if("cuid"===h.kind)u.test(t.data)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{validation:"cuid",code:a.ZodIssueCode.invalid_string,message:h.message}),e.dirty());else if("cuid2"===h.kind)p.test(t.data)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{validation:"cuid2",code:a.ZodIssueCode.invalid_string,message:h.message}),e.dirty());else if("ulid"===h.kind)g.test(t.data)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{validation:"ulid",code:a.ZodIssueCode.invalid_string,message:h.message}),e.dirty());else if("url"===h.kind)try{new URL(t.data)}catch(n){i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{validation:"url",code:a.ZodIssueCode.invalid_string,message:h.message}),e.dirty()}else"regex"===h.kind?(h.regex.lastIndex=0,h.regex.test(t.data)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{validation:"regex",code:a.ZodIssueCode.invalid_string,message:h.message}),e.dirty())):"trim"===h.kind?t.data=t.data.trim():"includes"===h.kind?t.data.includes(h.value,h.position)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.invalid_string,validation:{includes:h.value,position:h.position},message:h.message}),e.dirty()):"toLowerCase"===h.kind?t.data=t.data.toLowerCase():"toUpperCase"===h.kind?t.data=t.data.toUpperCase():"startsWith"===h.kind?t.data.startsWith(h.value)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.invalid_string,validation:{startsWith:h.value},message:h.message}),e.dirty()):"endsWith"===h.kind?t.data.endsWith(h.value)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.invalid_string,validation:{endsWith:h.value},message:h.message}),e.dirty()):"datetime"===h.kind?((l=h).precision?l.offset?new RegExp(`^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{${l.precision}}(([+-]\\d{2}(:?\\d{2})?)|Z)$`):new RegExp(`^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{${l.precision}}Z$`):0===l.precision?l.offset?new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(([+-]\\d{2}(:?\\d{2})?)|Z)$"):new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}Z$"):l.offset?new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?(([+-]\\d{2}(:?\\d{2})?)|Z)$"):new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?Z$")).test(t.data)||(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.invalid_string,validation:"datetime",message:h.message}),e.dirty()):"ip"===h.kind?(n=t.data,("v4"!==(s=h.version)&&s||!y.test(n))&&("v6"!==s&&s||!v.test(n))&&(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{validation:"ip",code:a.ZodIssueCode.invalid_string,message:h.message}),e.dirty())):r.util.assertNever(h);var n,s,l;return{status:e.value,value:t.data}}_regex(t,e,i){return this.refinement((e=>t.test(e)),{validation:e,code:a.ZodIssueCode.invalid_string,...s.errorUtil.errToObj(i)})}_addCheck(t){return new x({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...s.errorUtil.errToObj(t)})}url(t){return this._addCheck({kind:"url",...s.errorUtil.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...s.errorUtil.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...s.errorUtil.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...s.errorUtil.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...s.errorUtil.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...s.errorUtil.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...s.errorUtil.errToObj(t)})}datetime(t){var e;return"string"==typeof t?this._addCheck({kind:"datetime",precision:null,offset:!1,message:t}):this._addCheck({kind:"datetime",precision:void 0===(null==t?void 0:t.precision)?null:null==t?void 0:t.precision,offset:null!==(e=null==t?void 0:t.offset)&&void 0!==e&&e,...s.errorUtil.errToObj(null==t?void 0:t.message)})}regex(t,e){return this._addCheck({kind:"regex",regex:t,...s.errorUtil.errToObj(e)})}includes(t,e){return this._addCheck({kind:"includes",value:t,position:null==e?void 0:e.position,...s.errorUtil.errToObj(null==e?void 0:e.message)})}startsWith(t,e){return this._addCheck({kind:"startsWith",value:t,...s.errorUtil.errToObj(e)})}endsWith(t,e){return this._addCheck({kind:"endsWith",value:t,...s.errorUtil.errToObj(e)})}min(t,e){return this._addCheck({kind:"min",value:t,...s.errorUtil.errToObj(e)})}max(t,e){return this._addCheck({kind:"max",value:t,...s.errorUtil.errToObj(e)})}length(t,e){return this._addCheck({kind:"length",value:t,...s.errorUtil.errToObj(e)})}nonempty(t){return this.min(1,s.errorUtil.errToObj(t))}trim(){return new x({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new x({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new x({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find((t=>"datetime"===t.kind))}get isEmail(){return!!this._def.checks.find((t=>"email"===t.kind))}get isURL(){return!!this._def.checks.find((t=>"url"===t.kind))}get isEmoji(){return!!this._def.checks.find((t=>"emoji"===t.kind))}get isUUID(){return!!this._def.checks.find((t=>"uuid"===t.kind))}get isCUID(){return!!this._def.checks.find((t=>"cuid"===t.kind))}get isCUID2(){return!!this._def.checks.find((t=>"cuid2"===t.kind))}get isULID(){return!!this._def.checks.find((t=>"ulid"===t.kind))}get isIP(){return!!this._def.checks.find((t=>"ip"===t.kind))}get minLength(){let t=null;for(const e of this._def.checks)"min"===e.kind&&(null===t||e.value>t)&&(t=e.value);return t}get maxLength(){let t=null;for(const e of this._def.checks)"max"===e.kind&&(null===t||e.value<t)&&(t=e.value);return t}}function w(t,e){const i=(t.toString().split(".")[1]||"").length,n=(e.toString().split(".")[1]||"").length,s=i>n?i:n;return parseInt(t.toFixed(s).replace(".",""))%parseInt(e.toFixed(s).replace(".",""))/Math.pow(10,s)}e.ZodString=x,x.create=t=>{var e;return new x({checks:[],typeName:at.ZodString,coerce:null!==(e=null==t?void 0:t.coerce)&&void 0!==e&&e,...d(t)})};class C extends c{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce&&(t.data=Number(t.data)),this._getType(t)!==r.ZodParsedType.number){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.number,received:e.parsedType}),o.INVALID}let e;const i=new o.ParseStatus;for(const n of this._def.checks)"int"===n.kind?r.util.isInteger(t.data)||(e=this._getOrReturnCtx(t,e),(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:"integer",received:"float",message:n.message}),i.dirty()):"min"===n.kind?(n.inclusive?t.data<n.value:t.data<=n.value)&&(e=this._getOrReturnCtx(t,e),(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.too_small,minimum:n.value,type:"number",inclusive:n.inclusive,exact:!1,message:n.message}),i.dirty()):"max"===n.kind?(n.inclusive?t.data>n.value:t.data>=n.value)&&(e=this._getOrReturnCtx(t,e),(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.too_big,maximum:n.value,type:"number",inclusive:n.inclusive,exact:!1,message:n.message}),i.dirty()):"multipleOf"===n.kind?0!==w(t.data,n.value)&&(e=this._getOrReturnCtx(t,e),(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.not_multiple_of,multipleOf:n.value,message:n.message}),i.dirty()):"finite"===n.kind?Number.isFinite(t.data)||(e=this._getOrReturnCtx(t,e),(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.not_finite,message:n.message}),i.dirty()):r.util.assertNever(n);return{status:i.value,value:t.data}}gte(t,e){return this.setLimit("min",t,!0,s.errorUtil.toString(e))}gt(t,e){return this.setLimit("min",t,!1,s.errorUtil.toString(e))}lte(t,e){return this.setLimit("max",t,!0,s.errorUtil.toString(e))}lt(t,e){return this.setLimit("max",t,!1,s.errorUtil.toString(e))}setLimit(t,e,i,n){return new C({...this._def,checks:[...this._def.checks,{kind:t,value:e,inclusive:i,message:s.errorUtil.toString(n)}]})}_addCheck(t){return new C({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:s.errorUtil.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:s.errorUtil.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:s.errorUtil.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:s.errorUtil.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:s.errorUtil.toString(t)})}multipleOf(t,e){return this._addCheck({kind:"multipleOf",value:t,message:s.errorUtil.toString(e)})}finite(t){return this._addCheck({kind:"finite",message:s.errorUtil.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:s.errorUtil.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:s.errorUtil.toString(t)})}get minValue(){let t=null;for(const e of this._def.checks)"min"===e.kind&&(null===t||e.value>t)&&(t=e.value);return t}get maxValue(){let t=null;for(const e of this._def.checks)"max"===e.kind&&(null===t||e.value<t)&&(t=e.value);return t}get isInt(){return!!this._def.checks.find((t=>"int"===t.kind||"multipleOf"===t.kind&&r.util.isInteger(t.value)))}get isFinite(){let t=null,e=null;for(const i of this._def.checks){if("finite"===i.kind||"int"===i.kind||"multipleOf"===i.kind)return!0;"min"===i.kind?(null===e||i.value>e)&&(e=i.value):"max"===i.kind&&(null===t||i.value<t)&&(t=i.value)}return Number.isFinite(e)&&Number.isFinite(t)}}e.ZodNumber=C,C.create=t=>new C({checks:[],typeName:at.ZodNumber,coerce:(null==t?void 0:t.coerce)||!1,...d(t)});class S extends c{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce&&(t.data=BigInt(t.data)),this._getType(t)!==r.ZodParsedType.bigint){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.bigint,received:e.parsedType}),o.INVALID}let e;const i=new o.ParseStatus;for(const n of this._def.checks)"min"===n.kind?(n.inclusive?t.data<n.value:t.data<=n.value)&&(e=this._getOrReturnCtx(t,e),(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.too_small,type:"bigint",minimum:n.value,inclusive:n.inclusive,message:n.message}),i.dirty()):"max"===n.kind?(n.inclusive?t.data>n.value:t.data>=n.value)&&(e=this._getOrReturnCtx(t,e),(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.too_big,type:"bigint",maximum:n.value,inclusive:n.inclusive,message:n.message}),i.dirty()):"multipleOf"===n.kind?t.data%n.value!==BigInt(0)&&(e=this._getOrReturnCtx(t,e),(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.not_multiple_of,multipleOf:n.value,message:n.message}),i.dirty()):r.util.assertNever(n);return{status:i.value,value:t.data}}gte(t,e){return this.setLimit("min",t,!0,s.errorUtil.toString(e))}gt(t,e){return this.setLimit("min",t,!1,s.errorUtil.toString(e))}lte(t,e){return this.setLimit("max",t,!0,s.errorUtil.toString(e))}lt(t,e){return this.setLimit("max",t,!1,s.errorUtil.toString(e))}setLimit(t,e,i,n){return new S({...this._def,checks:[...this._def.checks,{kind:t,value:e,inclusive:i,message:s.errorUtil.toString(n)}]})}_addCheck(t){return new S({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:s.errorUtil.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:s.errorUtil.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:s.errorUtil.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:s.errorUtil.toString(t)})}multipleOf(t,e){return this._addCheck({kind:"multipleOf",value:t,message:s.errorUtil.toString(e)})}get minValue(){let t=null;for(const e of this._def.checks)"min"===e.kind&&(null===t||e.value>t)&&(t=e.value);return t}get maxValue(){let t=null;for(const e of this._def.checks)"max"===e.kind&&(null===t||e.value<t)&&(t=e.value);return t}}e.ZodBigInt=S,S.create=t=>{var e;return new S({checks:[],typeName:at.ZodBigInt,coerce:null!==(e=null==t?void 0:t.coerce)&&void 0!==e&&e,...d(t)})};class T extends c{_parse(t){if(this._def.coerce&&(t.data=Boolean(t.data)),this._getType(t)!==r.ZodParsedType.boolean){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.boolean,received:e.parsedType}),o.INVALID}return(0,o.OK)(t.data)}}e.ZodBoolean=T,T.create=t=>new T({typeName:at.ZodBoolean,coerce:(null==t?void 0:t.coerce)||!1,...d(t)});class b extends c{_parse(t){if(this._def.coerce&&(t.data=new Date(t.data)),this._getType(t)!==r.ZodParsedType.date){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.date,received:e.parsedType}),o.INVALID}if(isNaN(t.data.getTime())){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_date}),o.INVALID}const e=new o.ParseStatus;let i;for(const n of this._def.checks)"min"===n.kind?t.data.getTime()<n.value&&(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.too_small,message:n.message,inclusive:!0,exact:!1,minimum:n.value,type:"date"}),e.dirty()):"max"===n.kind?t.data.getTime()>n.value&&(i=this._getOrReturnCtx(t,i),(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.too_big,message:n.message,inclusive:!0,exact:!1,maximum:n.value,type:"date"}),e.dirty()):r.util.assertNever(n);return{status:e.value,value:new Date(t.data.getTime())}}_addCheck(t){return new b({...this._def,checks:[...this._def.checks,t]})}min(t,e){return this._addCheck({kind:"min",value:t.getTime(),message:s.errorUtil.toString(e)})}max(t,e){return this._addCheck({kind:"max",value:t.getTime(),message:s.errorUtil.toString(e)})}get minDate(){let t=null;for(const e of this._def.checks)"min"===e.kind&&(null===t||e.value>t)&&(t=e.value);return null!=t?new Date(t):null}get maxDate(){let t=null;for(const e of this._def.checks)"max"===e.kind&&(null===t||e.value<t)&&(t=e.value);return null!=t?new Date(t):null}}e.ZodDate=b,b.create=t=>new b({checks:[],coerce:(null==t?void 0:t.coerce)||!1,typeName:at.ZodDate,...d(t)});class k extends c{_parse(t){if(this._getType(t)!==r.ZodParsedType.symbol){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.symbol,received:e.parsedType}),o.INVALID}return(0,o.OK)(t.data)}}e.ZodSymbol=k,k.create=t=>new k({typeName:at.ZodSymbol,...d(t)});class I extends c{_parse(t){if(this._getType(t)!==r.ZodParsedType.undefined){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.undefined,received:e.parsedType}),o.INVALID}return(0,o.OK)(t.data)}}e.ZodUndefined=I,I.create=t=>new I({typeName:at.ZodUndefined,...d(t)});class E extends c{_parse(t){if(this._getType(t)!==r.ZodParsedType.null){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.null,received:e.parsedType}),o.INVALID}return(0,o.OK)(t.data)}}e.ZodNull=E,E.create=t=>new E({typeName:at.ZodNull,...d(t)});class R extends c{constructor(){super(...arguments),this._any=!0}_parse(t){return(0,o.OK)(t.data)}}e.ZodAny=R,R.create=t=>new R({typeName:at.ZodAny,...d(t)});class P extends c{constructor(){super(...arguments),this._unknown=!0}_parse(t){return(0,o.OK)(t.data)}}e.ZodUnknown=P,P.create=t=>new P({typeName:at.ZodUnknown,...d(t)});class M extends c{_parse(t){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.never,received:e.parsedType}),o.INVALID}}e.ZodNever=M,M.create=t=>new M({typeName:at.ZodNever,...d(t)});class A extends c{_parse(t){if(this._getType(t)!==r.ZodParsedType.undefined){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.void,received:e.parsedType}),o.INVALID}return(0,o.OK)(t.data)}}e.ZodVoid=A,A.create=t=>new A({typeName:at.ZodVoid,...d(t)});class L extends c{_parse(t){const{ctx:e,status:i}=this._processInputParams(t),n=this._def;if(e.parsedType!==r.ZodParsedType.array)return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.array,received:e.parsedType}),o.INVALID;if(null!==n.exactLength){const t=e.data.length>n.exactLength.value,s=e.data.length<n.exactLength.value;(t||s)&&((0,o.addIssueToContext)(e,{code:t?a.ZodIssueCode.too_big:a.ZodIssueCode.too_small,minimum:s?n.exactLength.value:void 0,maximum:t?n.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:n.exactLength.message}),i.dirty())}if(null!==n.minLength&&e.data.length<n.minLength.value&&((0,o.addIssueToContext)(e,{code:a.ZodIssueCode.too_small,minimum:n.minLength.value,type:"array",inclusive:!0,exact:!1,message:n.minLength.message}),i.dirty()),null!==n.maxLength&&e.data.length>n.maxLength.value&&((0,o.addIssueToContext)(e,{code:a.ZodIssueCode.too_big,maximum:n.maxLength.value,type:"array",inclusive:!0,exact:!1,message:n.maxLength.message}),i.dirty()),e.common.async)return Promise.all([...e.data].map(((t,i)=>n.type._parseAsync(new l(e,t,e.path,i))))).then((t=>o.ParseStatus.mergeArray(i,t)));const s=[...e.data].map(((t,i)=>n.type._parseSync(new l(e,t,e.path,i))));return o.ParseStatus.mergeArray(i,s)}get element(){return this._def.type}min(t,e){return new L({...this._def,minLength:{value:t,message:s.errorUtil.toString(e)}})}max(t,e){return new L({...this._def,maxLength:{value:t,message:s.errorUtil.toString(e)}})}length(t,e){return new L({...this._def,exactLength:{value:t,message:s.errorUtil.toString(e)}})}nonempty(t){return this.min(1,t)}}function O(t){if(t instanceof F){const e={};for(const i in t.shape){const n=t.shape[i];e[i]=Q.create(O(n))}return new F({...t._def,shape:()=>e})}return t instanceof L?new L({...t._def,type:O(t.element)}):t instanceof Q?Q.create(O(t.unwrap())):t instanceof tt?tt.create(O(t.unwrap())):t instanceof $?$.create(t.items.map((t=>O(t)))):t}e.ZodArray=L,L.create=(t,e)=>new L({type:t,minLength:null,maxLength:null,exactLength:null,typeName:at.ZodArray,...d(e)});class F extends c{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(null!==this._cached)return this._cached;const t=this._def.shape(),e=r.util.objectKeys(t);return this._cached={shape:t,keys:e}}_parse(t){if(this._getType(t)!==r.ZodParsedType.object){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.object,received:e.parsedType}),o.INVALID}const{status:e,ctx:i}=this._processInputParams(t),{shape:n,keys:s}=this._getCached(),h=[];if(!(this._def.catchall instanceof M&&"strip"===this._def.unknownKeys))for(const t in i.data)s.includes(t)||h.push(t);const d=[];for(const t of s){const e=n[t],s=i.data[t];d.push({key:{status:"valid",value:t},value:e._parse(new l(i,s,i.path,t)),alwaysSet:t in i.data})}if(this._def.catchall instanceof M){const t=this._def.unknownKeys;if("passthrough"===t)for(const t of h)d.push({key:{status:"valid",value:t},value:{status:"valid",value:i.data[t]}});else if("strict"===t)h.length>0&&((0,o.addIssueToContext)(i,{code:a.ZodIssueCode.unrecognized_keys,keys:h}),e.dirty());else if("strip"!==t)throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const t=this._def.catchall;for(const e of h){const n=i.data[e];d.push({key:{status:"valid",value:e},value:t._parse(new l(i,n,i.path,e)),alwaysSet:e in i.data})}}return i.common.async?Promise.resolve().then((async()=>{const t=[];for(const e of d){const i=await e.key;t.push({key:i,value:await e.value,alwaysSet:e.alwaysSet})}return t})).then((t=>o.ParseStatus.mergeObjectSync(e,t))):o.ParseStatus.mergeObjectSync(e,d)}get shape(){return this._def.shape()}strict(t){return s.errorUtil.errToObj,new F({...this._def,unknownKeys:"strict",...void 0!==t?{errorMap:(e,i)=>{var n,o,r,a;const l=null!==(r=null===(o=(n=this._def).errorMap)||void 0===o?void 0:o.call(n,e,i).message)&&void 0!==r?r:i.defaultError;return"unrecognized_keys"===e.code?{message:null!==(a=s.errorUtil.errToObj(t).message)&&void 0!==a?a:l}:{message:l}}}:{}})}strip(){return new F({...this._def,unknownKeys:"strip"})}passthrough(){return new F({...this._def,unknownKeys:"passthrough"})}extend(t){return new F({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new F({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:at.ZodObject})}setKey(t,e){return this.augment({[t]:e})}catchall(t){return new F({...this._def,catchall:t})}pick(t){const e={};return r.util.objectKeys(t).forEach((i=>{t[i]&&this.shape[i]&&(e[i]=this.shape[i])})),new F({...this._def,shape:()=>e})}omit(t){const e={};return r.util.objectKeys(this.shape).forEach((i=>{t[i]||(e[i]=this.shape[i])})),new F({...this._def,shape:()=>e})}deepPartial(){return O(this)}partial(t){const e={};return r.util.objectKeys(this.shape).forEach((i=>{const n=this.shape[i];t&&!t[i]?e[i]=n:e[i]=n.optional()})),new F({...this._def,shape:()=>e})}required(t){const e={};return r.util.objectKeys(this.shape).forEach((i=>{if(t&&!t[i])e[i]=this.shape[i];else{let t=this.shape[i];for(;t instanceof Q;)t=t._def.innerType;e[i]=t}})),new F({...this._def,shape:()=>e})}keyof(){return K(r.util.objectKeys(this.shape))}}e.ZodObject=F,F.create=(t,e)=>new F({shape:()=>t,unknownKeys:"strip",catchall:M.create(),typeName:at.ZodObject,...d(e)}),F.strictCreate=(t,e)=>new F({shape:()=>t,unknownKeys:"strict",catchall:M.create(),typeName:at.ZodObject,...d(e)}),F.lazycreate=(t,e)=>new F({shape:t,unknownKeys:"strip",catchall:M.create(),typeName:at.ZodObject,...d(e)});class D extends c{_parse(t){const{ctx:e}=this._processInputParams(t),i=this._def.options;if(e.common.async)return Promise.all(i.map((async t=>{const i={...e,common:{...e.common,issues:[]},parent:null};return{result:await t._parseAsync({data:e.data,path:e.path,parent:i}),ctx:i}}))).then((function(t){for(const e of t)if("valid"===e.result.status)return e.result;for(const i of t)if("dirty"===i.result.status)return e.common.issues.push(...i.ctx.common.issues),i.result;const i=t.map((t=>new a.ZodError(t.ctx.common.issues)));return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_union,unionErrors:i}),o.INVALID}));{let t;const n=[];for(const s of i){const i={...e,common:{...e.common,issues:[]},parent:null},o=s._parseSync({data:e.data,path:e.path,parent:i});if("valid"===o.status)return o;"dirty"!==o.status||t||(t={result:o,ctx:i}),i.common.issues.length&&n.push(i.common.issues)}if(t)return e.common.issues.push(...t.ctx.common.issues),t.result;const s=n.map((t=>new a.ZodError(t)));return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_union,unionErrors:s}),o.INVALID}}get options(){return this._def.options}}e.ZodUnion=D,D.create=(t,e)=>new D({options:t,typeName:at.ZodUnion,...d(e)});const Z=t=>t instanceof U?Z(t.schema):t instanceof J?Z(t.innerType()):t instanceof X?[t.value]:t instanceof Y?t.options:t instanceof H?Object.keys(t.enum):t instanceof et?Z(t._def.innerType):t instanceof I?[void 0]:t instanceof E?[null]:null;class N extends c{_parse(t){const{ctx:e}=this._processInputParams(t);if(e.parsedType!==r.ZodParsedType.object)return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.object,received:e.parsedType}),o.INVALID;const i=this.discriminator,n=e.data[i],s=this.optionsMap.get(n);return s?e.common.async?s._parseAsync({data:e.data,path:e.path,parent:e}):s._parseSync({data:e.data,path:e.path,parent:e}):((0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[i]}),o.INVALID)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,e,i){const n=new Map;for(const i of e){const e=Z(i.shape[t]);if(!e)throw new Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(const s of e){if(n.has(s))throw new Error(`Discriminator property ${String(t)} has duplicate value ${String(s)}`);n.set(s,i)}}return new N({typeName:at.ZodDiscriminatedUnion,discriminator:t,options:e,optionsMap:n,...d(i)})}}function z(t,e){const i=(0,r.getParsedType)(t),n=(0,r.getParsedType)(e);if(t===e)return{valid:!0,data:t};if(i===r.ZodParsedType.object&&n===r.ZodParsedType.object){const i=r.util.objectKeys(e),n=r.util.objectKeys(t).filter((t=>-1!==i.indexOf(t))),s={...t,...e};for(const i of n){const n=z(t[i],e[i]);if(!n.valid)return{valid:!1};s[i]=n.data}return{valid:!0,data:s}}if(i===r.ZodParsedType.array&&n===r.ZodParsedType.array){if(t.length!==e.length)return{valid:!1};const i=[];for(let n=0;n<t.length;n++){const s=z(t[n],e[n]);if(!s.valid)return{valid:!1};i.push(s.data)}return{valid:!0,data:i}}return i===r.ZodParsedType.date&&n===r.ZodParsedType.date&&+t==+e?{valid:!0,data:t}:{valid:!1}}e.ZodDiscriminatedUnion=N;class j extends c{_parse(t){const{status:e,ctx:i}=this._processInputParams(t),n=(t,n)=>{if((0,o.isAborted)(t)||(0,o.isAborted)(n))return o.INVALID;const s=z(t.value,n.value);return s.valid?(((0,o.isDirty)(t)||(0,o.isDirty)(n))&&e.dirty(),{status:e.value,value:s.data}):((0,o.addIssueToContext)(i,{code:a.ZodIssueCode.invalid_intersection_types}),o.INVALID)};return i.common.async?Promise.all([this._def.left._parseAsync({data:i.data,path:i.path,parent:i}),this._def.right._parseAsync({data:i.data,path:i.path,parent:i})]).then((([t,e])=>n(t,e))):n(this._def.left._parseSync({data:i.data,path:i.path,parent:i}),this._def.right._parseSync({data:i.data,path:i.path,parent:i}))}}e.ZodIntersection=j,j.create=(t,e,i)=>new j({left:t,right:e,typeName:at.ZodIntersection,...d(i)});class $ extends c{_parse(t){const{status:e,ctx:i}=this._processInputParams(t);if(i.parsedType!==r.ZodParsedType.array)return(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.array,received:i.parsedType}),o.INVALID;if(i.data.length<this._def.items.length)return(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),o.INVALID;!this._def.rest&&i.data.length>this._def.items.length&&((0,o.addIssueToContext)(i,{code:a.ZodIssueCode.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),e.dirty());const n=[...i.data].map(((t,e)=>{const n=this._def.items[e]||this._def.rest;return n?n._parse(new l(i,t,i.path,e)):null})).filter((t=>!!t));return i.common.async?Promise.all(n).then((t=>o.ParseStatus.mergeArray(e,t))):o.ParseStatus.mergeArray(e,n)}get items(){return this._def.items}rest(t){return new $({...this._def,rest:t})}}e.ZodTuple=$,$.create=(t,e)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new $({items:t,typeName:at.ZodTuple,rest:null,...d(e)})};class W extends c{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){const{status:e,ctx:i}=this._processInputParams(t);if(i.parsedType!==r.ZodParsedType.object)return(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.object,received:i.parsedType}),o.INVALID;const n=[],s=this._def.keyType,h=this._def.valueType;for(const t in i.data)n.push({key:s._parse(new l(i,t,i.path,t)),value:h._parse(new l(i,i.data[t],i.path,t))});return i.common.async?o.ParseStatus.mergeObjectAsync(e,n):o.ParseStatus.mergeObjectSync(e,n)}get element(){return this._def.valueType}static create(t,e,i){return new W(e instanceof c?{keyType:t,valueType:e,typeName:at.ZodRecord,...d(i)}:{keyType:x.create(),valueType:t,typeName:at.ZodRecord,...d(e)})}}e.ZodRecord=W;class G extends c{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){const{status:e,ctx:i}=this._processInputParams(t);if(i.parsedType!==r.ZodParsedType.map)return(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.map,received:i.parsedType}),o.INVALID;const n=this._def.keyType,s=this._def.valueType,h=[...i.data.entries()].map((([t,e],o)=>({key:n._parse(new l(i,t,i.path,[o,"key"])),value:s._parse(new l(i,e,i.path,[o,"value"]))})));if(i.common.async){const t=new Map;return Promise.resolve().then((async()=>{for(const i of h){const n=await i.key,s=await i.value;if("aborted"===n.status||"aborted"===s.status)return o.INVALID;"dirty"!==n.status&&"dirty"!==s.status||e.dirty(),t.set(n.value,s.value)}return{status:e.value,value:t}}))}{const t=new Map;for(const i of h){const n=i.key,s=i.value;if("aborted"===n.status||"aborted"===s.status)return o.INVALID;"dirty"!==n.status&&"dirty"!==s.status||e.dirty(),t.set(n.value,s.value)}return{status:e.value,value:t}}}}e.ZodMap=G,G.create=(t,e,i)=>new G({valueType:e,keyType:t,typeName:at.ZodMap,...d(i)});class B extends c{_parse(t){const{status:e,ctx:i}=this._processInputParams(t);if(i.parsedType!==r.ZodParsedType.set)return(0,o.addIssueToContext)(i,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.set,received:i.parsedType}),o.INVALID;const n=this._def;null!==n.minSize&&i.data.size<n.minSize.value&&((0,o.addIssueToContext)(i,{code:a.ZodIssueCode.too_small,minimum:n.minSize.value,type:"set",inclusive:!0,exact:!1,message:n.minSize.message}),e.dirty()),null!==n.maxSize&&i.data.size>n.maxSize.value&&((0,o.addIssueToContext)(i,{code:a.ZodIssueCode.too_big,maximum:n.maxSize.value,type:"set",inclusive:!0,exact:!1,message:n.maxSize.message}),e.dirty());const s=this._def.valueType;function h(t){const i=new Set;for(const n of t){if("aborted"===n.status)return o.INVALID;"dirty"===n.status&&e.dirty(),i.add(n.value)}return{status:e.value,value:i}}const d=[...i.data.values()].map(((t,e)=>s._parse(new l(i,t,i.path,e))));return i.common.async?Promise.all(d).then((t=>h(t))):h(d)}min(t,e){return new B({...this._def,minSize:{value:t,message:s.errorUtil.toString(e)}})}max(t,e){return new B({...this._def,maxSize:{value:t,message:s.errorUtil.toString(e)}})}size(t,e){return this.min(t,e).max(t,e)}nonempty(t){return this.min(1,t)}}e.ZodSet=B,B.create=(t,e)=>new B({valueType:t,minSize:null,maxSize:null,typeName:at.ZodSet,...d(e)});class V extends c{constructor(){super(...arguments),this.validate=this.implement}_parse(t){const{ctx:e}=this._processInputParams(t);if(e.parsedType!==r.ZodParsedType.function)return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.function,received:e.parsedType}),o.INVALID;function i(t,i){return(0,o.makeIssue)({data:t,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,(0,n.getErrorMap)(),n.defaultErrorMap].filter((t=>!!t)),issueData:{code:a.ZodIssueCode.invalid_arguments,argumentsError:i}})}function s(t,i){return(0,o.makeIssue)({data:t,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,(0,n.getErrorMap)(),n.defaultErrorMap].filter((t=>!!t)),issueData:{code:a.ZodIssueCode.invalid_return_type,returnTypeError:i}})}const l={errorMap:e.common.contextualErrorMap},h=e.data;if(this._def.returns instanceof q){const t=this;return(0,o.OK)((async function(...e){const n=new a.ZodError([]),o=await t._def.args.parseAsync(e,l).catch((t=>{throw n.addIssue(i(e,t)),n})),r=await Reflect.apply(h,this,o);return await t._def.returns._def.type.parseAsync(r,l).catch((t=>{throw n.addIssue(s(r,t)),n}))}))}{const t=this;return(0,o.OK)((function(...e){const n=t._def.args.safeParse(e,l);if(!n.success)throw new a.ZodError([i(e,n.error)]);const o=Reflect.apply(h,this,n.data),r=t._def.returns.safeParse(o,l);if(!r.success)throw new a.ZodError([s(o,r.error)]);return r.data}))}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...t){return new V({...this._def,args:$.create(t).rest(P.create())})}returns(t){return new V({...this._def,returns:t})}implement(t){return this.parse(t)}strictImplement(t){return this.parse(t)}static create(t,e,i){return new V({args:t||$.create([]).rest(P.create()),returns:e||P.create(),typeName:at.ZodFunction,...d(i)})}}e.ZodFunction=V;class U extends c{get schema(){return this._def.getter()}_parse(t){const{ctx:e}=this._processInputParams(t);return this._def.getter()._parse({data:e.data,path:e.path,parent:e})}}e.ZodLazy=U,U.create=(t,e)=>new U({getter:t,typeName:at.ZodLazy,...d(e)});class X extends c{_parse(t){if(t.data!==this._def.value){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{received:e.data,code:a.ZodIssueCode.invalid_literal,expected:this._def.value}),o.INVALID}return{status:"valid",value:t.data}}get value(){return this._def.value}}function K(t,e){return new Y({values:t,typeName:at.ZodEnum,...d(e)})}e.ZodLiteral=X,X.create=(t,e)=>new X({value:t,typeName:at.ZodLiteral,...d(e)});class Y extends c{_parse(t){if("string"!=typeof t.data){const e=this._getOrReturnCtx(t),i=this._def.values;return(0,o.addIssueToContext)(e,{expected:r.util.joinValues(i),received:e.parsedType,code:a.ZodIssueCode.invalid_type}),o.INVALID}if(-1===this._def.values.indexOf(t.data)){const e=this._getOrReturnCtx(t),i=this._def.values;return(0,o.addIssueToContext)(e,{received:e.data,code:a.ZodIssueCode.invalid_enum_value,options:i}),o.INVALID}return(0,o.OK)(t.data)}get options(){return this._def.values}get enum(){const t={};for(const e of this._def.values)t[e]=e;return t}get Values(){const t={};for(const e of this._def.values)t[e]=e;return t}get Enum(){const t={};for(const e of this._def.values)t[e]=e;return t}extract(t){return Y.create(t)}exclude(t){return Y.create(this.options.filter((e=>!t.includes(e))))}}e.ZodEnum=Y,Y.create=K;class H extends c{_parse(t){const e=r.util.getValidEnumValues(this._def.values),i=this._getOrReturnCtx(t);if(i.parsedType!==r.ZodParsedType.string&&i.parsedType!==r.ZodParsedType.number){const t=r.util.objectValues(e);return(0,o.addIssueToContext)(i,{expected:r.util.joinValues(t),received:i.parsedType,code:a.ZodIssueCode.invalid_type}),o.INVALID}if(-1===e.indexOf(t.data)){const t=r.util.objectValues(e);return(0,o.addIssueToContext)(i,{received:i.data,code:a.ZodIssueCode.invalid_enum_value,options:t}),o.INVALID}return(0,o.OK)(t.data)}get enum(){return this._def.values}}e.ZodNativeEnum=H,H.create=(t,e)=>new H({values:t,typeName:at.ZodNativeEnum,...d(e)});class q extends c{unwrap(){return this._def.type}_parse(t){const{ctx:e}=this._processInputParams(t);if(e.parsedType!==r.ZodParsedType.promise&&!1===e.common.async)return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.promise,received:e.parsedType}),o.INVALID;const i=e.parsedType===r.ZodParsedType.promise?e.data:Promise.resolve(e.data);return(0,o.OK)(i.then((t=>this._def.type.parseAsync(t,{path:e.path,errorMap:e.common.contextualErrorMap}))))}}e.ZodPromise=q,q.create=(t,e)=>new q({type:t,typeName:at.ZodPromise,...d(e)});class J extends c{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===at.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){const{status:e,ctx:i}=this._processInputParams(t),n=this._def.effect||null,s={addIssue:t=>{(0,o.addIssueToContext)(i,t),t.fatal?e.abort():e.dirty()},get path(){return i.path}};if(s.addIssue=s.addIssue.bind(s),"preprocess"===n.type){const t=n.transform(i.data,s);return i.common.issues.length?{status:"dirty",value:i.data}:i.common.async?Promise.resolve(t).then((t=>this._def.schema._parseAsync({data:t,path:i.path,parent:i}))):this._def.schema._parseSync({data:t,path:i.path,parent:i})}if("refinement"===n.type){const t=t=>{const e=n.refinement(t,s);if(i.common.async)return Promise.resolve(e);if(e instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return t};if(!1===i.common.async){const n=this._def.schema._parseSync({data:i.data,path:i.path,parent:i});return"aborted"===n.status?o.INVALID:("dirty"===n.status&&e.dirty(),t(n.value),{status:e.value,value:n.value})}return this._def.schema._parseAsync({data:i.data,path:i.path,parent:i}).then((i=>"aborted"===i.status?o.INVALID:("dirty"===i.status&&e.dirty(),t(i.value).then((()=>({status:e.value,value:i.value}))))))}if("transform"===n.type){if(!1===i.common.async){const t=this._def.schema._parseSync({data:i.data,path:i.path,parent:i});if(!(0,o.isValid)(t))return t;const r=n.transform(t.value,s);if(r instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:e.value,value:r}}return this._def.schema._parseAsync({data:i.data,path:i.path,parent:i}).then((t=>(0,o.isValid)(t)?Promise.resolve(n.transform(t.value,s)).then((t=>({status:e.value,value:t}))):t))}r.util.assertNever(n)}}e.ZodEffects=J,e.ZodTransformer=J,J.create=(t,e,i)=>new J({schema:t,typeName:at.ZodEffects,effect:e,...d(i)}),J.createWithPreprocess=(t,e,i)=>new J({schema:e,effect:{type:"preprocess",transform:t},typeName:at.ZodEffects,...d(i)});class Q extends c{_parse(t){return this._getType(t)===r.ZodParsedType.undefined?(0,o.OK)(void 0):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}e.ZodOptional=Q,Q.create=(t,e)=>new Q({innerType:t,typeName:at.ZodOptional,...d(e)});class tt extends c{_parse(t){return this._getType(t)===r.ZodParsedType.null?(0,o.OK)(null):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}e.ZodNullable=tt,tt.create=(t,e)=>new tt({innerType:t,typeName:at.ZodNullable,...d(e)});class et extends c{_parse(t){const{ctx:e}=this._processInputParams(t);let i=e.data;return e.parsedType===r.ZodParsedType.undefined&&(i=this._def.defaultValue()),this._def.innerType._parse({data:i,path:e.path,parent:e})}removeDefault(){return this._def.innerType}}e.ZodDefault=et,et.create=(t,e)=>new et({innerType:t,typeName:at.ZodDefault,defaultValue:"function"==typeof e.default?e.default:()=>e.default,...d(e)});class it extends c{_parse(t){const{ctx:e}=this._processInputParams(t),i={...e,common:{...e.common,issues:[]}},n=this._def.innerType._parse({data:i.data,path:i.path,parent:{...i}});return(0,o.isAsync)(n)?n.then((t=>({status:"valid",value:"valid"===t.status?t.value:this._def.catchValue({get error(){return new a.ZodError(i.common.issues)},input:i.data})}))):{status:"valid",value:"valid"===n.status?n.value:this._def.catchValue({get error(){return new a.ZodError(i.common.issues)},input:i.data})}}removeCatch(){return this._def.innerType}}e.ZodCatch=it,it.create=(t,e)=>new it({innerType:t,typeName:at.ZodCatch,catchValue:"function"==typeof e.catch?e.catch:()=>e.catch,...d(e)});class nt extends c{_parse(t){if(this._getType(t)!==r.ZodParsedType.nan){const e=this._getOrReturnCtx(t);return(0,o.addIssueToContext)(e,{code:a.ZodIssueCode.invalid_type,expected:r.ZodParsedType.nan,received:e.parsedType}),o.INVALID}return{status:"valid",value:t.data}}}e.ZodNaN=nt,nt.create=t=>new nt({typeName:at.ZodNaN,...d(t)}),e.BRAND=Symbol("zod_brand");class st extends c{_parse(t){const{ctx:e}=this._processInputParams(t),i=e.data;return this._def.type._parse({data:i,path:e.path,parent:e})}unwrap(){return this._def.type}}e.ZodBranded=st;class ot extends c{_parse(t){const{status:e,ctx:i}=this._processInputParams(t);if(i.common.async)return(async()=>{const t=await this._def.in._parseAsync({data:i.data,path:i.path,parent:i});return"aborted"===t.status?o.INVALID:"dirty"===t.status?(e.dirty(),(0,o.DIRTY)(t.value)):this._def.out._parseAsync({data:t.value,path:i.path,parent:i})})();{const t=this._def.in._parseSync({data:i.data,path:i.path,parent:i});return"aborted"===t.status?o.INVALID:"dirty"===t.status?(e.dirty(),{status:"dirty",value:t.value}):this._def.out._parseSync({data:t.value,path:i.path,parent:i})}}static create(t,e){return new ot({in:t,out:e,typeName:at.ZodPipeline})}}e.ZodPipeline=ot;class rt extends c{_parse(t){const e=this._def.innerType._parse(t);return(0,o.isValid)(e)&&(e.value=Object.freeze(e.value)),e}}var at;e.ZodReadonly=rt,rt.create=(t,e)=>new rt({innerType:t,typeName:at.ZodReadonly,...d(e)}),e.custom=(t,e={},i)=>t?R.create().superRefine(((n,s)=>{var o,r;if(!t(n)){const t="function"==typeof e?e(n):"string"==typeof e?{message:e}:e,a=null===(r=null!==(o=t.fatal)&&void 0!==o?o:i)||void 0===r||r,l="string"==typeof t?{message:t}:t;s.addIssue({code:"custom",...l,fatal:a})}})):R.create(),e.late={object:F.lazycreate},function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"}(at=e.ZodFirstPartyTypeKind||(e.ZodFirstPartyTypeKind={})),e.instanceof=(t,i={message:`Input not instance of ${t.name}`})=>(0,e.custom)((e=>e instanceof t),i);const lt=x.create;e.string=lt;const ht=C.create;e.number=ht;const dt=nt.create;e.nan=dt;const ct=S.create;e.bigint=ct;const ut=T.create;e.boolean=ut;const pt=b.create;e.date=pt;const gt=k.create;e.symbol=gt;const ft=I.create;e.undefined=ft;const mt=E.create;e.null=mt;const _t=R.create;e.any=_t;const yt=P.create;e.unknown=yt;const vt=M.create;e.never=vt;const xt=A.create;e.void=xt;const wt=L.create;e.array=wt;const Ct=F.create;e.object=Ct;const St=F.strictCreate;e.strictObject=St;const Tt=D.create;e.union=Tt;const bt=N.create;e.discriminatedUnion=bt;const kt=j.create;e.intersection=kt;const It=$.create;e.tuple=It;const Et=W.create;e.record=Et;const Rt=G.create;e.map=Rt;const Pt=B.create;e.set=Pt;const Mt=V.create;e.function=Mt;const At=U.create;e.lazy=At;const Lt=X.create;e.literal=Lt;const Ot=Y.create;e.enum=Ot;const Ft=H.create;e.nativeEnum=Ft;const Dt=q.create;e.promise=Dt;const Zt=J.create;e.effect=Zt,e.transformer=Zt;
1const Nt=Q.create;e.optional=Nt;const zt=tt.create;e.nullable=zt;const jt=J.createWithPreprocess;e.preprocess=jt;const $t=ot.create;e.pipeline=$t,e.ostring=()=>lt().optional(),e.onumber=()=>ht().optional(),e.oboolean=()=>ut().optional(),e.coerce={string:t=>x.create({...t,coerce:!0}),number:t=>C.create({...t,coerce:!0}),boolean:t=>T.create({...t,coerce:!0}),bigint:t=>S.create({...t,coerce:!0}),date:t=>b.create({...t,coerce:!0})},e.NEVER=o.INVALID},5311:function(t){"use strict";t.exports=jQuery},2384:function(t,e,i){"use strict";var n=i(8509),s=(i(8754),class{sm;md;lg;constructor(){this.sm=768,this.md=1024,this.lg=1200}isMobile(){return window.innerWidth<=this.sm-1}isTabletPortrait(){const t=window.innerWidth;return t>=this.sm&&t<=991}isTabletLandscape(){const t=window.innerWidth;return t>=992&&t<=this.md}isDesktop(){return window.innerWidth>=this.lg}atLeastTabletPortrait(){return window.innerWidth>=this.sm}smallerThanTabletPortrait(){return window.innerWidth<=this.sm}atLeastTabletLandscape(){return window.innerWidth>=992}smallerThanTabletLandscape(){return window.innerWidth<=992}smallerThanCustomSize(t){return window.innerWidth<=t}atLeastCustomSize(t){return window.innerWidth>=t}isRealDevice(){return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)&&void 0!==window.orientation}}),o=t=>{let e=Array.from(t.querySelectorAll("\n\t\tiframe,\n\t\tobject,\n\t\tembed,\n\t\ta[href],\n\t\tarea[href],\n\t\tbutton,\n\t\tinput,\n\t\tselect,\n\t\ttextarea,\n\t\tdetails,\n\t\tsummary:not(:disabled),\n\t\t*[contenteditable]\n\t\t"));return e=e.filter((t=>{const e="true"===t.getAttribute("aria-hidden");return"none"!==window.getComputedStyle(t,null).display&&!t.hasAttribute("disabled")&&!e})),e=e.filter((t=>{const e=t.closest("[aria-hidden]")?.getAttribute("aria-hidden");return!("true"===e)})),e.filter((t=>"-1"!==t.getAttribute("tabindex")))},r=class{trap(t,e){const i=o(t),n=document.activeElement,s=i.length,r=i.findIndex((t=>t===n));if(e.shiftKey){if(0===r){const t=i[s-1];t?.focus(),e.preventDefault()}}else r===s-1&&i.length>0&&((a=t,o(a)[0]).focus(),e.preventDefault());var a}},a={trigger:null,target:null,disableScroll:!1,disableTrap:!1,customScrollableElement:null,focusInputClass:null,focusInput:!1,defaultButtonText:null,closeButtonText:null,isChildToggle:!1};e.Gn=class{element;config;options;_moduleName;_triggers;_targets;_tabFocus;_responsiveHelper;_buttonTextTarget;constructor(t,e){this.element=t,this.options=e,this._moduleName=this.options?.moduleName?this.options.moduleName:"",this.config=this.element.dataset.config?{...a,...JSON.parse(this.element.dataset.config)}:{},this._triggers=[],this._targets=[],this._tabFocus=new r,this._responsiveHelper=new s,this._buttonTextTarget=".btn__text, [data-button-text]",void 0!==this.config.trigger?void 0!==this.config.target?(this.reset(),this.addEventListeners()):console.warn("MrToggle: Target property not found in data-config"):console.warn("MrToggle: Trigger property not found in data-config")}reset(){0!==this._moduleName?.length&&Array.from(document.querySelectorAll(`[data-module="${this._moduleName}"]`)).forEach((t=>{const e=t.dataset.config?{...a,...JSON.parse(t.dataset.config)}:null;if(e){if(e.trigger){const t=document.querySelector(e.trigger);t&&this._triggers.push(t)}if(e.target){const t=document.querySelector(e.target);t&&this._targets.push(t)}}}))}closeAllToggles(){this.close()}addEventListeners(){this.config.trigger&&(document.querySelectorAll(this.config.trigger).forEach((t=>{t.addEventListener("click",this.handleClick.bind(this))})),this.element.addEventListener("keydown",this.handleKeyboard.bind(this)),this.options?.useHover&&!this._responsiveHelper.isRealDevice()&&(this.element.addEventListener("mouseenter",this.open.bind(this)),this.element.addEventListener("mouseleave",this.handleMouseLeave.bind(this))))}handleClick(){this.config.trigger&&("false"===document.querySelector(this.config.trigger)?.getAttribute("aria-expanded")?this.open():this.close())}open(){if(!this.config.trigger||!this.config.target)return;this.config.isChildToggle||this.resetAllToggles();const t=document.querySelector(this.config.trigger),e=document.querySelector(this.config.target);if(!t||!e)return;t.setAttribute("aria-expanded","true");const i=t.getAttribute("data-expanded");if(i&&t.setAttribute("aria-label",i),e.setAttribute("aria-hidden","false"),this.config.disableScroll){let t=null;this.config.customScrollableElement&&(t=document.querySelector(this.config.customScrollableElement)),t?n.disableBodyScroll(t):n.disableBodyScroll(e)}if(this.config.closeButtonText&&this.config.defaultButtonText){const e=t.querySelector(this._buttonTextTarget);e instanceof HTMLElement&&(e.textContent=this.config.closeButtonText)}this.config.focusInput&&setTimeout((()=>{let t=e.querySelector("input");this.config.focusInputClass&&(t=e.querySelector(this.config.focusInputClass)),t?.focus()}),100),this.element.dispatchEvent(new Event("openMrToggle"))}close(){if(!this.config.trigger||!this.config.target)return;const t=document.querySelector(this.config.trigger),e=document.querySelector(this.config.target);if(!t||!e)return;
1t.setAttribute("aria-expanded","false");const i=t.getAttribute("data-collapsed");if(i&&t.setAttribute("aria-label",i),e.setAttribute("aria-hidden","true"),this.config.closeButtonText&&this.config.defaultButtonText){const e=t.querySelector(this._buttonTextTarget);e instanceof HTMLElement&&(e.textContent=this.config.defaultButtonText)}this.config.disableScroll&&n.clearAllBodyScrollLocks(),t.focus(),this.element.dispatchEvent(new Event("closeMrToggle"))}handleMouseLeave(){if(this.close(),!this.config.trigger)return;const t=document.querySelector(this.config.trigger);t?.blur()}handleKeyboard(t){"Escape"===t.key&&this.close(),this.config.disableTrap||"Tab"===t.key&&this.config.trigger&&"true"===document.querySelector(this.config.trigger)?.getAttribute("aria-expanded")&&this._tabFocus.trap(this.element,t)}resetAllToggles(){this._triggers.forEach((t=>{t.setAttribute("aria-expanded","false");const e=t.getAttribute("data-collapsed");e&&t.setAttribute("aria-label",e);const i=t.closest(`[data-module="${this._moduleName}"]`),s=i?.dataset.config?JSON.parse(i.dataset.config):null;if(s?.closeButtonText&&s?.defaultButtonText){const e=t.querySelector(this._buttonTextTarget);e instanceof HTMLElement&&(e.textContent=s.defaultButtonText?s.defaultButtonText:"")}s.disableScroll&&n.clearAllBodyScrollLocks()})),this._targets.forEach((t=>{t.setAttribute("aria-hidden","true")}))}},e.QA=s,e.M4=r}},e={};function i(n){var s=e[n];if(void 0!==s)return s.exports;var o=e[n]={exports:{}};return t[n].call(o.exports,o,o.exports,i),o.exports}i.d=function(t,e){for(var n in e)i.o(e,n)&&!i.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},function(){var t;i.g.importScripts&&(t=i.g.location+"");var e=i.g.document;if(!t&&e&&(e.currentScript&&(t=e.currentScript.src),!t)){var n=e.getElementsByTagName("script");if(n.length)for(var s=n.length-1;s>-1&&!t;)t=n[s--].src}if(!t)throw new Error("Automatic publicPath is not supported in this browser");t=t.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),i.p=t}(),function(){"use strict";var t,e=i(2384),n=i(5311);t=n,(window.app=window.app||{}).primaryNav=function(i){var n,s=t(i).data("config")||{},o=s.class?s.class:"primary-nav",r={parent:"".concat(o,"__item--parent"),link:"".concat(o,"__link"),arrow:"".concat(o,"__arrow"),sub:"".concat(o,"-sub")},a=t(i),l=a.find(".".concat(r.parent)),h=a.parents("header"),d=new e.QA;function c(){t(this).children(".".concat(r.sub)).attr("aria-hidden",!1),t(this).children(".".concat(r.arrow)).attr("aria-expanded",!0)}function u(){t(this).children(".".concat(r.sub)).attr("aria-hidden",!0),t(this).children(".".concat(r.arrow)).attr("aria-expanded",!1)}function p(){a.find(".".concat(r.sub)).attr("aria-hidden",!0),a.find(".".concat(r.arrow)).attr("aria-expanded",!1)}n='<button class="'.concat(r.arrow,'" aria-expanded="false">\n\t\t\t\t\t<span class="icon icon-dropdown"></span>\n\t\t\t\t\t<span class="screen-reader-text">').concat(i18n.navigation.subMenu,"</span>\n\t\t\t\t</button>"),l.find(".".concat(r.sub)).before(n),a.find(".".concat(r.sub)).attr("aria-hidden",!0),t(window).on("load resize orientationchange",(function(){d.isDesktop()&&(l.on("mouseenter",c),l.on("mouseleave",u))})),a.find(".".concat(r.arrow)).on("click",(function(){var e=t(this);"false"===e.attr("aria-expanded")?(e.attr("aria-expanded",!0),e.next().attr("aria-hidden",!1)):(e.attr("aria-expanded",!1),e.next().attr("aria-hidden",!0))})),a.on("keydown",(function(t){27===t.which&&p()})),a.on("keyup",(function(t){if(9===t.which){var e=a.find(":focus");e.attr("class")===r.link?(a.find(".".concat(r.sub)).attr("aria-hidden",!0),a.find(".".concat(r.arrow)).attr("aria-expanded",!1)):e.closest(".".concat(r.sub)).length&&(e.closest(".".concat(r.sub)).find(".".concat(r.sub)).attr("aria-hidden",!0),e.closest(".".concat(r.sub)).find(".".concat(r.arrow)).attr("aria-expanded",!1))}})),h.on("keyup",(function(t){9!==t.which||t.shiftKey||0===a.find(":focus").length&&p()}))},i(2),i(8704),i(2671),i(7090),i(5291),function(t,i){(window.app=window.app||{}
1).toggle=function(i){var n=t(i).data("config"),s=new e.QA;!function(){var o=new e.Gn(i,{moduleName:"toggle"});if(n.activeClass&&n.activeClassElements){var r=t(n.activeClassElements),a=t(n.overlay),l=n.activeClass;i.addEventListener("openMrToggle",(function(){r.addClass(l),r.first().data("current-trigger",n.trigger),a.attr("aria-hidden","false")})),i.addEventListener("closeMrToggle",(function(){r.removeClass(l),r.first().data("current-trigger",null),a.attr("aria-hidden","true")}))}n.overlayHiddenOn&&n.activeClassElements&&t(window).on("resize onorientationchange",(function(){t(n.activeClassElements).first().data("current-trigger")===n.trigger&&(s.isDesktop()&&"Desktop"===n.overlayHiddenOn&&o.close(),s.isDesktop()||"lessThanDesktop"!==n.overlayHiddenOn||o.close())}))}()}}(i(5311)),i(2282),i(7475),function(t,e){(window.app=window.app||{}).slider=function(e){var i,n=t(e),s=n.find(".slider-counter__initial"),o=n.find(".slider-counter__total"),r=n.find(".slider-nav__button--fullscreen"),a=n.find(".slider-overlay"),l=n.data("class"),h=n.find(".".concat(l)),d=n.find(".slider-caption").first();h.on("init reInit afterChange",(function(t,e,i){var n=i||0,a=n+1;s.text("".concat(a<10?"0".concat(a):a)),o.text("".concat(e.slideCount<10?"0".concat(e.slideCount):e.slideCount)),r.length&&r.data("current-slide",n)})),h.on("init reInit afterChange",(function(e,i,n){if(d.length){var s=t(i.$slides.get(n)).find("[data-caption]").data("caption");d.text(s||"")}})),h.on("init reInit setPosition",(function(e,i){var n=h.width(),s=i.$slideTrack.height();h.find(".slick-slide").each((function(){var e=t(this).find("img"),i=e.attr("width"),o=e.attr("height"),r=i*(s/o)>n;t(this).css({height:s+"px",width:r?n+"px":"auto"})}))})),r.length&&r.on("click",(function(){t(this).is("[aria-expanded='false']")?a.trigger("openSliderOverlay",t(this).data("current-slide")):a.trigger("closeSliderOverlay")})),i={dots:!1,slidesToShow:1,infinite:!0,centerMode:!1,variableWidth:!0,speed:300,adaptiveHeight:!1,prevArrow:n.find(".slider-nav__button--prev"),nextArrow:n.find(".slider-nav__button--next")},h.slick(i)}}(i(5311)),function(t,e){(window.app=window.app||{}).sliderOverlay=function(e){var i=t(e),n=i.find(".slider-counter__initial"),s=i.find(".slider-counter__total"),o=i.data("class"),r=i.find(".".concat(o)),a=i.find(".slider-caption").first();function l(t,e,i){var o=(i||0)+1;n.text(o),s.text(e.slideCount)}function h(e,i,n){if(a.length){var s=t(i.$slides.get(n)).find("[data-caption]").data("caption");a.text(s||"")}}i.on("openSliderOverlay",(function(t,e){r.on("init reInit afterChange",l),r.on("init reInit afterChange",h),function(t){var e={dots:!1,slidesToShow:1,infinite:!0,centerMode:!0,variableWidth:!0,speed:300,adaptiveHeight:!1,prevArrow:i.find(".slider-nav__button--prev"),nextArrow:i.find(".slider-nav__button--next")};r.slick(e),r.slick("slickGoTo",t,!0)}(e)})),i.on("closeSliderOverlay",(function(){r.slick("unslick")}))}}(i(5311)),function(t,e){(window.app=window.app||{}).sliderTimeline=function(e){var i,n=t(e),s=n.find(".slider-counter__initial"),o=n.find(".slider-counter__total"),r=n.find(".slider-nav__button--fullscreen"),a=n.data("class"),l=n.find(".".concat(a));l.on("init reInit afterChange",(function(t,e,i){var n=i||0,a=n+1;s.text(a),o.text(e.slideCount),r.length&&r.data("current-slide",n)})),l.on("keydown",(function(t){37===t.which&&l.slick("slickPrev"),39===t.which&&l.slick("slickNext"),l.find(".slick-slide.slick-current.slick-active").first().find("a").trigger("focus")})),i={dots:!1,slidesToShow:1,infinite:!1,centerMode:!1,variableWidth:!0,speed:300,adaptiveHeight:!1,prevArrow:n.find(".slider-nav__button--prev"),nextArrow:n.find(".slider-nav__button--next")},l.slick(i)}}(i(5311)),i(5290),function(t,i){(window.app=window.app||{}).stickyScrollSlider=function(i){var n=t(i),s=n.find(".sticky-scroll__item"),o=n.find(".sticky-scroll__image"),r=n.find(".sticky-scroll__sticky"),a=new e.QA;function l(){if(a.atLeastTabletPortrait()){var e=window.innerHeight-n.find(".sticky-scroll__image--visible").height(),l=window.getComputedStyle(i).getPropertyValue("--admin-bar-height"),h=window.getComputedStyle(i).getPropertyValue("--header-height");r.css({top:e/2+l+h})}else r.removeAttr("style"),s.removeAttr("style");var d=new IntersectionObserver((function(e){e.forEach((function(e){var i=t(e.target).attr("data-index");e.isIntersecting&&(o.removeClass("sticky-scroll__image--visible"),n.find('.sticky-scroll__image[data-index="'.concat(i,'"]')).addClass("sticky-scroll__image--visible"))}))}),{root:null,rootMargin:"0px 0px",threshold:.6});s.length>0&&s.each((function(t,e){d.observe(e)}))}l(),t(window).on("resize onorientationchange",(function(){l()}))}}(i(5311));var s=i(8509);!function(t,i){(window.app=window.app||{}).filterModal=function(i){var n=t(i),o=n.find(".js--toggle-filter-modal"),r=n.find(".js--close-filter-modal"),a=n.find(".js--apply-filters").first(),l=n.find(".filter-modal"),h=t(".filter-overlay"),d=n.find(".filter-modal__inner"),c=new e.M4,u=new e.QA;function p(){"true"===l.attr("aria-hidden")?(o.attr("aria-expanded",!0),r.attr("aria-expanded",!0),o.attr("aria-label",o.attr("data-expanded")),l.attr("aria-hidden",!1),h.addClass("filter-overlay--active"),(u.isMobile()||u.isTabletPortrait()||u.isTabletLandscape())&&(0,s.disableBodyScroll)(d[0])):g()}function g(){o.attr("aria-expanded",!1),o.attr("aria-label",o.attr("data-collapsed")),l.attr("aria-hidden",!0),h.removeClass("filter-overlay--active"),(u.isMobile()||u.isTabletPortrait()||u.isTabletLandscape())&&(0,s.enableBodyScroll)(d[0])}function f(){var t=n.find(".filter-modal__header"),e=n.find(".filter-modal__footer");d.css({top:t.outerHeight(!0),bottom:e.outerHeight(!0)})}o.on("click",p),r.on("click",p),h.on("click",p),n.on("keydown",(function(t){9===t.which&&"true"===o.attr("aria-expanded")&&
1c.trap(l,t),27===t.which&&g()})),a.on("click",(function(){var e=window.location,i=function(t,e){for(var i=t.substring(1).split("&"),n=0;n<i.length;n++){var s=i[n].split("=");if("s"===s[0])return s[1]}return!1}(e.search),n="".concat(e.origin,"?s=").concat(i);a.data("url",n),d.find("select").each((function(){var e=t(this).val();e&&a.data("url","".concat(a.data("url"),"&").concat(e))})),a.data("url")!==e.href&&(window.location.href=a.data("url"))})),t(window).on("resize onorientationchange",f),f(),t(document).on("click",(function(t){n.is(t.target)||0!==n.has(t.target).length||g()}))}}(i(5311)),i(1074);const o=class{constructor(t){this.propagationStopped,this.defaultPrevented,this.type=t,this.target=null}preventDefault(){this.defaultPrevented=!0}stopPropagation(){this.propagationStopped=!0}},r="propertychange",a=class{constructor(){this.disposed=!1}dispose(){this.disposed||(this.disposed=!0,this.disposeInternal())}disposeInternal(){}};function l(t,e){return t>e?1:t<e?-1:0}function h(t,e,i){if(t[0]<=e)return 0;const n=t.length;if(e<=t[n-1])return n-1;if("function"==typeof i){for(let s=1;s<n;++s){const n=t[s];if(n===e)return s;if(n<e)return i(e,t[s-1],n)>0?s-1:s}return n-1}if(i>0){for(let i=1;i<n;++i)if(t[i]<e)return i-1;return n-1}if(i<0){for(let i=1;i<n;++i)if(t[i]<=e)return i;return n-1}for(let i=1;i<n;++i){if(t[i]==e)return i;if(t[i]<e)return t[i-1]-e<e-t[i]?i-1:i}return n-1}function d(t,e,i){for(;e<i;){const n=t[e];t[e]=t[i],t[i]=n,++e,--i}}function c(t,e){const i=Array.isArray(e)?e:[e],n=i.length;for(let e=0;e<n;e++)t[t.length]=i[e]}function u(t,e){const i=t.length;if(i!==e.length)return!1;for(let n=0;n<i;n++)if(t[n]!==e[n])return!1;return!0}function p(){return!0}function g(){return!1}function f(){}function m(t){for(const e in t)delete t[e]}function _(t){let e;for(e in t)return!1;return!e}const y=class extends a{constructor(t){super(),this.eventTarget_=t,this.pendingRemovals_=null,this.dispatching_=null,this.listeners_=null}addEventListener(t,e){if(!t||!e)return;const i=this.listeners_||(this.listeners_={}),n=i[t]||(i[t]=[]);n.includes(e)||n.push(e)}dispatchEvent(t){const e="string"==typeof t,i=e?t:t.type,n=this.listeners_&&this.listeners_[i];if(!n)return;const s=e?new o(t):t;s.target||(s.target=this.eventTarget_||this);const r=this.dispatching_||(this.dispatching_={}),a=this.pendingRemovals_||(this.pendingRemovals_={});let l;i in r||(r[i]=0,a[i]=0),++r[i];for(let t=0,e=n.length;t<e;++t)if(l="handleEvent"in n[t]?n[t].handleEvent(s):n[t].call(this,s),!1===l||s.propagationStopped){l=!1;break}if(0==--r[i]){let t=a[i];for(delete a[i];t--;)this.removeEventListener(i,f);delete r[i]}return l}disposeInternal(){this.listeners_&&m(this.listeners_)}getListeners(t){return this.listeners_&&this.listeners_[t]||void 0}hasListener(t){return!!this.listeners_&&(t?t in this.listeners_:Object.keys(this.listeners_).length>0)}removeEventListener(t,e){const i=this.listeners_&&this.listeners_[t];if(i){const n=i.indexOf(e);-1!==n&&(this.pendingRemovals_&&t in this.pendingRemovals_?(i[n]=f,++this.pendingRemovals_[t]):(i.splice(n,1),0===i.length&&delete this.listeners_[t]))}}},v="change",x="contextmenu",w="click",C="keydown",S="keypress",T="touchmove",b="wheel";function k(t,e,i,n,s){if(n&&n!==t&&(i=i.bind(n)),s){const n=i;i=function(){t.removeEventListener(e,i),n.apply(this,arguments)}}const o={target:t,type:e,listener:i};return t.addEventListener(e,i),o}function I(t,e,i,n){return k(t,e,i,n,!0)}function E(t){t&&t.target&&(t.target.removeEventListener(t.type,t.listener),m(t))}class R extends y{constructor(){super(),this.on=this.onInternal,this.once=this.onceInternal,this.un=this.unInternal,this.revision_=0}changed(){++this.revision_,this.dispatchEvent(v)}getRevision(){return this.revision_}onInternal(t,e){if(Array.isArray(t)){const i=t.length,n=new Array(i);for(let s=0;s<i;++s)n[s]=k(this,t[s],e);return n}return k(this,t,e)}onceInternal(t,e){let i;if(Array.isArray(t)){const n=t.length;i=new Array(n);for(let s=0;s<n;++s)i[s]=I(this,t[s],e)}else i=I(this,t,e);return e.ol_key=i,i}unInternal(t,e){const i=e.ol_key;if(i)!function(t){if(Array.isArray(t))for(let e=0,i=t.length;e<i;++e)E(t[e]);else E(t)}(i);else if(Array.isArray(t))for(let i=0,n=t.length;i<n;++i)this.removeEventListener(t[i],e);else this.removeEventListener(t,e)}}R.prototype.on,R.prototype.once,R.prototype.un;const P=R;function M(){throw new Error("Unimplemented abstract method.")}let A=0;function L(t){return t.ol_uid||(t.ol_uid=String(++A))}class O extends o{constructor(t,e,i){super(t),this.key=e,this.oldValue=i}}const F=class extends P{constructor(t){super(),this.on,this.once,this.un,L(this),this.values_=null,void 0!==t&&this.setProperties(t)}get(t){let e;return this.values_&&this.values_.hasOwnProperty(t)&&(e=this.values_[t]),e}getKeys(){return this.values_&&Object.keys(this.values_)||[]}getProperties(){return this.values_&&Object.assign({},this.values_)||{}}hasProperties(){return!!this.values_}notify(t,e){let i;i=`change:${t}`,this.hasListener(i)&&this.dispatchEvent(new O(i,t,e)),i=r,this.hasListener(i)&&this.dispatchEvent(new O(i,t,e))}addChangeListener(t,e){this.addEventListener(`change:${t}`,e)}removeChangeListener(t,e){this.removeEventListener(`change:${t}`,e)}set(t,e,i){const n=this.values_||(this.values_={});if(i)n[t]=e;else{const i=n[t];n[t]=e,i!==e&&this.notify(t,i)}}setProperties(t,e){for(const i in t)this.set(i,t[i],e)}applyProperties(t){t.values_&&Object.assign(this.values_||(this.values_={}),t.values_)}unset(t,e){if(this.values_&&t in this.values_){const i=this.values_[t];delete this.values_[t],_(this.values_)&&(this.values_=null),e||this.notify(t,i)}}},D={1:"The view center is not defined",2:"The view resolution is not defined",3:"The view rotation is not defined",4:"`image` and `src` cannot be provided at the same time",5:"`imgSize` must be set when `image` is provided",7:"`format` must be set when `url` is set",8:"Unknown `serverType` configured",9:"`url` must be configured or set using `#setUrl()`",10:"The default `geometryFunction` can only handle `Point` geometries",11:"`options.featureTypes` must be an Array",12:"`options.geometryName` must also be provided when `options.bbox` is set",13:"Invalid corner",14:"Invalid color",15:"Tried to get a value for a key that does not exist in the cache",16:"Tried to set a value for a key that is used already",17:"`resolutions` must be sorted in descending order",18:"Either `origin` or `origins` must be configured, never both",19:"Number of `tileSizes` and `resolutions` must be equal",20:"Number of `origins` and `resolutions` must be equal",22:"Either `tileSize` or `tileSizes` must be configured, never both",24:"Invalid extent or geometry provided as `geometry`",25:"Cannot fit empty extent provided as `geometry`",26:"Features must have an id set",27:"Features must have an id set",28:'`renderMode` must be `"hybrid"` or `"vector"`',30:"The passed `feature` was already added to the source",31:"Tried to enqueue an `element` that was already added to the queue",32:"Transformation matrix cannot be inverted",33:"Invalid units",34:"Invalid geometry layout",36:"Unknown SRS type",37:"Unknown geometry type found",38:"`styleMapValue` has an unknown type",39:"Unknown geometry type",40:"Expected `feature` to have a geometry",41:"Expected an `ol/style/Style` or an array of `ol/style/Style.js`",42:"Question unknown, the answer is 42",43:"Expected `layers` to be an array or a `Collection`",47:"Expected `controls` to be an array or an `ol/Collection`",48:"Expected `interactions` to be an array or an `ol/Collection`",49:"Expected `overlays` to be an array or an `ol/Collection`",50:"`options.featureTypes` should be an Array",51:"Either `url` or `tileJSON` options must be provided",52:"Unknown `serverType` configured",53:"Unknown `tierSizeCalculation` configured",55:"The {-y} placeholder requires a tile grid with extent",56:"mapBrowserEvent must originate from a pointer event",57:"At least 2 conditions are required",59:"Invalid command found in the PBF",60:"Missing or invalid `size`",61:"Cannot determine IIIF Image API version from provided image information JSON",62:"A `WebGLArrayBuffer` must either be of type `ELEMENT_ARRAY_BUFFER` or `ARRAY_BUFFER`",64:"Layer opacity must be a number",66:"`forEac
1hFeatureAtCoordinate` cannot be used on a WebGL layer if the hit detection logic has not been enabled. This is done by providing adequate shaders using the `hitVertexShader` and `hitFragmentShader` properties of `WebGLPointsLayerRenderer`",67:"A layer can only be added to the map once. Use either `layer.setMap()` or `map.addLayer()`, not both",68:"A VectorTile source can only be rendered if it has a projection compatible with the view projection",69:"`width` or `height` cannot be provided together with `scale`"};class Z extends Error{constructor(t){const e=D[t];super(e),this.code=t,this.name="AssertionError",this.message=e}}const N=Z,z="add",j="remove",$="length";class W extends o{constructor(t,e,i){super(t),this.element=e,this.index=i}}const G=class extends F{constructor(t,e){if(super(),this.on,this.once,this.un,e=e||{},this.unique_=!!e.unique,this.array_=t||[],this.unique_)for(let t=0,e=this.array_.length;t<e;++t)this.assertUnique_(this.array_[t],t);this.updateLength_()}clear(){for(;this.getLength()>0;)this.pop()}extend(t){for(let e=0,i=t.length;e<i;++e)this.push(t[e]);return this}forEach(t){const e=this.array_;for(let i=0,n=e.length;i<n;++i)t(e[i],i,e)}getArray(){return this.array_}item(t){return this.array_[t]}getLength(){return this.get($)}insertAt(t,e){if(t<0||t>this.getLength())throw new Error("Index out of bounds: "+t);this.unique_&&this.assertUnique_(e),this.array_.splice(t,0,e),this.updateLength_(),this.dispatchEvent(new W(z,e,t))}pop(){return this.removeAt(this.getLength()-1)}push(t){this.unique_&&this.assertUnique_(t);const e=this.getLength();return this.insertAt(e,t),this.getLength()}remove(t){const e=this.array_;for(let i=0,n=e.length;i<n;++i)if(e[i]===t)return this.removeAt(i)}removeAt(t){if(t<0||t>=this.getLength())return;const e=this.array_[t];return this.array_.splice(t,1),this.updateLength_(),this.dispatchEvent(new W(j,e,t)),e}setAt(t,e){if(t>=this.getLength())return void this.insertAt(t,e);if(t<0)throw new Error("Index out of bounds: "+t);this.unique_&&this.assertUnique_(e,t);const i=this.array_[t];this.array_[t]=e,this.dispatchEvent(new W(j,i,t)),this.dispatchEvent(new W(z,e,t))}updateLength_(){this.set($,this.array_.length)}assertUnique_(t,e){for(let i=0,n=this.array_.length;i<n;++i)if(this.array_[i]===t&&i!==e)throw new N(58)}},B="undefined"!=typeof navigator&&void 0!==navigator.userAgent?navigator.userAgent.toLowerCase():"",V=B.includes("firefox"),U=(B.includes("safari")&&!B.includes("chrom")&&(B.includes("version/15.4")||/cpu (os|iphone os) 15_4 like mac os x/.test(B)),B.includes("webkit")&&!B.includes("edge")),X=B.includes("macintosh"),K="undefined"!=typeof devicePixelRatio?devicePixelRatio:1,Y="undefined"!=typeof WorkerGlobalScope&&"undefined"!=typeof OffscreenCanvas&&self instanceof WorkerGlobalScope,H="undefined"!=typeof Image&&Image.prototype.decode,q=function(){let t=!1;try{const e=Object.defineProperty({},"passive",{get:function(){t=!0}});window.addEventListener("_",null,e),window.removeEventListener("_",null,e)}catch(t){}return t}();function J(t,e){if(!t)throw new N(e)}function Q(t,e){const i=e[0],n=e[1];return e[0]=t[0]*i+t[2]*n+t[4],e[1]=t[1]*i+t[3]*n+t[5],e}function tt(t,e,i,n,s,o,r,a){const l=Math.sin(o),h=Math.cos(o);return t[0]=n*h,t[1]=s*l,t[2]=-n*l,t[3]=s*h,t[4]=r*n*h-a*n*l+e,t[5]=r*s*l+a*s*h+i,t}function et(t,e){const i=(n=e)[0]*n[3]-n[1]*n[2];var n;J(0!==i,32);const s=e[0],o=e[1],r=e[2],a=e[3],l=e[4],h=e[5];return t[0]=a/i,t[1]=-o/i,t[2]=-r/i,t[3]=s/i,t[4]=(r*h-a*l)/i,t[5]=-(s*h-o*l)/i,t}let it;function nt(t){const e="matrix("+t.join(", ")+")";if(Y)return e;const i=it||(it=document.createElement("div"));return i.style.transform=e,i.style.transform}new Array(6);const st={UNKNOWN:0,INTERSECTING:1,ABOVE:2,RIGHT:4,BELOW:8,LEFT:16};function ot(t){const e=[1/0,1/0,-1/0,-1/0];for(let i=0,n=t.length;i<n;++i)mt(e,t[i]);return e}function rt(t,e,i){return i?(i[0]=t[0]-e,i[1]=t[1]-e,i[2]=t[2]+e,i[3]=t[3]+e,i):[t[0]-e,t[1]-e,t[2]+e,t[3]+e]}function at(t,e){return e?(e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e):t.slice()}function lt(t,e,i){let n,s;return n=e<t[0]?t[0]-e:t[2]<e?e-t[2]:0,s=i<t[1]?t[1]-i:t[3]<i?i-t[3]:0,n*n+s*s}function ht(t,e){return ct(t,e[0],e[1])}function dt(t,e){return t[0]<=e[0]&&e[2]<=t[2]&&t[1]<=e[1]&&e[3]<=t[3]}function ct(t,e,i){return t[0]<=e&&e<=t[2]&&t[1]<=i&&i<=t[3]}function ut(t,e){const i=t[0],n=t[1],s=t[2],o=t[3],r=e[0],a=e[1];let l=st.UNKNOWN;return r<i?l|=st.LEFT:r>s&&(l|=st.RIGHT),a<n?l|=st.BELOW:a>o&&(l|=st.ABOVE),l===st.UNKNOWN&&(l=st.INTERSECTING),l}function pt(t,e,i,n,s){return s?(s[0]=t,s[1]=e,s[2]=i,s[3]=n,s):[t,e,i,n]}function gt(t){return pt(1/0,1/0,-1/0,-1/0,t)}function ft(t,e){return t[0]==e[0]&&t[2]==e[2]&&t[1]==e[1]&&t[3]==e[3]}function mt(t,e){e[0]<t[0]&&(t[0]=e[0]),e[0]>t[2]&&(t[2]=e[0]),e[1]<t[1]&&(t[1]=e[1]),e[1]>t[3]&&(t[3]=e[1])}function _t(t,e,i,n,s){for(;i<n;i+=s)yt(t,e[i],e[i+1]);return t}function yt(t,e,i){t[0]=Math.min(t[0],e),t[1]=Math.min(t[1],i),t[2]=Math.max(t[2],e),t[3]=Math.max(t[3],i)}function vt(t,e){let i;return i=e(wt(t)),i||(i=e(Ct(t)),i||(i=e(Pt(t)),i||(i=e(Rt(t)),i||!1)))}function xt(t){let e=0;return Lt(t)||(e=Mt(t)*It(t)),e}function wt(t){return[t[0],t[1]]}function Ct(t){return[t[2],t[1]]}function St(t){return[(t[0]+t[2])/2,(t[1]+t[3])/2]}function Tt(t,e){let i;return"bottom-left"===e?i=wt(t):"bottom-right"===e?i=Ct(t):"top-left"===e?i=Rt(t):"top-right"===e?i=Pt(t):J(!1,13),i}function bt(t,e,i,n,s){const[o,r,a,l,h,d,c,u]=kt(t,e,i,n);return pt(Math.min(o,a,h,c),Math.min(r,l,d,u),Math.max(o,a,h,c),Math.max(r,l,d,u),s)}function kt(t,e,i,n){const s=e*n[0]/2,o=e*n[1]/2,r=Math.cos(i),a=Math.sin(i),l=s*r,h=s*a,d=o*r,c=o*a,u=t[0],p=t[1];return[u-l+c,p-h-d,u-l-c,p-h+d,u+l-c,p+h+d,u+l+c,p+h-d,u-l+c,p-h-d]}function It(t){return t[3]-t[1]}function Et(t,e,i){const n=i||[1/0,1/0,-1/0,-1/0];return At(t,e)?(t[0]>e[0]?n[0]=t[0]:n[0]=e[0],t[1]>e[1]?n[1]=t[1]:n[1]=e[1],t[2]<e[2]?n[2]=t[2]:n[2]=e[2],t[3]<e[3]?n[3]=t[3]:n[3]=e[3]):gt(n),n}function Rt(t){return[t[0],t[3]]}function Pt(t){return[t[2],t[3]]}function Mt(t){return t[2]-t[0]}function At(t,e){return t[0]<=e[2]&&t[2]>=e[0]&&t[1]<=e[3]&&t[3]>=e[1]}function Lt(t){return t[2]<t[0]||t[3]<t[1]}function Ot(t,e){const i=e.getExtent(),n=St(t);if(e.canWrapX()&&(n[0]<i[0]||n[0]>=i[2])){const e=Mt(i),s=Math.floor((n[0]-i[0])/e)*e;t[0]-=s,t[2]-=s}return t}function Ft(t,e,i){return Math.min(Math.max(t,e),i)}function Dt(t,e,i,n,s,o){const r=s-i,a=o-n;if(0!==r||0!==a){const l=((t-i)*r+(e-n)*a)/(r*r+a*a);l>1?(i=s,n=o):l>0&&(i+=r*l,n+=a*l)}return Zt(t,e,i,n)}function Zt(t,e,i,n){const s=i-t,o=n-e;return s*s+o*o}function Nt(t){return t*Math.PI/180}function zt(t,e){const i=t%e;return i*e<0?i+e:i}function jt(t,e,i){return t+i*(e-t)}function $t(t,e){const i=Math.pow(10,e);return Math.round(t*i)/i}function Wt(t,e){return Math.floor($t(t,e))}function Gt(t,e){return Math.ceil($t(t,e))}const Bt=/^#([a-f0-9]{3}|[a-f0-9]{4}(?:[a-f0-9]{2}){0,2})$/i,Vt=/^([a-z]*)$|^hsla?\(.*\)$/i;function Ut(t){return"string"==typeof t?t:Ht(t)}const Xt=function(){const t={};let e=0;return function(i){let n;if(t.hasOwnProperty(i))n=t[i];else{if(e>=1024){let i=0;for(const n in t)0==(3&i++)&&(delete t[n],--e)}n=function(t){let e,i,n,s,o;if(Vt.exec(t)&&(t=function(t){const e=document.createElement("div");if(e.style.color=t,""!==e.style.color){document.body.appendChild(e);const t=getComputedStyle(e).color;return document.body.removeChild(e),t}return""}(t)),Bt.exec(t)){const r=t.length-1;let a;a=r<=4?1:2;const l=4===r||8===r;e=parseInt(t.substr(1+0*a,a),16),i=parseInt(t.substr(1+1*a,a),16),n=parseInt(t.substr(1+2*a,a),16),s=l?parseInt(t.substr(1+3*a,a),16):255,1==a&&(e=(e<<4)+e,i=(i<<4)+i,n=(n<<4)+n,l&&(s=(s<<4)+s)),o=[e,i,n,s/255]}else t.startsWith("rgba(")?(o=t.slice(5,-1).split(",").map(Number),Yt(o)):t.startsWith("rgb(")?(o=t.slice(4,-1).split(",").map(Number),o.push(1),Yt(o)):J(!1,14);return o}(i),t[i]=n,++e}return n}}();function Kt(t){return Array.isArray(t)?t:Xt(t)}function Yt(t){return t[0]=Ft(t[0]+.5|0,0,255),t[1]=Ft(t[1]+.5|0,0,255),t[2]=Ft(t[2]+.5|0,0,255),t[3]=Ft(t[3],0,1),t}function Ht(t){let e=t[0];e!=(0|e)&&(e=e+.5|0);let i=t[1];i!=(0|i)&&(i=i+.5|0);let n=t[2];return n!=(0|n)&&(n=n+.5|0),"rgba("+e+","+i+","+n+","+(void 0===t[3]?1:Math.round(100*t[3])/100)+")"}function qt(t,e,i){return e+":"+t+":"+(i?Ut(i):"null")}const Jt=new class{constructor(){this.cache_={},this.cacheSize_=0,this.maxCacheSize_=32}clear(){this.cache_={},this.cacheSize_=0}canExpireCache(){return this.cacheSize_>this.maxCacheSize_}
1expire(){if(this.canExpireCache()){let t=0;for(const e in this.cache_){const i=this.cache_[e];0!=(3&t++)||i.hasListener()||(delete this.cache_[e],--this.cacheSize_)}}}get(t,e,i){const n=qt(t,e,i);return n in this.cache_?this.cache_[n]:null}set(t,e,i,n){const s=qt(t,e,i);this.cache_[s]=n,++this.cacheSize_}setSize(t){this.maxCacheSize_=t,this.expire()}},Qt="opacity",te="visible",ee="extent",ie="zIndex",ne="maxResolution",se="minResolution",oe="maxZoom",re="minZoom",ae="source",le=class extends F{constructor(t){super(),this.on,this.once,this.un,this.background_=t.background;const e=Object.assign({},t);"object"==typeof t.properties&&(delete e.properties,Object.assign(e,t.properties)),e[Qt]=void 0!==t.opacity?t.opacity:1,J("number"==typeof e[Qt],64),e[te]=void 0===t.visible||t.visible,e[ie]=t.zIndex,e[ne]=void 0!==t.maxResolution?t.maxResolution:1/0,e[se]=void 0!==t.minResolution?t.minResolution:0,e[re]=void 0!==t.minZoom?t.minZoom:-1/0,e[oe]=void 0!==t.maxZoom?t.maxZoom:1/0,this.className_=void 0!==e.className?e.className:"ol-layer",delete e.className,this.setProperties(e),this.state_=null}getBackground(){return this.background_}getClassName(){return this.className_}getLayerState(t){const e=this.state_||{layer:this,managed:void 0===t||t},i=this.getZIndex();return e.opacity=Ft(Math.round(100*this.getOpacity())/100,0,1),e.visible=this.getVisible(),e.extent=this.getExtent(),e.zIndex=void 0!==i||e.managed?i:1/0,e.maxResolution=this.getMaxResolution(),e.minResolution=Math.max(this.getMinResolution(),0),e.minZoom=this.getMinZoom(),e.maxZoom=this.getMaxZoom(),this.state_=e,e}getLayersArray(t){return M()}getLayerStatesArray(t){return M()}getExtent(){return this.get(ee)}getMaxResolution(){return this.get(ne)}getMinResolution(){return this.get(se)}getMinZoom(){return this.get(re)}getMaxZoom(){return this.get(oe)}getOpacity(){return this.get(Qt)}getSourceState(){return M()}getVisible(){return this.get(te)}getZIndex(){return this.get(ie)}setBackground(t){this.background_=t,this.changed()}setExtent(t){this.set(ee,t)}setMaxResolution(t){this.set(ne,t)}setMinResolution(t){this.set(se,t)}setMaxZoom(t){this.set(oe,t)}setMinZoom(t){this.set(re,t)}setOpacity(t){J("number"==typeof t,64),this.set(Qt,t)}setVisible(t){this.set(te,t)}setZIndex(t){this.set(ie,t)}disposeInternal(){this.state_&&(this.state_.layer=null,this.state_=null),super.disposeInternal()}},he="prerender",de="postrender",ce="precompose",ue="rendercomplete",pe={CENTER:"center",RESOLUTION:"resolution",ROTATION:"rotation"},ge=42,fe=256,me={radians:6370997/(2*Math.PI),degrees:2*Math.PI*6370997/360,ft:.3048,m:1,"us-ft":1200/3937},_e=class{constructor(t){this.code_=t.code,this.units_=t.units,this.extent_=void 0!==t.extent?t.extent:null,this.worldExtent_=void 0!==t.worldExtent?t.worldExtent:null,this.axisOrientation_=void 0!==t.axisOrientation?t.axisOrientation:"enu",this.global_=void 0!==t.global&&t.global,this.canWrapX_=!(!this.global_||!this.extent_),this.getPointResolutionFunc_=t.getPointResolution,this.defaultTileGrid_=null,this.metersPerUnit_=t.metersPerUnit}canWrapX(){return this.canWrapX_}getCode(){return this.code_}getExtent(){return this.extent_}getUnits(){return this.units_}getMetersPerUnit(){return this.metersPerUnit_||me[this.units_]}getWorldExtent(){return this.worldExtent_}getAxisOrientation(){return this.axisOrientation_}isGlobal(){return this.global_}setGlobal(t){this.global_=t,this.canWrapX_=!(!t||!this.extent_)}getDefaultTileGrid(){return this.defaultTileGrid_}setDefaultTileGrid(t){this.defaultTileGrid_=t}setExtent(t){this.extent_=t,this.canWrapX_=!(!this.global_||!t)}setWorldExtent(t){this.worldExtent_=t}setGetPointResolution(t){this.getPointResolutionFunc_=t}getPointResolutionFunc(){return this.getPointResolutionFunc_}},ye=6378137,ve=Math.PI*ye,xe=[-ve,-ve,ve,ve],we=[-180,-85,180,85],Ce=ye*Math.log(Math.tan(Math.PI/2));class Se extends _e{constructor(t){super({code:t,units:"m",extent:xe,global:!0,worldExtent:we,getPointResolution:function(t,e){return t/Math.cosh(e[1]/ye)}})}}const Te=[new Se("EPSG:3857"),new Se("EPSG:102100"),new Se("EPSG:102113"),new Se("EPSG:900913"),new Se("http://www.opengis.net/def/crs/EPSG/0/3857"),new Se("http://www.opengis.net/gml/srs/epsg.xml#3857")];const be=[-180,-90,180,90],ke=6378137*Math.PI/180;
1class Ie extends _e{constructor(t,e){super({code:t,units:"degrees",extent:be,axisOrientation:e,global:!0,metersPerUnit:ke,worldExtent:be})}}const Ee=[new Ie("CRS:84"),new Ie("EPSG:4326","neu"),new Ie("urn:ogc:def:crs:OGC:1.3:CRS84"),new Ie("urn:ogc:def:crs:OGC:2:84"),new Ie("http://www.opengis.net/def/crs/OGC/1.3/CRS84"),new Ie("http://www.opengis.net/gml/srs/epsg.xml#4326","neu"),new Ie("http://www.opengis.net/def/crs/EPSG/0/4326","neu")];let Re={},Pe={};function Me(t,e,i){const n=t.getCode(),s=e.getCode();n in Pe||(Pe[n]={}),Pe[n][s]=i}function Ae(t,e){let i=!0;for(let n=t.length-1;n>=0;--n)if(t[n]!=e[n]){i=!1;break}return i}function Le(t,e){const i=Math.cos(e),n=Math.sin(e),s=t[0]*i-t[1]*n,o=t[1]*i+t[0]*n;return t[0]=s,t[1]=o,t}function Oe(t,e){if(e.canWrapX()){const i=Mt(e.getExtent()),n=function(t,e,i){const n=e.getExtent();let s=0;return e.canWrapX()&&(t[0]<n[0]||t[0]>n[2])&&(i=i||Mt(n),s=Math.floor((t[0]-n[0])/i)),s}(t,e,i);n&&(t[0]-=n*i)}return t}const Fe=6371008.8;function De(t,e,i){i=i||Fe;const n=Nt(t[1]),s=Nt(e[1]),o=(s-n)/2,r=Nt(e[0]-t[0])/2,a=Math.sin(o)*Math.sin(o)+Math.sin(r)*Math.sin(r)*Math.cos(n)*Math.cos(s);return 2*i*Math.atan2(Math.sqrt(a),Math.sqrt(1-a))}const Ze={info:1,warn:2,error:3,none:4};let Ne=Ze.info;function ze(...t){Ne>Ze.warn||console.warn(...t)}let je=!0;function $e(t,e){if(void 0!==e)for(let i=0,n=t.length;i<n;++i)e[i]=t[i];else e=t.slice();return e}function We(t,e){if(void 0!==e&&t!==e){for(let i=0,n=t.length;i<n;++i)e[i]=t[i];t=e}return t}function Ge(t){!function(t,e){Re[t]=e}(t.getCode(),t),Me(t,t,$e)}function Be(t){return"string"==typeof t?Re[e=t]||Re[e.replace(/urn:(x-)?ogc:def:crs:EPSG:(.*:)?(\w+)$/,"EPSG:$3")]||null:t||null;var e}function Ve(t,e,i,n){let s;const o=(t=Be(t)).getPointResolutionFunc();if(o){if(s=o(e,i),n&&n!==t.getUnits()){const e=t.getMetersPerUnit();e&&(s=s*e/me[n])}}else{const o=t.getUnits();if("degrees"==o&&!n||"degrees"==n)s=e;else{const r=Ye(t,Be("EPSG:4326"));if(r===We&&"degrees"!==o)s=e*t.getMetersPerUnit();else{let t=[i[0]-e/2,i[1],i[0]+e/2,i[1],i[0],i[1]-e/2,i[0],i[1]+e/2];t=r(t,t,2),s=(De(t.slice(0,2),t.slice(2,4))+De(t.slice(4,6),t.slice(6,8)))/2}const a=n?me[n]:t.getMetersPerUnit();void 0!==a&&(s/=a)}}return s}function Ue(t){!function(t){t.forEach(Ge)}(t),t.forEach((function(e){t.forEach((function(t){e!==t&&Me(e,t,$e)}))}))}function Xe(t,e){return t?"string"==typeof t?Be(t):t:Be(e)}function Ke(t,e){if(t===e)return!0;const i=t.getUnits()===e.getUnits();return(t.getCode()===e.getCode()||Ye(t,e)===$e)&&i}function Ye(t,e){let i=function(t,e){let i;return t in Pe&&e in Pe[t]&&(i=Pe[t][e]),i}(t.getCode(),e.getCode());return i||(i=We),i}function He(t,e){return Ye(Be(t),Be(e))}function qe(t,e,i){return He(e,i)(t,void 0,t.length)}let Je=null;function Qe(){return Je}function ti(t,e){return t}function ei(t,e){return je&&!Ae(t,[0,0])&&t[0]>=-180&&t[0]<=180&&t[1]>=-90&&t[1]<=90&&(je=!1,ze("Call useGeographic() from ol/proj once to work with [longitude, latitude] coordinates.")),t}function ii(t,e){return t}function ni(t,e){return t}function si(t,e){return t}var oi,ri,ai;function li(t,e,i){return function(n,s,o,r,a){if(!n)return;if(!s&&!e)return n;const l=e?0:o[0]*s,h=e?0:o[1]*s,d=a?a[0]:0,c=a?a[1]:0;let u=t[0]+l/2+d,p=t[2]-l/2+d,g=t[1]+h/2+c,f=t[3]-h/2+c;u>p&&(u=(p+u)/2,p=u),g>f&&(g=(f+g)/2,f=g);let m=Ft(n[0],u,p),_=Ft(n[1],g,f);if(r&&i&&s){const t=30*s;m+=-t*Math.log(1+Math.max(0,u-n[0])/t)+t*Math.log(1+Math.max(0,n[0]-p)/t),_+=-t*Math.log(1+Math.max(0,g-n[1])/t)+t*Math.log(1+Math.max(0,n[1]-f)/t)}return[m,_]}}function hi(t){return t}function di(t,e,i,n){const s=Mt(e)/i[0],o=It(e)/i[1];return n?Math.min(t,Math.max(s,o)):Math.min(t,Math.min(s,o))}function ci(t,e,i){let n=Math.min(t,e);return n*=Math.log(1+50*Math.max(0,t/e-1))/50+1,i&&(n=Math.max(n,i),n/=Math.log(1+50*Math.max(0,i/t-1))/50+1),Ft(n,i/2,2*e)}function ui(t,e,i,n,s){return i=void 0===i||i,function(o,r,a,l){if(void 0!==o){const r=n?di(t,n,a,s):t;return i&&l?ci(o,r,e):Ft(o,e,r)}}}function pi(t){if(void 0!==t)return 0}function gi(t){if(void 0!==t)return t}function fi(t){return Math.pow(t,3)}function mi(t){return 1-fi(1-t)}function _i(t){return 3*t*t-2*t*t*t}function yi(t){return t}function vi(t,e,i,n,s,o){o=o||[];let r=0;for(let a=e;a<i;a+=n){const e=t[a],i=t[a+1];o[r++]=s[0]*e+s[2]*i+s[4],o[r++]=s[1]*e+s[3]*i+s[5]}return o&&o.length!=r&&(o.length=r),o}function xi(t,e,i,n,s,o,r){r=r||[];const a=Math.cos(s),l=Math.sin(s),h=o[0],d=o[1];let c=0;for(let s=e;s<i;s+=n){const e=t[s]-h,i=t[s+1]-d;r[c++]=h+e*a-i*l,r[c++]=d+e*l+i*a;for(let e=s+2;e<s+n;++e)r[c++]=t[e]}return r&&r.length!=c&&(r.length=c),r}
1Ue(Te),Ue(Ee),oi=Te,ri=function(t,e,i){const n=t.length;i=i>1?i:2,void 0===e&&(e=i>2?t.slice():new Array(n));for(let s=0;s<n;s+=i){e[s]=ve*t[s]/180;let i=ye*Math.log(Math.tan(Math.PI*(+t[s+1]+90)/360));i>Ce?i=Ce:i<-Ce&&(i=-Ce),e[s+1]=i}return e},ai=function(t,e,i){const n=t.length;i=i>1?i:2,void 0===e&&(e=i>2?t.slice():new Array(n));for(let s=0;s<n;s+=i)e[s]=180*t[s]/ve,e[s+1]=360*Math.atan(Math.exp(t[s+1]/ye))/Math.PI-90;return e},Ee.forEach((function(t){oi.forEach((function(e){Me(t,e,ri),Me(e,t,ai)}))}));const wi=[1,0,0,1,0,0],Ci=class extends F{constructor(){super(),this.extent_=[1/0,1/0,-1/0,-1/0],this.extentRevision_=-1,this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=0,this.simplifyTransformedInternal=function(t){let e,i,n,s=!1;return function(){const o=Array.prototype.slice.call(arguments);return s&&this===n&&u(o,i)||(s=!0,n=this,i=o,e=t.apply(this,arguments)),e}}((function(t,e,i){if(!i)return this.getSimplifiedGeometry(e);const n=this.clone();return n.applyTransform(i),n.getSimplifiedGeometry(e)}))}simplifyTransformed(t,e){return this.simplifyTransformedInternal(this.getRevision(),t,e)}clone(){return M()}closestPointXY(t,e,i,n){return M()}containsXY(t,e){const i=this.getClosestPoint([t,e]);return i[0]===t&&i[1]===e}getClosestPoint(t,e){return e=e||[NaN,NaN],this.closestPointXY(t[0],t[1],e,1/0),e}intersectsCoordinate(t){return this.containsXY(t[0],t[1])}computeExtent(t){return M()}getExtent(t){if(this.extentRevision_!=this.getRevision()){const t=this.computeExtent(this.extent_);(isNaN(t[0])||isNaN(t[1]))&&gt(t),this.extentRevision_=this.getRevision()}return function(t,e){return e?(e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e):t}(this.extent_,t)}rotate(t,e){M()}scale(t,e,i){M()}simplify(t){return this.getSimplifiedGeometry(t*t)}getSimplifiedGeometry(t){return M()}getType(){return M()}applyTransform(t){M()}intersectsExtent(t){return M()}translate(t,e){M()}transform(t,e){const i=Be(t),n="tile-pixels"==i.getUnits()?function(t,n,s){const o=i.getExtent(),r=i.getWorldExtent(),a=It(r)/It(o);return tt(wi,r[0],r[3],a,-a,0,0,0),vi(t,0,t.length,s,wi,n),He(i,e)(t,n,s)}:He(i,e);return this.applyTransform(n),this}};function Si(t){let e;return"XY"==t?e=2:"XYZ"==t||"XYM"==t?e=3:"XYZM"==t&&(e=4),e}const Ti=class extends Ci{constructor(){super(),this.layout="XY",this.stride=2,this.flatCoordinates=null}computeExtent(t){return e=this.flatCoordinates,i=this.flatCoordinates.length,n=this.stride,_t(gt(t),e,0,i,n);var e,i,n}getCoordinates(){return M()}getFirstCoordinate(){return this.flatCoordinates.slice(0,this.stride)}getFlatCoordinates(){return this.flatCoordinates}getLastCoordinate(){return this.flatCoordinates.slice(this.flatCoordinates.length-this.stride)}getLayout(){return this.layout}getSimplifiedGeometry(t){if(this.simplifiedGeometryRevision!==this.getRevision()&&(this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=this.getRevision()),t<0||0!==this.simplifiedGeometryMaxMinSquaredTolerance&&t<=this.simplifiedGeometryMaxMinSquaredTolerance)return this;const e=this.getSimplifiedGeometryInternal(t);return e.getFlatCoordinates().length<this.flatCoordinates.length?e:(this.simplifiedGeometryMaxMinSquaredTolerance=t,this)}getSimplifiedGeometryInternal(t){return this}getStride(){return this.stride}setFlatCoordinates(t,e){this.stride=Si(t),this.layout=t,this.flatCoordinates=e}setCoordinates(t,e){M()}setLayout(t,e,i){let n;if(t)n=Si(t);else{for(let t=0;t<i;++t){if(0===e.length)return this.layout="XY",void(this.stride=2);e=e[0]}n=e.length,t=function(t){let e;return 2==t?e="XY":3==t?e="XYZ":4==t&&(e="XYZM"),e}(n)}this.layout=t,this.stride=n}applyTransform(t){this.flatCoordinates&&(t(this.flatCoordinates,this.flatCoordinates,this.stride),this.changed())}rotate(t,e){const i=this.getFlatCoordinates();if(i){const n=this.getStride();xi(i,0,i.length,n,t,e,i),this.changed()}}scale(t,e,i){void 0===e&&(e=t),i||(i=St(this.getExtent()));const n=this.getFlatCoordinates();if(n){const s=this.getStride();!function(t,e,i,n,s,o,r,a){a=a||[];const l=r[0],h=r[1];let d=0;for(let e=0;e<i;e+=n){const i=t[e]-l,r=t[e+1]-h;a[d++]=l+s*i,a[d++]=h+o*r;for(let i=e+2;i<e+n;++i)a[d++]=t[i]}a&&a.length!=d&&(a.length=d)}(n,0,n.length,s,t,e,i,n),this.changed()}}translate(t,e){const i=this.getFlatCoordinates();if(i){const n=this.getStride();
vendor: 2,166 bytes, line 1
1!function(t,e,i,n,s,o,r){r=r||[];let a=0;for(let e=0;e<i;e+=n){r[a++]=t[e]+s,r[a++]=t[e+1]+o;for(let i=e+2;i<e+n;++i)r[a++]=t[i]}r&&r.length!=a&&(r.length=a)}(i,0,i.length,n,t,e,i),this.changed()}}};function bi(t,e,i,n,s,o,r){const a=t[e],l=t[e+1],h=t[i]-a,d=t[i+1]-l;let c;if(0===h&&0===d)c=e;else{const u=((s-a)*h+(o-l)*d)/(h*h+d*d);if(u>1)c=i;else{if(u>0){for(let s=0;s<n;++s)r[s]=jt(t[e+s],t[i+s],u);return void(r.length=n)}c=e}}for(let e=0;e<n;++e)r[e]=t[c+e];r.length=n}function ki(t,e,i,n,s){let o=t[e],r=t[e+1];for(e+=n;e<i;e+=n){const i=t[e],n=t[e+1],a=Zt(o,r,i,n);a>s&&(s=a),o=i,r=n}return s}function Ii(t,e,i,n,s,o,r,a,l,h,d){if(e==i)return h;let c,u;if(0===s){if(u=Zt(r,a,t[e],t[e+1]),u<h){for(c=0;c<n;++c)l[c]=t[e+c];return l.length=n,u}return h}d=d||[NaN,NaN];let p=e+n;for(;p<i;)if(bi(t,p-n,p,n,r,a,d),u=Zt(r,a,d[0],d[1]),u<h){for(h=u,c=0;c<n;++c)l[c]=d[c];l.length=n,p+=n}else p+=n*Math.max((Math.sqrt(u)-Math.sqrt(h))/s|0,1);if(o&&(bi(t,i-n,e,n,r,a,d),u=Zt(r,a,d[0],d[1]),u<h)){for(h=u,c=0;c<n;++c)l[c]=d[c];l.length=n}return h}function Ei(t,e,i,n){for(let s=0,o=i.length;s<o;++s){const o=i[s];for(let i=0;i<n;++i)t[e++]=o[i]}return e}function Ri(t,e){return e*Math.round(t/e)}function Pi(t,e,i,n,s,o,r){if(e==i)return r;let a,l,h=Ri(t[e],s),d=Ri(t[e+1],s);e+=n,o[r++]=h,o[r++]=d;do{if(a=Ri(t[e],s),l=Ri(t[e+1],s),(e+=n)==i)return o[r++]=a,o[r++]=l,r}while(a==h&&l==d);for(;e<i;){const i=Ri(t[e],s),c=Ri(t[e+1],s);if(e+=n,i==a&&c==l)continue;const u=a-h,p=l-d,g=i-h,f=c-d;u*f==p*g&&(u<0&&g<u||u==g||u>0&&g>u)&&(p<0&&f<p||p==f||p>0&&f>p)?(a=i,l=c):(o[r++]=a,o[r++]=l,h=a,d=l,a=i,l=c)}return o[r++]=a,o[r++]=l,r}function Mi(t,e,i,n,s){s=void 0!==s?s:[];let o=0;for(let r=e;r<i;r+=n)s[o++]=t.slice(r,r+n);return s.length=o,s}function Ai(t,e,i,n,s){s=void 0!==s?s:[];let o=0;for(let r=0,a=i.length;r<a;++r){const a=i[r];s[o++]=Mi(t,e,a,n,s[o]),e=a}return s.length=o,s}function Li(t,e,i,n,s){s=void 0!==s?s:[];let o=0;for(let r=0,a=i.length;r<a;++r){const a=i[r];s[o++]=1===a.length&&a[0]===e?[]:Ai(t,e,a,n,s[o]),e=a[a.length-1]}return s.length=o,s}function Oi(t,e,i,n){let s=0,o=t[i-n],r=t[i-n+1];for(;e<i;e+=n){const i=t[e],n=t[e+1];s+=r*i-o*n,o=i,r=n}
1return s/2}class Fi extends Ti{constructor(t,e){super(),this.maxDelta_=-1,this.maxDeltaRevision_=-1,void 0===e||Array.isArray(t[0])?this.setCoordinates(t,e):this.setFlatCoordinates(e,t)}clone(){return new Fi(this.flatCoordinates.slice(),this.layout)}closestPointXY(t,e,i,n){return n<lt(this.getExtent(),t,e)?n:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(ki(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),Ii(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,this.maxDelta_,!0,t,e,i,n))}getArea(){return Oi(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getCoordinates(){return Mi(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getSimplifiedGeometryInternal(t){const e=[];return e.length=function(t,e,i,n,s,o,r){const a=(i-e)/n;if(a<3){for(;e<i;e+=n)o[r++]=t[e],o[r++]=t[e+1];return r}const l=new Array(a);l[0]=1,l[a-1]=1;const h=[e,i-n];let d=0;for(;h.length>0;){const i=h.pop(),o=h.pop();let r=0;const a=t[o],c=t[o+1],u=t[i],p=t[i+1];for(let e=o+n;e<i;e+=n){const i=Dt(t[e],t[e+1],a,c,u,p);i>r&&(d=e,r=i)}r>s&&(l[(d-e)/n]=1,o+n<d&&h.push(o,d),d+n<i&&h.push(d,i))}for(let i=0;i<a;++i)l[i]&&(o[r++]=t[e+i*n],o[r++]=t[e+i*n+1]);return r}(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,e,0),new Fi(e,"XY")}getType(){return"LinearRing"}intersectsExtent(t){return!1}setCoordinates(t,e){this.setLayout(e,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=Ei(this.flatCoordinates,0,t,this.stride),this.changed()}}const Di=Fi;class Zi extends Ti{constructor(t,e){super(),this.setCoordinates(t,e)}clone(){const t=new Zi(this.flatCoordinates.slice(),this.layout);return t.applyProperties(this),t}closestPointXY(t,e,i,n){const s=this.flatCoordinates,o=Zt(t,e,s[0],s[1]);if(o<n){const t=this.stride;for(let e=0;e<t;++e)i[e]=s[e];return i.length=t,o}return n}getCoordinates(){return this.flatCoordinates?this.flatCoordinates.slice():[]}computeExtent(t){return function(t,e){const i=t[0],n=t[1];return pt(i,n,i,n,e)}(this.flatCoordinates,t)}getType(){return"Point"}intersectsExtent(t){return ct(t,this.flatCoordinates[0],this.flatCoordinates[1])}setCoordinates(t,e){this.setLayout(e,t,0),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=function(t,e,i,n){for(let n=0,s=i.length;n<s;++n)t[e++]=i[n];return e}(this.flatCoordinates,0,t,this.stride),this.changed()}}const Ni=Zi;function zi(t,e,i,n,s){return!vt(s,(function(s){return!ji(t,e,i,n,s[0],s[1])}))}function ji(t,e,i,n,s,o){let r=0,a=t[i-n],l=t[i-n+1];for(;e<i;e+=n){const i=t[e],n=t[e+1];l<=o?n>o&&(i-a)*(o-l)-(s-a)*(n-l)>0&&r++:n<=o&&(i-a)*(o-l)-(s-a)*(n-l)<0&&r--,a=i,l=n}return 0!==r}function $i(t,e,i,n,s,o){if(0===i.length)return!1;if(!ji(t,e,i[0],n,s,o))return!1;for(let e=1,r=i.length;e<r;++e)if(ji(t,i[e-1],i[e],n,s,o))return!1;return!0}function Wi(t,e,i,n,s){const o=_t([1/0,1/0,-1/0,-1/0],t,e,i,n);return!!At(s,o)&&(!!dt(s,o)||o[0]>=s[0]&&o[2]<=s[2]||o[1]>=s[1]&&o[3]<=s[3]||function(t,e,i,n,o){let r;for(e+=n;e<i;e+=n)if(a=t.slice(e-n,e),l=t.slice(e,e+n),r=function(t,e,i){let n=!1;const s=ut(t,e),o=ut(t,i);if(s===st.INTERSECTING||o===st.INTERSECTING)n=!0;else{const r=t[0],a=t[1],l=t[2],h=t[3],d=e[0],c=e[1],u=i[0],p=i[1],g=(p-c)/(u-d);let f,m;o&st.ABOVE&&!(s&st.ABOVE)&&(f=u-(p-h)/g,n=f>=r&&f<=l),n||!(o&st.RIGHT)||s&st.RIGHT||(m=p-(u-l)*g,n=m>=a&&m<=h),n||!(o&st.BELOW)||s&st.BELOW||(f=u-(p-a)/g,n=f>=r&&f<=l),n||!(o&st.LEFT)||s&st.LEFT||(m=p-(u-r)*g,n=m>=a&&m<=h)}return n}(s,a,l),r)return r;var a,l;return!1}(t,e,i,n))}function Gi(t,e,i,n,s){return!!(Wi(t,e,i,n,s)||ji(t,e,i,n,s[0],s[1])||ji(t,e,i,n,s[0],s[3])||ji(t,e,i,n,s[2],s[1])||ji(t,e,i,n,s[2],s[3]))}function Bi(t,e,i,n){for(;e<i-n;){for(let s=0;s<n;++s){const o=t[e+s];t[e+s]=t[i-n+s],t[i-n+s]=o}e+=n,i-=n}}function Vi(t,e,i,n){let s=0,o=t[i-n],r=t[i-n+1];for(;e<i;e+=n){const i=t[e],n=t[e+1];s+=(i-o)*(n+r),o=i,r=n}
vendor: 4,142 bytes, line 1
1return 0===s?void 0:s>0}function Ui(t,e,i,n,s){s=void 0!==s&&s;for(let o=0,r=i.length;o<r;++o){const r=i[o],a=Vi(t,e,r,n);(0===o?s&&a||!s&&!a:s&&!a||!s&&a)&&Bi(t,e,r,n),e=r}return e}class Xi extends Ti{constructor(t,e,i){super(),this.ends_=[],this.flatInteriorPointRevision_=-1,this.flatInteriorPoint_=null,this.maxDelta_=-1,this.maxDeltaRevision_=-1,this.orientedRevision_=-1,this.orientedFlatCoordinates_=null,void 0!==e&&i?(this.setFlatCoordinates(e,t),this.ends_=i):this.setCoordinates(t,e)}appendLinearRing(t){this.flatCoordinates?c(this.flatCoordinates,t.getFlatCoordinates()):this.flatCoordinates=t.getFlatCoordinates().slice(),this.ends_.push(this.flatCoordinates.length),this.changed()}clone(){const t=new Xi(this.flatCoordinates.slice(),this.layout,this.ends_.slice());return t.applyProperties(this),t}closestPointXY(t,e,i,n){return n<lt(this.getExtent(),t,e)?n:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(function(t,e,i,n,s){for(let o=0,r=i.length;o<r;++o){const r=i[o];s=ki(t,e,r,n,s),e=r}return s}(this.flatCoordinates,0,this.ends_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),function(t,e,i,n,s,o,r,a,l,h,d){d=d||[NaN,NaN];for(let c=0,u=i.length;c<u;++c){const u=i[c];h=Ii(t,e,u,n,s,o,r,a,l,h,d),e=u}return h}(this.flatCoordinates,0,this.ends_,this.stride,this.maxDelta_,!0,t,e,i,n))}containsXY(t,e){return $i(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t,e)}getArea(){return function(t,e,i,n){let s=0;for(let o=0,r=i.length;o<r;++o){const r=i[o];s+=Oi(t,e,r,n),e=r}return s}(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride)}getCoordinates(t){let e;return void 0!==t?(e=this.getOrientedFlatCoordinates().slice(),Ui(e,0,this.ends_,this.stride,t)):e=this.flatCoordinates,Ai(e,0,this.ends_,this.stride)}getEnds(){return this.ends_}getFlatInteriorPoint(){if(this.flatInteriorPointRevision_!=this.getRevision()){const t=St(this.getExtent());this.flatInteriorPoint_=function(t,e,i,n,s,o,r){let a,h,d,c,u,p,g;const f=s[o+1],m=[];for(let s=0,o=i.length;s<o;++s){const o=i[s];for(c=t[o-n],p=t[o-n+1],a=e;a<o;a+=n)u=t[a],g=t[a+1],(f<=p&&g<=f||p<=f&&f<=g)&&(d=(f-p)/(g-p)*(u-c)+c,m.push(d)),c=u,p=g}let _=NaN,y=-1/0;for(m.sort(l),c=m[0],a=1,h=m.length;a<h;++a){u=m[a];const s=Math.abs(u-c);s>y&&(d=(c+u)/2,$i(t,e,i,n,d,f)&&(_=d,y=s)),c=u}return isNaN(_)&&(_=s[o]),r?(r.push(_,f,y),r):[_,f,y]}(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t,0),this.flatInteriorPointRevision_=this.getRevision()}return this.flatInteriorPoint_}getInteriorPoint(){return new Ni(this.getFlatInteriorPoint(),"XYM")}getLinearRingCount(){return this.ends_.length}getLinearRing(t){return t<0||this.ends_.length<=t?null:new Di(this.flatCoordinates.slice(0===t?0:this.ends_[t-1],this.ends_[t]),this.layout)}getLinearRings(){const t=this.layout,e=this.flatCoordinates,i=this.ends_,n=[];let s=0;for(let o=0,r=i.length;o<r;++o){const r=i[o],a=new Di(e.slice(s,r),t);n.push(a),s=r}return n}getOrientedFlatCoordinates(){if(this.orientedRevision_!=this.getRevision()){const t=this.flatCoordinates;!function(t,e,i,n,s){s=void 0!==s&&s;for(let o=0,r=i.length;o<r;++o){const r=i[o],a=Vi(t,e,r,n);if(0===o){if(s&&a||!s&&!a)return!1}else if(s&&!a||!s&&a)return!1;e=r}return!0}(t,0,this.ends_,this.stride)?(this.orientedFlatCoordinates_=t.slice(),this.orientedFlatCoordinates_.length=Ui(this.orientedFlatCoordinates_,0,this.ends_,this.stride)):this.orientedFlatCoordinates_=t,this.orientedRevision_=this.getRevision()}return this.orientedFlatCoordinates_}getSimplifiedGeometryInternal(t){const e=[],i=[];return e.length=function(t,e,i,n,s,o,r,a){for(let l=0,h=i.length;l<h;++l){const h=i[l];r=Pi(t,e,h,n,s,o,r),a.push(r),e=h}return r}(this.flatCoordinates,0,this.ends_,this.stride,Math.sqrt(t),e,0,i),new Xi(e,"XY",i)}getType(){return"Polygon"}intersectsExtent(t){return function(t,e,i,n,s){if(!Gi(t,e,i[0],n,s))return!1;if(1===i.length)return!0;for(let e=1,o=i.length;e<o;++e)if(zi(t,i[e-1],i[e],n,s)&&!Wi(t,i[e-1],i[e],n,s))return!1;return!0}(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t)}setCoordinates(t,e){this.setLayout(e,t,2),this.flatCoordinates||(this.flatCoordinates=[]);
1const i=function(t,e,i,n,s){s=s||[];let o=0;for(let r=0,a=i.length;r<a;++r){const a=Ei(t,e,i[r],n);s[o++]=a,e=a}return s.length=o,s}(this.flatCoordinates,0,t,this.stride,this.ends_);this.flatCoordinates.length=0===i.length?0:i[i.length-1],this.changed()}}const Ki=Xi;function Yi(t){if(Lt(t))throw new Error("Cannot create polygon from empty extent");const e=t[0],i=t[1],n=t[2],s=t[3],o=[e,i,e,s,n,s,n,i,e,i];return new Xi(o,"XY",[o.length])}function Hi(t,e){setTimeout((function(){t(e)}),0)}function qi(t){return!(t.sourceCenter&&t.targetCenter&&!Ae(t.sourceCenter,t.targetCenter))&&t.sourceResolution===t.targetResolution&&t.sourceRotation===t.targetRotation}function Ji(t,e,i,n,s){const o=Math.cos(-s);let r=Math.sin(-s),a=t[0]*o-t[1]*r,l=t[1]*o+t[0]*r;return a+=(e[0]/2-i[0])*n,l+=(i[1]-e[1]/2)*n,r=-r,[a*o-l*r,l*o+a*r]}const Qi=class extends F{constructor(t){super(),this.on,this.once,this.un,t=Object.assign({},t),this.hints_=[0,0],this.animations_=[],this.updateAnimationKey_,this.projection_=Xe(t.projection,"EPSG:3857"),this.viewportSize_=[100,100],this.targetCenter_=null,this.targetResolution_,this.targetRotation_,this.nextCenter_=null,this.nextResolution_,this.nextRotation_,this.cancelAnchor_=void 0,t.projection&&function(t){je=!(void 0===t||t)}(),t.center&&(t.center=ei(t.center,this.projection_)),t.extent&&(t.extent=ni(t.extent,this.projection_)),this.applyOptions_(t)}applyOptions_(t){const e=Object.assign({},t);for(const t in pe)delete e[t];this.setProperties(e,!0);const i=function(t){let e,i,n;let s=void 0!==t.minZoom?t.minZoom:0,o=void 0!==t.maxZoom?t.maxZoom:28;const r=void 0!==t.zoomFactor?t.zoomFactor:2,a=void 0!==t.multiWorld&&t.multiWorld,l=void 0===t.smoothResolutionConstraint||t.smoothResolutionConstraint,d=void 0!==t.showFullExtent&&t.showFullExtent,c=Xe(t.projection,"EPSG:3857"),u=c.getExtent();let p=t.constrainOnlyCenter,g=t.extent;if(a||g||!c.isGlobal()||(p=!1,g=u),void 0!==t.resolutions){const r=t.resolutions;i=r[s],n=void 0!==r[o]?r[o]:r[r.length-1],e=t.constrainResolution?function(t,e,i,n){return e=void 0===e||e,function(s,o,r,a){if(void 0!==s){const l=t[0],d=t[t.length-1],c=i?di(l,i,r,n):l;if(a)return e?ci(s,c,d):Ft(s,d,c);const u=Math.min(c,s),p=Math.floor(h(t,u,o));return t[p]>c&&p<t.length-1?t[p+1]:t[p]}}}(r,l,!p&&g,d):ui(i,n,l,!p&&g,d)}else{const a=(u?Math.max(Mt(u),It(u)):360*me.degrees/c.getMetersPerUnit())/fe/Math.pow(2,0),h=a/Math.pow(2,28);i=t.maxResolution,void 0!==i?s=0:i=a/Math.pow(r,s),n=t.minResolution,void 0===n&&(n=void 0!==t.maxZoom?void 0!==t.maxResolution?i/Math.pow(r,o):a/Math.pow(r,o):h),o=s+Math.floor(Math.log(i/n)/Math.log(r)),n=i/Math.pow(r,o-s),e=t.constrainResolution?function(t,e,i,n,s,o){return n=void 0===n||n,i=void 0!==i?i:0,function(r,a,l,h){if(void 0!==r){const d=s?di(e,s,l,o):e;if(h)return n?ci(r,d,i):Ft(r,i,d);const c=1e-9,u=Math.ceil(Math.log(e/d)/Math.log(t)-c),p=-a*(.5-c)+.5,g=Math.min(d,r),f=Math.floor(Math.log(e/g)/Math.log(t)+p),m=Math.max(u,f);return Ft(e/Math.pow(t,m),i,d)}}}(r,i,n,l,!p&&g,d):ui(i,n,l,!p&&g,d)}return{constraint:e,maxResolution:i,minResolution:n,minZoom:s,zoomFactor:r}}(t);this.maxResolution_=i.maxResolution,this.minResolution_=i.minResolution,this.zoomFactor_=i.zoomFactor,this.resolutions_=t.resolutions,this.padding_=t.padding,this.minZoom_=i.minZoom;const n=function(t){if(void 0!==t.extent){const e=void 0===t.smoothExtentConstraint||t.smoothExtentConstraint;return li(t.extent,t.constrainOnlyCenter,e)}const e=Xe(t.projection,"EPSG:3857");if(!0!==t.multiWorld&&e.isGlobal()){const t=e.getExtent().slice();return t[0]=-1/0,t[2]=1/0,li(t,!1,!1)}return hi}(t),s=i.constraint,o=function(t){if(void 0===t.enableRotation||t.enableRotation){const i=t.constrainRotation;return void 0===i||!0===i?(e=e||Nt(5),function(t,i){return i?t:void 0!==t?Math.abs(t)<=e?0:t:void 0}):!1===i?gi:"number"==typeof i?function(t){const e=2*Math.PI/t;return function(t,i){return i?t:void 0!==t?t=Math.floor(t/e+.5)*e:void 0}}(i):gi}var e;return pi}(t);this.constraints_={center:n,resolution:s,rotation:o},this.setRotation(void 0!==t.rotation?t.rotation:0),this.setCenterInternal(void 0!==t.center?t.center:null),void 0!==t.resolution?this.setResolution(t.resolution):void 0!==t.zoom&&this.setZoom(t.zoom)}get padding(){return this.padding_}set padding(t){let e=this.padding_;this.padding_=t;const i=this.getCenterInternal();if(i){const n=t||[0,0,0,0];e=e||[0,0,0,0];const s=this.getResolution(),o=s/2*(n[3]-e[3]+e[1]-n[1]),r=s/2*(n[0]-e[0]+e[2]-n[2]);this.setCenterInternal([i[0]+o,i[1]-r])}}getUpdatedOptions_(t){const e=this.getProperties();return void 0!==e.resolution?e.resolution=this.getResolution():e.zoom=this.getZoom(),e.center=this.getCenterInternal(),e.rotation=this.getRotation(),Object.assign({},e,t)}animate(t){this.isDef()&&!this.getAnimating()&&this.resolveConstraints(0);const e=new Array(arguments.length);for(let t=0;t<e.length;++t){let i=arguments[t];i.center&&(i=Object.assign({},i),i.center=ei(i.center,this.getProjection())),i.anchor&&(i=Object.assign({},i),i.anchor=ei(i.anchor,this.getProjection())),e[t]=i}this.animateInternal.apply(this,e)}animateInternal(t){let e,i=arguments.length;i>1&&"function"==typeof arguments[i-1]&&(e=arguments[i-1],--i);let n=0;for(;n<i&&!this.isDef();++n){const t=arguments[n];t.center&&this.setCenterInternal(t.center),void 0!==t.zoom?this.setZoom(t.zoom):t.resolution&&this.setResolution(t.resolution),void 0!==t.rotation&&this.setRotation(t.rotation)}if(n===i)return void(e&&Hi(e,!0));let s=Date.now(),o=this.targetCenter_.slice(),r=this.targetResolution_,a=this.targetRotation_;const l=[];for(;n<i;++n){const t=arguments[n],i={start:s,complete:!1,anchor:t.anchor,duration:void 0!==t.duration?t.duration:1e3,easing:t.easing||_i,callback:e};if(t.center&&(i.sourceCenter=o,i.targetCenter=t.center.slice(),o=i.targetCenter),void 0!==t.zoom?(i.sourceResolution=r,i.targetResolution=this.getResolutionForZoom(t.zoom),r=i.targetResolution):t.resolution&&(i.sourceResolution=r,i.targetResolution=t.resolution,r=i.targetResolution),void 0!==t.rotation){i.sourceRotation=a;const e=zt(t.rotation-a+Math.PI,2*Math.PI)-Math.PI;i.targetRotation=a+e,a=i.targetRotation}qi(i)?i.complete=!0:s+=i.duration,l.push(i)}this.animations_.push(l),this.setHint(0,1),this.updateAnimations_()}getAnimating(){return this.hints_[0]>0}getInteracting(){return this.hints_[1]>0}cancelAnimations(){let t;this.setHint(0,-this.hints_[0]);for(let e=0,i=this.animations_.length;e<i;++e){const i=this.animations_[e];
vendor: 10,622 bytes, line 1
1if(i[0].callback&&Hi(i[0].callback,!1),!t)for(let e=0,n=i.length;e<n;++e){const n=i[e];if(!n.complete){t=n.anchor;break}}}this.animations_.length=0,this.cancelAnchor_=t,this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN}updateAnimations_(){if(void 0!==this.updateAnimationKey_&&(cancelAnimationFrame(this.updateAnimationKey_),this.updateAnimationKey_=void 0),!this.getAnimating())return;const t=Date.now();let e=!1;for(let i=this.animations_.length-1;i>=0;--i){const n=this.animations_[i];let s=!0;for(let i=0,o=n.length;i<o;++i){const o=n[i];if(o.complete)continue;const r=t-o.start;let a=o.duration>0?r/o.duration:1;a>=1?(o.complete=!0,a=1):s=!1;const l=o.easing(a);if(o.sourceCenter){const t=o.sourceCenter[0],e=o.sourceCenter[1],i=o.targetCenter[0],n=o.targetCenter[1];this.nextCenter_=o.targetCenter;const s=t+l*(i-t),r=e+l*(n-e);this.targetCenter_=[s,r]}if(o.sourceResolution&&o.targetResolution){const t=1===l?o.targetResolution:o.sourceResolution+l*(o.targetResolution-o.sourceResolution);if(o.anchor){const e=this.getViewportSize_(this.getRotation()),i=this.constraints_.resolution(t,0,e,!0);this.targetCenter_=this.calculateCenterZoom(i,o.anchor)}this.nextResolution_=o.targetResolution,this.targetResolution_=t,this.applyTargetState_(!0)}if(void 0!==o.sourceRotation&&void 0!==o.targetRotation){const t=1===l?zt(o.targetRotation+Math.PI,2*Math.PI)-Math.PI:o.sourceRotation+l*(o.targetRotation-o.sourceRotation);if(o.anchor){const e=this.constraints_.rotation(t,!0);this.targetCenter_=this.calculateCenterRotate(e,o.anchor)}this.nextRotation_=o.targetRotation,this.targetRotation_=t}if(this.applyTargetState_(!0),e=!0,!o.complete)break}if(s){this.animations_[i]=null,this.setHint(0,-1),this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN;const t=n[0].callback;t&&Hi(t,!0)}}this.animations_=this.animations_.filter(Boolean),e&&void 0===this.updateAnimationKey_&&(this.updateAnimationKey_=requestAnimationFrame(this.updateAnimations_.bind(this)))}calculateCenterRotate(t,e){let i;const n=this.getCenterInternal();var s,o;return void 0!==n&&(i=[n[0]-e[0],n[1]-e[1]],Le(i,t-this.getRotation()),o=e,(s=i)[0]+=+o[0],s[1]+=+o[1]),i}calculateCenterZoom(t,e){let i;const n=this.getCenterInternal(),s=this.getResolution();return void 0!==n&&void 0!==s&&(i=[e[0]-t*(e[0]-n[0])/s,e[1]-t*(e[1]-n[1])/s]),i}getViewportSize_(t){const e=this.viewportSize_;if(t){const i=e[0],n=e[1];return[Math.abs(i*Math.cos(t))+Math.abs(n*Math.sin(t)),Math.abs(i*Math.sin(t))+Math.abs(n*Math.cos(t))]}return e}setViewportSize(t){this.viewportSize_=Array.isArray(t)?t.slice():[100,100],this.getAnimating()||this.resolveConstraints(0)}getCenter(){const t=this.getCenterInternal();return t?ti(t,this.getProjection()):t}getCenterInternal(){return this.get(pe.CENTER)}getConstraints(){return this.constraints_}getConstrainResolution(){return this.get("constrainResolution")}getHints(t){return void 0!==t?(t[0]=this.hints_[0],t[1]=this.hints_[1],t):this.hints_.slice()}calculateExtent(t){return ii(this.calculateExtentInternal(t),this.getProjection())}calculateExtentInternal(t){t=t||this.getViewportSizeMinusPadding_();const e=this.getCenterInternal();J(e,1);const i=this.getResolution();J(void 0!==i,2);const n=this.getRotation();return J(void 0!==n,3),bt(e,i,n,t)}getMaxResolution(){return this.maxResolution_}getMinResolution(){return this.minResolution_}getMaxZoom(){return this.getZoomForResolution(this.minResolution_)}setMaxZoom(t){this.applyOptions_(this.getUpdatedOptions_({maxZoom:t}))}getMinZoom(){return this.getZoomForResolution(this.maxResolution_)}setMinZoom(t){this.applyOptions_(this.getUpdatedOptions_({minZoom:t}))}setConstrainResolution(t){this.applyOptions_(this.getUpdatedOptions_({constrainResolution:t}))}getProjection(){return this.projection_}getResolution(){return this.get(pe.RESOLUTION)}getResolutions(){return this.resolutions_}getResolutionForExtent(t,e){return this.getResolutionForExtentInternal(ni(t,this.getProjection()),e)}getResolutionForExtentInternal(t,e){e=e||this.getViewportSizeMinusPadding_();const i=Mt(t)/e[0],n=It(t)/e[1];return Math.max(i,n)}getResolutionForValueFunction(t){t=t||2;const e=this.getConstrainedResolution(this.maxResolution_),i=this.minResolution_,n=Math.log(e/i)/Math.log(t);return function(i){return e/Math.pow(t,i*n)}}getRotation(){return this.get(pe.ROTATION)}getValueForResolutionFunction(t){const e=Math.log(t||2),i=this.getConstrainedResolution(this.maxResolution_),n=this.minResolution_,s=Math.log(i/n)/e;return function(t){return Math.log(i/t)/e/s}}getViewportSizeMinusPadding_(t){let e=this.getViewportSize_(t);const i=this.padding_;return i&&(e=[e[0]-i[1]-i[3],e[1]-i[0]-i[2]]),e}getState(){const t=this.getProjection(),e=this.getResolution(),i=this.getRotation();let n=this.getCenterInternal();const s=this.padding_;if(s){const t=this.getViewportSizeMinusPadding_();n=Ji(n,this.getViewportSize_(),[t[0]/2+s[3],t[1]/2+s[0]],e,i)}return{center:n.slice(0),projection:void 0!==t?t:null,resolution:e,nextCenter:this.nextCenter_,nextResolution:this.nextResolution_,nextRotation:this.nextRotation_,rotation:i,zoom:this.getZoom()}}getViewStateAndExtent(){return{viewState:this.getState(),extent:this.calculateExtent()}}getZoom(){let t;const e=this.getResolution();return void 0!==e&&(t=this.getZoomForResolution(e)),t}getZoomForResolution(t){let e,i,n=this.minZoom_||0;if(this.resolutions_){const s=h(this.resolutions_,t,1);n=s,e=this.resolutions_[s],i=s==this.resolutions_.length-1?2:e/this.resolutions_[s+1]}else e=this.maxResolution_,i=this.zoomFactor_;return n+Math.log(e/t)/Math.log(i)}getResolutionForZoom(t){if(this.resolutions_){if(this.resolutions_.length<=1)return 0;const e=Ft(Math.floor(t),0,this.resolutions_.length-2),i=this.resolutions_[e]/this.resolutions_[e+1];return this.resolutions_[e]/Math.pow(i,Ft(t-e,0,1))}return this.maxResolution_/Math.pow(this.zoomFactor_,t-this.minZoom_)}fit(t,e){let i;if(J(Array.isArray(t)||"function"==typeof t.getSimplifiedGeometry,24),Array.isArray(t))J(!Lt(t),25),i=Yi(ni(t,this.getProjection()));else if("Circle"===t.getType()){const e=ni(t.getExtent(),this.getProjection());i=Yi(e),i.rotate(this.getRotation(),St(e))}else{const e=Qe();i=e?t.clone().transform(e,this.getProjection()):t}this.fitInternal(i,e)}rotatedExtentForGeometry(t){const e=this.getRotation(),i=Math.cos(e),n=Math.sin(-e),s=t.getFlatCoordinates(),o=t.getStride();let r=1/0,a=1/0,l=-1/0,h=-1/0;for(let t=0,e=s.length;t<e;t+=o){const e=s[t]*i-s[t+1]*n,o=s[t]*n+s[t+1]*i;r=Math.min(r,e),a=Math.min(a,o),l=Math.max(l,e),h=Math.max(h,o)}return[r,a,l,h]}fitInternal(t,e){let i=(e=e||{}).size;i||(i=this.getViewportSizeMinusPadding_());const n=void 0!==e.padding?e.padding:[0,0,0,0],s=void 0!==e.nearest&&e.nearest;let o;o=void 0!==e.minResolution?e.minResolution:void 0!==e.maxZoom?this.getResolutionForZoom(e.maxZoom):0;const r=this.rotatedExtentForGeometry(t);let a=this.getResolutionForExtentInternal(r,[i[0]-n[1]-n[3],i[1]-n[0]-n[2]]);a=isNaN(a)?o:Math.max(a,o),a=this.getConstrainedResolution(a,s?0:1);const l=this.getRotation(),h=Math.sin(l),d=Math.cos(l),c=St(r);c[0]+=(n[1]-n[3])/2*a,c[1]+=(n[0]-n[2])/2*a;const u=c[0]*d-c[1]*h,p=c[1]*d+c[0]*h,g=this.getConstrainedCenter([u,p],a),m=e.callback?e.callback:f;void 0!==e.duration?this.animateInternal({resolution:a,center:g,duration:e.duration,easing:e.easing},m):(this.targetResolution_=a,this.targetCenter_=g,this.applyTargetState_(!1,!0),Hi(m,!0))}centerOn(t,e,i){this.centerOnInternal(ei(t,this.getProjection()),e,i)}centerOnInternal(t,e,i){this.setCenterInternal(Ji(t,e,i,this.getResolution(),this.getRotation()))}calculateCenterShift(t,e,i,n){let s;const o=this.padding_;if(o&&t){const r=this.getViewportSizeMinusPadding_(-i),a=Ji(t,n,[r[0]/2+o[3],r[1]/2+o[0]],e,i);s=[t[0]-a[0],t[1]-a[1]]}return s}isDef(){return!!this.getCenterInternal()&&void 0!==this.getResolution()}adjustCenter(t){const e=ti(this.targetCenter_,this.getProjection());this.setCenter([e[0]+t[0],e[1]+t[1]])}adjustCenterInternal(t){const e=this.targetCenter_;this.setCenterInternal([e[0]+t[0],e[1]+t[1]])}adjustResolution(t,e){e=e&&ei(e,this.getProjection()),this.adjustResolutionInternal(t,e)}adjustResolutionInternal(t,e){const i=this.getAnimating()||this.getInteracting(),n=this.getViewportSize_(this.getRotation()),s=this.constraints_.resolution(this.targetResolution_*t,0,n,i);e&&(this.targetCenter_=this.calculateCenterZoom(s,e)),this.targetResolution_*=t,this.applyTargetState_()}adjustZoom(t,e){this.adjustResolution(Math.pow(this.zoomFactor_,-t),e)}adjustRotation(t,e){e&&(e=ei(e,this.getProjection())),this.adjustRotationInternal(t,e)}adjustRotationInternal(t,e){const i=this.getAnimating()||this.getInteracting(),n=this.constraints_.rotation(this.targetRotation_+t,i);e&&(this.targetCenter_=this.calculateCenterRotate(n,e)),this.targetRotation_+=t,this.applyTargetState_()}setCenter(t){this.setCenterInternal(t?ei(t,this.getProjection()):t)}setCenterInternal(t){this.targetCenter_=t,this.applyTargetState_()}setHint(t,e){return this.hints_[t]+=e,this.changed(),this.hints_[t]}setResolution(t){this.targetResolution_=t,this.applyTargetState_()}setRotation(t){this.targetRotation_=t,this.applyTargetState_()}setZoom(t){this.setResolution(this.getResolutionForZoom(t))}applyTargetState_(t,e){const i=this.getAnimating()||this.getInteracting()||e,n=this.constraints_.rotation(this.targetRotation_,i),s=this.getViewportSize_(n),o=this.constraints_.resolution(this.targetResolution_,0,s,i),r=this.constraints_.center(this.targetCenter_,o,s,i,this.calculateCenterShift(this.targetCenter_,o,n,s));this.get(pe.ROTATION)!==n&&this.set(pe.ROTATION,n),this.get(pe.RESOLUTION)!==o&&(this.set(pe.RESOLUTION,o),this.set("zoom",this.getZoom(),!0)),r&&this.get(pe.CENTER)&&Ae(this.get(pe.CENTER),r)||this.set(pe.CENTER,r),this.getAnimating()&&!t&&this.cancelAnimations(),this.cancelAnchor_=void 0}resolveConstraints(t,e,i){t=void 0!==t?t:200;const n=e||0,s=this.constraints_.rotation(this.targetRotation_),o=this.getViewportSize_(s),r=this.constraints_.resolution(this.targetResolution_,n,o),a=this.constraints_.center(this.targetCenter_,r,o,!1,this.calculateCenterShift(this.targetCenter_,r,s,o));if(0===t&&!this.cancelAnchor_)return this.targetResolution_=r,this.targetRotation_=s,this.targetCenter_=a,void this.applyTargetState_();i=i||(0===t?this.cancelAnchor_:void 0),this.cancelAnchor_=void 0,this.getResolution()===r&&this.getRotation()===s&&this.getCenterInternal()&&Ae(this.getCenterInternal(),a)||(this.getAnimating()&&this.cancelAnimations(),this.animateInternal({rotation:s,center:a,resolution:r,duration:t,easing:mi,anchor:i}))}beginInteraction(){this.resolveConstraints(0),this.setHint(1,1)}
1endInteraction(t,e,i){i=i&&ei(i,this.getProjection()),this.endInteractionInternal(t,e,i)}endInteractionInternal(t,e,i){this.getInteracting()&&(this.setHint(1,-1),this.resolveConstraints(t,e,i))}getConstrainedCenter(t,e){const i=this.getViewportSize_(this.getRotation());return this.constraints_.center(t,e||this.getResolution(),i)}getConstrainedZoom(t,e){const i=this.getResolutionForZoom(t);return this.getZoomForResolution(this.getConstrainedResolution(i,e))}getConstrainedResolution(t,e){e=e||0;const i=this.getViewportSize_(this.getRotation());return this.constraints_.resolution(t,e,i)}};function tn(t,e){if(!t.visible)return!1;const i=e.resolution;if(i<t.minResolution||i>=t.maxResolution)return!1;const n=e.zoom;return n>t.minZoom&&n<=t.maxZoom}const en=class extends le{constructor(t){const e=Object.assign({},t);delete e.source,super(e),this.on,this.once,this.un,this.mapPrecomposeKey_=null,this.mapRenderKey_=null,this.sourceChangeKey_=null,this.renderer_=null,this.sourceReady_=!1,this.rendered=!1,t.render&&(this.render=t.render),t.map&&this.setMap(t.map),this.addChangeListener(ae,this.handleSourcePropertyChange_);const i=t.source?t.source:null;this.setSource(i)}getLayersArray(t){return(t=t||[]).push(this),t}getLayerStatesArray(t){return(t=t||[]).push(this.getLayerState()),t}getSource(){return this.get(ae)||null}getRenderSource(){return this.getSource()}getSourceState(){const t=this.getSource();return t?t.getState():"undefined"}handleSourceChange_(){this.changed(),this.sourceReady_||"ready"!==this.getSource().getState()||(this.sourceReady_=!0,this.dispatchEvent("sourceready"))}handleSourcePropertyChange_(){this.sourceChangeKey_&&(E(this.sourceChangeKey_),this.sourceChangeKey_=null),this.sourceReady_=!1;const t=this.getSource();t&&(this.sourceChangeKey_=k(t,v,this.handleSourceChange_,this),"ready"===t.getState()&&(this.sourceReady_=!0,setTimeout((()=>{this.dispatchEvent("sourceready")}),0))),this.changed()}getFeatures(t){return this.renderer_?this.renderer_.getFeatures(t):Promise.resolve([])}getData(t){return this.renderer_&&this.rendered?this.renderer_.getData(t):null}isVisible(t){let e;const i=this.getMapInternal();let n;!t&&i&&(t=i.getView()),e=t instanceof Qi?{viewState:t.getState(),extent:t.calculateExtent()}:t,!e.layerStatesArray&&i&&(e.layerStatesArray=i.getLayerGroup().getLayerStatesArray()),n=e.layerStatesArray?e.layerStatesArray.find((t=>t.layer===this)):this.getLayerState();const s=this.getExtent();return tn(n,e.viewState)&&(!s||At(s,e.extent))}getAttributions(t){if(!this.isVisible(t))return[];let e;const i=this.getSource();if(i&&(e=i.getAttributions()),!e)return[];let n=e(t instanceof Qi?t.getViewStateAndExtent():t);return Array.isArray(n)||(n=[n]),n}render(t,e){const i=this.getRenderer();return i.prepareFrame(t)?(this.rendered=!0,i.renderFrame(t,e)):null}unrender(){this.rendered=!1}setMapInternal(t){t||this.unrender(),this.set("map",t)}getMapInternal(){return this.get("map")}setMap(t){this.mapPrecomposeKey_&&(E(this.mapPrecomposeKey_),this.mapPrecomposeKey_=null),t||this.changed(),this.mapRenderKey_&&(E(this.mapRenderKey_),this.mapRenderKey_=null),t&&(this.mapPrecomposeKey_=k(t,ce,(function(t){const e=t.frameState.layerStatesArray,i=this.getLayerState(!1);J(!e.some((function(t){return t.layer===i.layer})),67),e.push(i)}),this),this.mapRenderKey_=k(this,v,t.render,t),this.changed())}setSource(t){this.set(ae,t)}getRenderer(){return this.renderer_||(this.renderer_=this.createRenderer()),this.renderer_}hasRenderer(){return!!this.renderer_}createRenderer(){return null}disposeInternal(){this.renderer_&&(this.renderer_.dispose(),delete this.renderer_),this.setSource(null),super.disposeInternal()}};function nn(t,e){Jt.expire()}const sn=class extends a{constructor(t){super(),this.map_=t}dispatchRenderEvent(t,e){M()}calculateMatrices2D(t){const e=t.viewState,i=t.coordinateToPixelTransform,n=t.pixelToCoordinateTransform;tt(i,t.size[0]/2,t.size[1]/2,1/e.resolution,-1/e.resolution,-e.rotation,-e.center[0],-e.center[1]),et(n,i)}forEachFeatureAtCoordinate(t,e,i,n,s,o,r,a){let l;const h=e.viewState;function d(t,e,i,n){return s.call(o,e,t?i:null,n)}const c=h.projection,u=Oe(t.slice(),c),p=[[0,0]];if(c.canWrapX()&&n){const t=Mt(c.getExtent());p.push([-t,0],[t,0])}const g=e.layerStatesArray,f=g.length,m=[],_=[];for(let n=0;n<p.length;n++)for(let s=f-1;s>=0;--s){const o=g[s],c=o.layer;if(c.hasRenderer()&&tn(o,h)&&r.call(a,c)){const s=c.getRenderer(),r=c.get
1Source();if(s&&r){const a=r.getWrapX()?u:t,h=d.bind(null,o.managed);_[0]=a[0]+p[n][0],_[1]=a[1]+p[n][1],l=s.forEachFeatureAtCoordinate(_,e,i,h,m)}if(l)return l}}if(0===m.length)return;const y=1/m.length;return m.forEach(((t,e)=>t.distanceSq+=e*y)),m.sort(((t,e)=>t.distanceSq-e.distanceSq)),m.some((t=>l=t.callback(t.feature,t.layer,t.geometry))),l}hasFeatureAtCoordinate(t,e,i,n,s,o){return void 0!==this.forEachFeatureAtCoordinate(t,e,i,n,p,this,s,o)}getMap(){return this.map_}renderFrame(t){M()}flushDeclutterItems(t){}scheduleExpireIconCache(t){Jt.canExpireCache()&&t.postRenderFunctions.push(nn)}},on=class extends o{constructor(t,e,i,n){super(t),this.inversePixelTransform=e,this.frameState=i,this.context=n}},rn="ol-hidden",an="ol-unselectable",ln="ol-control",hn="ol-collapsed",dn=new RegExp(["^\\s*(?=(?:(?:[-a-z]+\\s*){0,2}(italic|oblique))?)","(?=(?:(?:[-a-z]+\\s*){0,2}(small-caps))?)","(?=(?:(?:[-a-z]+\\s*){0,2}(bold(?:er)?|lighter|[1-9]00 ))?)","(?:(?:normal|\\1|\\2|\\3)\\s*){0,3}((?:xx?-)?","(?:small|large)|medium|smaller|larger|[\\.\\d]+(?:\\%|in|[cem]m|ex|p[ctx]))","(?:\\s*\\/\\s*(normal|[\\.\\d]+(?:\\%|in|[cem]m|ex|p[ctx])?))","?\\s*([-,\\\"\\'\\sa-z]+?)\\s*$"].join(""),"i"),cn=["style","variant","weight","size","lineHeight","family"],un=function(t){const e=t.match(dn);if(!e)return null;const i={lineHeight:"normal",size:"1.2em",style:"normal",weight:"normal",variant:"normal"};for(let t=0,n=cn.length;t<n;++t){const n=e[t+1];void 0!==n&&(i[cn[t]]=n)}return i.families=i.family.split(/,\s?/),i};function pn(t,e,i,n){let s;return s=i&&i.length?i.shift():Y?new OffscreenCanvas(t||300,e||300):document.createElement("canvas"),t&&(s.width=t),e&&(s.height=e),s.getContext("2d",n)}function gn(t){const e=t.canvas;e.width=1,e.height=1,t.clearRect(0,0,1,1)}function fn(t,e){const i=e.parentNode;i&&i.replaceChild(t,e)}function mn(t){return t&&t.parentNode?t.parentNode.removeChild(t):null}const _n="10px sans-serif",yn="#000",vn="round",xn=[],wn="round",Cn="#000",Sn="center",Tn="middle",bn=[0,0,0,0],kn=new F;let In,En=null;const Rn={},Pn=function(){const t="32px ",e=["monospace","serif"],i=e.length,n="wmytzilWMYTZIL@#/&?$%10";let s,o;function r(s,r,a){let l=!0;for(let h=0;h<i;++h){const i=e[h];if(o=Ln(s+" "+r+" "+t+i,n),a!=i){const e=Ln(s+" "+r+" "+t+a+","+i,n);l=l&&e!=o}}return!!l}function a(){let t=!0;const e=kn.getKeys();for(let i=0,n=e.length;i<n;++i){const n=e[i];kn.get(n)<100&&(r.apply(this,n.split("\n"))?(m(Rn),En=null,In=void 0,kn.set(n,100)):(kn.set(n,kn.get(n)+1,!0),t=!1))}t&&(clearInterval(s),s=void 0)}return function(t){const e=un(t);if(!e)return;const i=e.families;for(let t=0,n=i.length;t<n;++t){const n=i[t],o=e.style+"\n"+e.weight+"\n"+n;void 0===kn.get(o)&&(kn.set(o,100,!0),r(e.style,e.weight,n)||(kn.set(o,0,!0),void 0===s&&(s=setInterval(a,32))))}}}(),Mn=function(){let t;return function(e){let i=Rn[e];if(null==i){if(Y){const t=un(e),n=An(e,"Žg");i=(isNaN(Number(t.lineHeight))?1.2:Number(t.lineHeight))*(n.actualBoundingBoxAscent+n.actualBoundingBoxDescent)}else t||(t=document.createElement("div"),t.innerHTML="M",t.style.minHeight="0",t.style.maxHeight="none",t.style.height="auto",t.style.padding="0",t.style.border="none",t.style.position="absolute",t.style.display="block",t.style.left="-99999px"),t.style.font=e,document.body.appendChild(t),i=t.offsetHeight,document.body.removeChild(t);Rn[e]=i}return i}}();function An(t,e){return En||(En=pn(1,1)),t!=In&&(En.font=t,In=En.font),En.measureText(e)}function Ln(t,e){return An(t,e).width}function On(t,e,i){if(e in i)return i[e];const n=e.split("\n").reduce(((e,i)=>Math.max(e,Ln(t,i))),0);return i[e]=n,n}const Fn=class extends sn{constructor(t){super(t),this.fontChangeListenerKey_=k(kn,r,t.redrawText.bind(t)),this.element_=document.createElement("div");const e=this.element_.style;e.position="absolute",e.width="100%",e.height="100%",e.zIndex="0",this.element_.className=an+" ol-layers";const i=t.getViewport();i.insertBefore(this.element_,i.firstChild||null),this.children_=[],this.renderedVisible_=!0,this.declutterLayers_=[]}dispatchRenderEvent(t,e){const i=this.getMap();if(i.hasListener(t)){const n=new on(t,void 0,e);i.dispatchEvent(n)}}disposeInternal(){E(this.fontChangeListenerKey_),this.element_.parentNode.removeChild(this.element_),super.disposeInternal()}renderFrame(t){if(!t)return void(this.renderedVisible_&&(this.element_.style.display="none",this.renderedVisible_=!1));this.calculateMatrices2D(t),this.dispatchRenderEvent(ce,t);const e=t.layerStatesArray.sort((function(t,e){return t.zIndex-e.zIndex})),i=t.viewState;this.children_.length=0;const n=this.declutterLayers_;n.length=0;let s=null;for(let o=0,r=e.length;o<r;++o){const r=e[o];t.layerIndex=o;const a=r.layer,l=a.getSourceState();if(!tn(r,i)||"ready"!=l&&"undefined"!=l){a.unrender();continue}const h=a.render(t,s);h&&(h!==s&&(this.children_.push(h),s=h),"getDeclutter"in a&&n.push(a))}this.flushDeclutterItems(t),function(t,e){const i=t.childNodes;for(let n=0;;++n){const s=i[n],o=e[n];if(!s&&!o)break;s!==o&&(s?o?t.insertBefore(o,s):(t.removeChild(s),--n):t.appendChild(o))}}(this.element_,this.children_),this.dispatchRenderEvent("postcompose",t),this.renderedVisible_||(this.element_.style.display="",this.renderedVisible_=!0),this.scheduleExpireIconCache(t)}flushDeclutterItems(t){const e=this.declutterLayers_;for(let i=e.length-1;i>=0;--i)e[i].renderDeclutter(t);e.length=0}};class Dn extends o{constructor(t,e){super(t),this.layer=e}}const Zn="layers";class Nn extends le{constructor(t){t=t||{};const e=Object.assign({},t);delete e.layers;let i=t.layers;super(e),this.on,this.once,this.un,this.layersListenerKeys_=[],this.listenerKeys_={},this.addChangeListener(Zn,this.handleLayersChanged_),i?Array.isArray(i)?i=new G(i.slice(),{unique:!0}):J("function"==typeof i.getArray,43):i=new G(void 0,{unique:!0}),this.setLayers(i)}handleLayerChange_(){this.changed()}handleLayersChanged_(){this.layersListenerKeys_.forEach(E),this.layersListenerKeys_.length=0;const t=this.getLayers();this.layersListenerKeys_.push(k(t,z,this.handleLayersAdd_,this),k(t,j,this.handleLayersRemove_,this));for(const t in this.listenerKeys_)this.listenerKeys_[t].forEach(E);m(this.listenerKeys_);const e=t.getArray();for(let t=0,i=e.length;t<i;t++){const i=e[t];this.registerLayerListeners_(i),this.dispatchEvent(new Dn("addlayer",i))}this.changed()}registerLayerListeners_(t){const e=[k(t,r,this.handleLayerChange_,this),k(t,v,this.handleLayerChange_,this)];t instanceof Nn&&e.push(k(t,"addlayer",this.handleLayerGroupAdd_,this),k(t,"removelayer",this.handleLayerGroupRemove_,this)),this.listenerKeys_[L(t)]=e}handleLayerGroupAdd_(t){this.dispatchEvent(new Dn("addlayer",t.layer))}handleLayerGroupRemove_(t){this.dispatchEvent(new Dn("removelayer",t.layer))}handleLayersAdd_(t){const e=t.element;this.registerLayerListeners_(e),this.dispatchEvent(new Dn("addlayer",e)),this.changed()}handleLayersRemove_(t){const e=t.element,i=L(e);
1this.listenerKeys_[i].forEach(E),delete this.listenerKeys_[i],this.dispatchEvent(new Dn("removelayer",e)),this.changed()}getLayers(){return this.get(Zn)}setLayers(t){const e=this.getLayers();if(e){const t=e.getArray();for(let e=0,i=t.length;e<i;++e)this.dispatchEvent(new Dn("removelayer",t[e]))}this.set(Zn,t)}getLayersArray(t){return t=void 0!==t?t:[],this.getLayers().forEach((function(e){e.getLayersArray(t)})),t}getLayerStatesArray(t){const e=void 0!==t?t:[],i=e.length;this.getLayers().forEach((function(t){t.getLayerStatesArray(e)}));const n=this.getLayerState();let s=n.zIndex;t||void 0!==n.zIndex||(s=0);for(let t=i,o=e.length;t<o;t++){const i=e[t];i.opacity*=n.opacity,i.visible=i.visible&&n.visible,i.maxResolution=Math.min(i.maxResolution,n.maxResolution),i.minResolution=Math.max(i.minResolution,n.minResolution),i.minZoom=Math.max(i.minZoom,n.minZoom),i.maxZoom=Math.min(i.maxZoom,n.maxZoom),void 0!==n.extent&&(void 0!==i.extent?i.extent=Et(i.extent,n.extent):i.extent=n.extent),void 0===i.zIndex&&(i.zIndex=s)}return e}getSourceState(){return"ready"}}const zn=Nn,jn=class extends o{constructor(t,e,i){super(t),this.map=e,this.frameState=void 0!==i?i:null}},$n=class extends jn{constructor(t,e,i,n,s,o){super(t,e,s),this.originalEvent=i,this.pixel_=null,this.coordinate_=null,this.dragging=void 0!==n&&n,this.activePointers=o}get pixel(){return this.pixel_||(this.pixel_=this.map.getEventPixel(this.originalEvent)),this.pixel_}set pixel(t){this.pixel_=t}get coordinate(){return this.coordinate_||(this.coordinate_=this.map.getCoordinateFromPixel(this.pixel)),this.coordinate_}set coordinate(t){this.coordinate_=t}preventDefault(){super.preventDefault(),"preventDefault"in this.originalEvent&&this.originalEvent.preventDefault()}stopPropagation(){super.stopPropagation(),"stopPropagation"in this.originalEvent&&this.originalEvent.stopPropagation()}},Wn={SINGLECLICK:"singleclick",CLICK:w,DBLCLICK:"dblclick",POINTERDRAG:"pointerdrag",POINTERMOVE:"pointermove",POINTERDOWN:"pointerdown",POINTERUP:"pointerup",POINTEROVER:"pointerover",POINTEROUT:"pointerout",POINTERENTER:"pointerenter",POINTERLEAVE:"pointerleave",POINTERCANCEL:"pointercancel"},Gn="pointerdown",Bn=class extends y{constructor(t,e){super(t),this.map_=t,this.clickTimeoutId_,this.emulateClicks_=!1,this.dragging_=!1,this.dragListenerKeys_=[],this.moveTolerance_=void 0===e?1:e,this.down_=null;const i=this.map_.getViewport();this.activePointers_=[],this.trackedTouches_={},this.element_=i,this.pointerdownListenerKey_=k(i,Gn,this.handlePointerDown_,this),this.originalPointerMoveEvent_,this.relayedListenerKey_=k(i,"pointermove",this.relayMoveEvent_,this),this.boundHandleTouchMove_=this.handleTouchMove_.bind(this),this.element_.addEventListener(T,this.boundHandleTouchMove_,!!q&&{passive:!1})}emulateClick_(t){let e=new $n(Wn.CLICK,this.map_,t);this.dispatchEvent(e),void 0!==this.clickTimeoutId_?(clearTimeout(this.clickTimeoutId_),this.clickTimeoutId_=void 0,e=new $n(Wn.DBLCLICK,this.map_,t),this.dispatchEvent(e)):this.clickTimeoutId_=setTimeout((()=>{this.clickTimeoutId_=void 0;const e=new $n(Wn.SINGLECLICK,this.map_,t);this.dispatchEvent(e)}),250)}updateActivePointers_(t){const e=t,i=e.pointerId;if(e.type==Wn.POINTERUP||e.type==Wn.POINTERCANCEL){delete this.trackedTouches_[i];for(const t in this.trackedTouches_)if(this.trackedTouches_[t].target!==e.target){delete this.trackedTouches_[t];break}}else e.type!=Wn.POINTERDOWN&&e.type!=Wn.POINTERMOVE||(this.trackedTouches_[i]=e);this.activePointers_=Object.values(this.trackedTouches_)}handlePointerUp_(t){this.updateActivePointers_(t);const e=new $n(Wn.POINTERUP,this.map_,t,void 0,void 0,this.activePointers_);this.dispatchEvent(e),this.emulateClicks_&&!e.defaultPrevented&&!this.dragging_&&this.isMouseActionButton_(t)&&this.emulateClick_(this.down_),0===this.activePointers_.length&&(this.dragListenerKeys_.forEach(E),this.dragListenerKeys_.length=0,this.dragging_=!1,this.down_=null)}isMouseActionButton_(t){return 0===t.button}handlePointerDown_(t){this.emulateClicks_=0===this.activePointers_.length,this.updateActivePointers_(t);const e=new $n(Wn.POINTERDOWN,this.map_,t,void 0,void 0,this.activePointers_);
1if(this.dispatchEvent(e),this.down_=new PointerEvent(t.type,t),Object.defineProperty(this.down_,"target",{writable:!1,value:t.target}),0===this.dragListenerKeys_.length){const t=this.map_.getOwnerDocument();this.dragListenerKeys_.push(k(t,Wn.POINTERMOVE,this.handlePointerMove_,this),k(t,Wn.POINTERUP,this.handlePointerUp_,this),k(this.element_,Wn.POINTERCANCEL,this.handlePointerUp_,this)),this.element_.getRootNode&&this.element_.getRootNode()!==t&&this.dragListenerKeys_.push(k(this.element_.getRootNode(),Wn.POINTERUP,this.handlePointerUp_,this))}}handlePointerMove_(t){if(this.isMoving_(t)){this.updateActivePointers_(t),this.dragging_=!0;const e=new $n(Wn.POINTERDRAG,this.map_,t,this.dragging_,void 0,this.activePointers_);this.dispatchEvent(e)}}relayMoveEvent_(t){this.originalPointerMoveEvent_=t;const e=!(!this.down_||!this.isMoving_(t));this.dispatchEvent(new $n(Wn.POINTERMOVE,this.map_,t,e))}handleTouchMove_(t){const e=this.originalPointerMoveEvent_;e&&!e.defaultPrevented||"boolean"==typeof t.cancelable&&!0!==t.cancelable||t.preventDefault()}isMoving_(t){return this.dragging_||Math.abs(t.clientX-this.down_.clientX)>this.moveTolerance_||Math.abs(t.clientY-this.down_.clientY)>this.moveTolerance_}disposeInternal(){this.relayedListenerKey_&&(E(this.relayedListenerKey_),this.relayedListenerKey_=null),this.element_.removeEventListener(T,this.boundHandleTouchMove_),this.pointerdownListenerKey_&&(E(this.pointerdownListenerKey_),this.pointerdownListenerKey_=null),this.dragListenerKeys_.forEach(E),this.dragListenerKeys_.length=0,this.element_=null,super.disposeInternal()}},Vn="postrender",Un="loadstart",Xn="loadend",Kn="layergroup",Yn="size",Hn="target",qn="view",Jn=1/0,Qn=class{constructor(t,e){this.priorityFunction_=t,this.keyFunction_=e,this.elements_=[],this.priorities_=[],this.queuedElements_={}}clear(){this.elements_.length=0,this.priorities_.length=0,m(this.queuedElements_)}dequeue(){const t=this.elements_,e=this.priorities_,i=t[0];1==t.length?(t.length=0,e.length=0):(t[0]=t.pop(),e[0]=e.pop(),this.siftUp_(0));const n=this.keyFunction_(i);return delete this.queuedElements_[n],i}enqueue(t){J(!(this.keyFunction_(t)in this.queuedElements_),31);const e=this.priorityFunction_(t);return e!=Jn&&(this.elements_.push(t),this.priorities_.push(e),this.queuedElements_[this.keyFunction_(t)]=!0,this.siftDown_(0,this.elements_.length-1),!0)}getCount(){return this.elements_.length}getLeftChildIndex_(t){return 2*t+1}getRightChildIndex_(t){return 2*t+2}getParentIndex_(t){return t-1>>1}heapify_(){let t;for(t=(this.elements_.length>>1)-1;t>=0;t--)this.siftUp_(t)}isEmpty(){return 0===this.elements_.length}isKeyQueued(t){return t in this.queuedElements_}isQueued(t){return this.isKeyQueued(this.keyFunction_(t))}siftUp_(t){const e=this.elements_,i=this.priorities_,n=e.length,s=e[t],o=i[t],r=t;for(;t<n>>1;){const s=this.getLeftChildIndex_(t),o=this.getRightChildIndex_(t),r=o<n&&i[o]<i[s]?o:s;e[t]=e[r],i[t]=i[r],t=r}e[t]=s,i[t]=o,this.siftDown_(r,t)}siftDown_(t,e){const i=this.elements_,n=this.priorities_,s=i[e],o=n[e];for(;e>t;){const t=this.getParentIndex_(e);if(!(n[t]>o))break;i[e]=i[t],n[e]=n[t],e=t}i[e]=s,n[e]=o}reprioritize(){const t=this.priorityFunction_,e=this.elements_,i=this.priorities_;let n=0;const s=e.length;let o,r,a;for(r=0;r<s;++r)o=e[r],a=t(o),a==Jn?delete this.queuedElements_[this.keyFunction_(o)]:(i[n]=a,e[n++]=o);e.length=n,i.length=n,this.heapify_()}},ts=class extends Qn{constructor(t,e){super((function(e){return t.apply(null,e)}),(function(t){return t[0].getKey()})),this.boundHandleTileChange_=this.handleTileChange.bind(this),this.tileChangeCallback_=e,this.tilesLoading_=0,this.tilesLoadingKeys_={}}enqueue(t){const e=super.enqueue(t);return e&&t[0].addEventListener(v,this.boundHandleTileChange_),e}getTilesLoading(){return this.tilesLoading_}handleTileChange(t){const e=t.target,i=e.getState();if(2===i||3===i||4===i){3!==i&&e.removeEventListener(v,this.boundHandleTileChange_);const t=e.getKey();t in this.tilesLoadingKeys_&&(delete this.tilesLoadingKeys_[t],--this.tilesLoading_),this.tileChangeCallback_()}}loadMoreTiles(t,e){let i,n,s,o=0;for(;this.tilesLoading_<t&&o<e&&this.getCount()>0;)n=this.dequeue()[0],s=n.getKey(),i=n.getState(),0!==i||s in this.tilesLoadingKeys_||(this.tilesLoadingKeys_[s]=!0,++this.tilesLoading_,++o,n.load())}},es=class extends F{constructor(t){super();const e=t.element;!e||t.target||e.style.pointerEvents||(e.style.pointerEvents="auto"),this.element=e||null,this.target_=null,this.map_=null,this.listenerKeys=[],t.render&&(this.render=t.render),t.target&&this.setTarget(t.target)}disposeInternal(){mn(this.element),super.disposeInternal()}getMap(){return this.map_}setMap(t){this.map_&&mn(this.element);for(let t=0,e=this.listenerKeys.length;t<e;++t)E(this.listenerKeys[t]);this.listenerKeys.length=0,this.map_=t,t&&((this.target_?this.target_:t.getOverlayContainerStopEvent()).appendChild(this.element),this.render!==f&&this.listenerKeys.push(k(t,Vn,this.render,this)),t.render())}render(t){}setTarget(t){this.target_="string"==typeof t?document.getElementById(t):t}},is=class extends es{constructor(t){t=t||{},super({element:document.createElement("div"),render:t.render,target:t.target}),this.ulElement_=document.createElement("ul"),this.collapsed_=void 0===t.collapsed||t.collapsed,this.userCollapsed_=this.collapsed_,this.overrideCollapsible_=void 0!==t.collapsible,this.collapsible_=void 0===t.collapsible||t.collapsible,this.collapsible_||(this.collapsed_=!1);const e=void 0!==t.className?t.className:"ol-attribution",i=void 0!==t.tipLabel?t.tipLabel:"Attributions",n=void 0!==t.expandClassName?t.expandClassName:e+"-expand",s=void 0!==t.collapseLabel?t.collapseLabel:"›",o=void 0!==t.collapseClassName?t.collapseClassName:e+"-collapse";"string"==typeof s?(this.collapseLabel_=document.createElement("span"),this.collapseLabel_.textContent=s,this.collapseLabel_.className=o):this.collapseLabel_=s;const r=void 0!==t.label?t.label:"i";"string"==typeof r?(this.label_=document.createElement("span"),this.label_.textContent=r,this.label_.className=n):this.label_=r;const a=this.collapsible_&&!this.collapsed_?this.collapseLabel_:this.label_;this.toggleButton_=document.createElement("button"),this.toggleButton_.setAttribute("type","button"),this.toggleButton_.setAttribute("aria-expanded",String(!this.collapsed_)),this.toggleButton_.title=i,this.toggleButton_.appendChild(a),this.toggleButton_.addEventListener(w,this.handleClick_.bind(this),!1);const l=e+" "+an+" "+ln+(this.collapsed_&&this.collapsible_?" "+hn:"")+(this.collapsible_?"":" ol-uncollapsible"),h=this.element;h.className=l,h.appendChild(this.toggleButton_),h.appendChild(this.ulElement_),this.renderedAttributions_=[],this.renderedVisible_=!0}collectSourceAttributions_(t){const e=Array.from(new Set(this.getMap().getAllLayers().flatMap((e=>e.getAttributions(t))))),i=!this.getMap().getAllLayers().some((t=>t.getSource()&&!1===t.getSource().getAttributionsCollapsible()));return this.overrideCollapsible_||this.setCollapsible(i),e}updateElement_(t){if(!t)return void(this.renderedVisible_&&(this.element.style.display="none",this.renderedVisible_=!1));const e=this.collectSourceAttributions_(t),i=e.length>0;if(this.renderedVisible_!=i&&(this.element.style.display=i?"":"none",this.renderedVisible_=i),!u(e,this.renderedAttributions_)){!function(t){for(;
vendor: 7,611 bytes, line 1
1t.lastChild;)t.removeChild(t.lastChild)}(this.ulElement_);for(let t=0,i=e.length;t<i;++t){const i=document.createElement("li");i.innerHTML=e[t],this.ulElement_.appendChild(i)}this.renderedAttributions_=e}}handleClick_(t){t.preventDefault(),this.handleToggle_(),this.userCollapsed_=this.collapsed_}handleToggle_(){this.element.classList.toggle(hn),this.collapsed_?fn(this.collapseLabel_,this.label_):fn(this.label_,this.collapseLabel_),this.collapsed_=!this.collapsed_,this.toggleButton_.setAttribute("aria-expanded",String(!this.collapsed_))}getCollapsible(){return this.collapsible_}setCollapsible(t){this.collapsible_!==t&&(this.collapsible_=t,this.element.classList.toggle("ol-uncollapsible"),this.userCollapsed_&&this.handleToggle_())}setCollapsed(t){this.userCollapsed_=t,this.collapsible_&&this.collapsed_!==t&&this.handleToggle_()}getCollapsed(){return this.collapsed_}render(t){this.updateElement_(t.frameState)}},ns=class extends es{constructor(t){t=t||{},super({element:document.createElement("div"),render:t.render,target:t.target});const e=void 0!==t.className?t.className:"ol-rotate",i=void 0!==t.label?t.label:"⇧",n=void 0!==t.compassClassName?t.compassClassName:"ol-compass";this.label_=null,"string"==typeof i?(this.label_=document.createElement("span"),this.label_.className=n,this.label_.textContent=i):(this.label_=i,this.label_.classList.add(n));const s=t.tipLabel?t.tipLabel:"Reset rotation",o=document.createElement("button");o.className=e+"-reset",o.setAttribute("type","button"),o.title=s,o.appendChild(this.label_),o.addEventListener(w,this.handleClick_.bind(this),!1);const r=e+" "+an+" "+ln,a=this.element;a.className=r,a.appendChild(o),this.callResetNorth_=t.resetNorth?t.resetNorth:void 0,this.duration_=void 0!==t.duration?t.duration:250,this.autoHide_=void 0===t.autoHide||t.autoHide,this.rotation_=void 0,this.autoHide_&&this.element.classList.add(rn)}handleClick_(t){t.preventDefault(),void 0!==this.callResetNorth_?this.callResetNorth_():this.resetNorth_()}resetNorth_(){const t=this.getMap().getView();if(!t)return;const e=t.getRotation();void 0!==e&&(this.duration_>0&&e%(2*Math.PI)!=0?t.animate({rotation:0,duration:this.duration_,easing:mi}):t.setRotation(0))}render(t){const e=t.frameState;if(!e)return;const i=e.viewState.rotation;if(i!=this.rotation_){const t="rotate("+i+"rad)";if(this.autoHide_){const t=this.element.classList.contains(rn);t||0!==i?t&&0!==i&&this.element.classList.remove(rn):this.element.classList.add(rn)}this.label_.style.transform=t}this.rotation_=i}},ss=class extends es{constructor(t){t=t||{},super({element:document.createElement("div"),target:t.target});const e=void 0!==t.className?t.className:"ol-zoom",i=void 0!==t.delta?t.delta:1,n=void 0!==t.zoomInClassName?t.zoomInClassName:e+"-in",s=void 0!==t.zoomOutClassName?t.zoomOutClassName:e+"-out",o=void 0!==t.zoomInLabel?t.zoomInLabel:"+",r=void 0!==t.zoomOutLabel?t.zoomOutLabel:"–",a=void 0!==t.zoomInTipLabel?t.zoomInTipLabel:"Zoom in",l=void 0!==t.zoomOutTipLabel?t.zoomOutTipLabel:"Zoom out",h=document.createElement("button");h.className=n,h.setAttribute("type","button"),h.title=a,h.appendChild("string"==typeof o?document.createTextNode(o):o),h.addEventListener(w,this.handleClick_.bind(this,i),!1);const d=document.createElement("button");d.className=s,d.setAttribute("type","button"),d.title=l,d.appendChild("string"==typeof r?document.createTextNode(r):r),d.addEventListener(w,this.handleClick_.bind(this,-i),!1);const c=e+" "+an+" "+ln,u=this.element;u.className=c,u.appendChild(h),u.appendChild(d),this.duration_=void 0!==t.duration?t.duration:250}handleClick_(t,e){e.preventDefault(),this.zoomByDelta_(t)}zoomByDelta_(t){const e=this.getMap().getView();if(!e)return;const i=e.getZoom();if(void 0!==i){const n=e.getConstrainedZoom(i+t);this.duration_>0?(e.getAnimating()&&e.cancelAnimations(),e.animate({zoom:n,duration:this.duration_,easing:mi})):e.setZoom(n)}}},os="active";function rs(t,e,i,n){const s=t.getZoom();if(void 0===s)return;const o=t.getConstrainedZoom(s+e),r=t.getResolutionForZoom(o);t.getAnimating()&&t.cancelAnimations(),t.animate({resolution:r,anchor:i,duration:void 0!==n?n:250,easing:mi})}const as=class extends F{constructor(t){super(),this.on,this.once,this.un,t&&t.handleEvent&&(this.handleEvent=t.handleEvent),this.map_=null,this.setActive(!0)}getActive(){return this.get(os)}getMap(){return this.map_}handleEvent(t){return!0}setActive(t){this.set(os,t)}setMap(t){this.map_=t}},ls=class extends as{constructor(t){super(),t=t||{},this.delta_=t.delta?t.delta:1,this.duration_=void 0!==t.duration?t.duration:250}handleEvent(t){let e=!1;if(t.type==Wn.DBLCLICK){const i=t.originalEvent,n=t.map,s=t.coordinate,o=i.shiftKey?-this.delta_:this.delta_;rs(n.getView(),o,s,this.duration_),i.preventDefault(),e=!0}return!e}};function hs(t){const e=t.length;let i=0,n=0;for(let s=0;s<e;s++)i+=t[s].clientX,n+=t[s].clientY;return{clientX:i/e,clientY:n/e}}const ds=class extends as{constructor(t){super(t=t||{}),t.handleDownEvent&&(this.handleDownEvent=t.handleDownEvent),t.handleDragEvent&&(this.handleDragEvent=t.handleDragEvent),t.handleMoveEvent&&(this.handleMoveEvent=t.handleMoveEvent),t.handleUpEvent&&(this.handleUpEvent=t.handleUpEvent),t.stopDown&&(this.stopDown=t.stopDown),this.handlingDownUpSequence=!1,this.targetPointers=[]}getPointerCount(){return this.targetPointers.length}handleDownEvent(t){return!1}handleDragEvent(t){}handleEvent(t){if(!t.originalEvent)return!0;let e=!1;if(this.updateTrackedPointers_(t),this.handlingDownUpSequence){if(t.type==Wn.POINTERDRAG)this.handleDragEvent(t),t.originalEvent.preventDefault();else if(t.type==Wn.POINTERUP){const e=this.handleUpEvent(t);this.handlingDownUpSequence=e&&this.targetPointers.length>0}}else if(t.type==Wn.POINTERDOWN){const i=this.handleDownEvent(t);this.handlingDownUpSequence=i,e=this.stopDown(i)}else t.type==Wn.POINTERMOVE&&this.handleMoveEvent(t);return!e}handleMoveEvent(t){}handleUpEvent(t){return!1}stopDown(t){return t}updateTrackedPointers_(t){t.activePointers&&(this.targetPointers=t.activePointers)}};function cs(t){const e=arguments;return function(t){let i=!0;for(let n=0,s=e.length;n<s&&(i=i&&e[n](t),i);++n);return i}}const us=function(t){const e=t.originalEvent;return e.altKey&&!(e.metaKey||e.ctrlKey)&&e.shiftKey},ps=function(t){return!t.map.getTargetElement().hasAttribute("tabindex")||function(t){const e=t.map.getTargetElement(),i=t.map.getOwnerDocument().activeElement;return e.contains(i)}(t)},gs=p,fs=function(t){const e=t.originalEvent;return 0==e.button&&!(U&&X&&e.ctrlKey)},ms=function(t){const e=t.originalEvent;return!e.altKey&&!(e.metaKey||e.ctrlKey)&&!e.shiftKey},_s=function(t){const e=t.originalEvent;return!e.altKey&&!(e.metaKey||e.ctrlKey)&&e.shiftKey},ys=function(t){const e=t.originalEvent,i=e.target.tagName;return"INPUT"!==i&&"SELECT"!==i&&"TEXTAREA"!==i&&!e.target.isContentEditable},vs=function(t){const e=t.originalEvent;return J(void 0!==e,56),"mouse"==e.pointerType},xs=function(t){const e=t.originalEvent;return J(void 0!==e,56),e.isPrimary&&0===e.button},ws=class extends ds{constructor(t){super({stopDown:g}),t=t||{},this.kinetic_=t.kinetic,this.lastCentroid=null,this.lastPointersCount_,this.panning_=!1;const e=t.condition?t.condition:cs(ms,xs);this.condition_=t.onFocusOnly?cs(ps,e):e,this.noKinetic_=!1}handleDragEvent(t){const e=t.map;this.panning_||(this.panning_=!0,e.getView().beginInteraction());const i=this.targetPointers,n=e.getEventPixel(hs(i));if(i.length==this.lastPointersCount_){if(this.kinetic_&&this.kinetic_.update(n[0],n[1]),this.lastCentroid){const e=[this.lastCentroid[0]-n[0],n[1]-this.lastCentroid[1]],i=t.map.getView();
1s=e,o=i.getResolution(),s[0]*=o,s[1]*=o,Le(e,i.getRotation()),i.adjustCenterInternal(e)}}else this.kinetic_&&this.kinetic_.begin();var s,o;this.lastCentroid=n,this.lastPointersCount_=i.length,t.originalEvent.preventDefault()}handleUpEvent(t){const e=t.map,i=e.getView();if(0===this.targetPointers.length){if(!this.noKinetic_&&this.kinetic_&&this.kinetic_.end()){const t=this.kinetic_.getDistance(),n=this.kinetic_.getAngle(),s=i.getCenterInternal(),o=e.getPixelFromCoordinateInternal(s),r=e.getCoordinateFromPixelInternal([o[0]-t*Math.cos(n),o[1]-t*Math.sin(n)]);i.animateInternal({center:i.getConstrainedCenter(r),duration:500,easing:mi})}return this.panning_&&(this.panning_=!1,i.endInteraction()),!1}return this.kinetic_&&this.kinetic_.begin(),this.lastCentroid=null,!0}handleDownEvent(t){if(this.targetPointers.length>0&&this.condition_(t)){const e=t.map.getView();return this.lastCentroid=null,e.getAnimating()&&e.cancelAnimations(),this.kinetic_&&this.kinetic_.begin(),this.noKinetic_=this.targetPointers.length>1,!0}return!1}},Cs=class extends ds{constructor(t){t=t||{},super({stopDown:g}),this.condition_=t.condition?t.condition:us,this.lastAngle_=void 0,this.duration_=void 0!==t.duration?t.duration:250}handleDragEvent(t){if(!vs(t))return;const e=t.map,i=e.getView();if(i.getConstraints().rotation===pi)return;const n=e.getSize(),s=t.pixel,o=Math.atan2(n[1]/2-s[1],s[0]-n[0]/2);if(void 0!==this.lastAngle_){const t=o-this.lastAngle_;i.adjustRotationInternal(-t)}this.lastAngle_=o}handleUpEvent(t){return!vs(t)||(t.map.getView().endInteraction(this.duration_),!1)}handleDownEvent(t){return!!vs(t)&&(!(!fs(t)||!this.condition_(t))&&(t.map.getView().beginInteraction(),this.lastAngle_=void 0,!0))}},Ss=class extends a{constructor(t){super(),this.geometry_=null,this.element_=document.createElement("div"),this.element_.style.position="absolute",this.element_.style.pointerEvents="auto",this.element_.className="ol-box "+t,this.map_=null,this.startPixel_=null,this.endPixel_=null}disposeInternal(){this.setMap(null)}render_(){const t=this.startPixel_,e=this.endPixel_,i="px",n=this.element_.style;n.left=Math.min(t[0],e[0])+i,n.top=Math.min(t[1],e[1])+i,n.width=Math.abs(e[0]-t[0])+i,n.height=Math.abs(e[1]-t[1])+i}setMap(t){if(this.map_){this.map_.getOverlayContainer().removeChild(this.element_);const t=this.element_.style;t.left="inherit",t.top="inherit",t.width="inherit",t.height="inherit"}this.map_=t,this.map_&&this.map_.getOverlayContainer().appendChild(this.element_)}setPixels(t,e){this.startPixel_=t,this.endPixel_=e,this.createOrUpdateGeometry(),this.render_()}createOrUpdateGeometry(){const t=this.startPixel_,e=this.endPixel_,i=[t,[t[0],e[1]],e,[e[0],t[1]]].map(this.map_.getCoordinateFromPixelInternal,this.map_);i[4]=i[0].slice(),this.geometry_?this.geometry_.setCoordinates([i]):this.geometry_=new Ki([i])}getGeometry(){return this.geometry_}};class Ts extends o{constructor(t,e,i){super(t),this.coordinate=e,this.mapBrowserEvent=i}}const bs=class extends ds{constructor(t){super(),this.on,this.once,this.un,t=t||{},this.box_=new Ss(t.className||"ol-dragbox"),this.minArea_=void 0!==t.minArea?t.minArea:64,t.onBoxEnd&&(this.onBoxEnd=t.onBoxEnd),this.startPixel_=null,this.condition_=t.condition?t.condition:fs,this.boxEndCondition_=t.boxEndCondition?t.boxEndCondition:this.defaultBoxEndCondition}defaultBoxEndCondition(t,e,i){const n=i[0]-e[0],s=i[1]-e[1];return n*n+s*s>=this.minArea_}getGeometry(){return this.box_.getGeometry()}handleDragEvent(t){this.box_.setPixels(this.startPixel_,t.pixel),this.dispatchEvent(new Ts("boxdrag",t.coordinate,t))}handleUpEvent(t){this.box_.setMap(null);const e=this.boxEndCondition_(t,this.startPixel_,t.pixel);return e&&this.onBoxEnd(t),this.dispatchEvent(new Ts(e?"boxend":"boxcancel",t.coordinate,t)),!1}handleDownEvent(t){return!!this.condition_(t)&&(this.startPixel_=t.pixel,this.box_.setMap(t.map),this.box_.setPixels(this.startPixel_,this.startPixel_),this.dispatchEvent(new Ts("boxstart",t.coordinate,t)),!0)}onBoxEnd(t){}},ks=class extends bs{constructor(t){super({condition:(t=t||{}).condition?t.condition:_s,className:t.className||"ol-dragzoom",minArea:t.minArea}),this.duration_=void 0!==t.duration?t.duration:200,this.out_=void 0!==t.out&&t.out}onBoxEnd(t){const e=this.getMap().getView();let i=this.getGeometry();if(this.out_){const t=e.rotatedExtentForGeometry(i),n=e.getResolutionForExtentInternal(t),s=e.getResolution()/n;i=i.clone(),i.scale(s*s)}e.fitInternal(i,{duration:this.duration_,easing:mi})}},Is="ArrowLeft",Es="ArrowRight",Rs="ArrowDown",Ps=class extends as{constructor(t){super(),t=t||{},this.defaultCondition_=function(t){return ms(t)&&ys(t)},this.condition_=void 0!==t.condition?t.condition:this.defaultCondition_,this.duration_=void 0!==t.duration?t.duration:100,this.pixelDelta_=void 0!==t.pixelDelta?t.pixelDelta:128}handleEvent(t){let e=!1;if(t.type==C){const i=t.originalEvent,n=i.key;if(this.condition_(t)&&(n==Rs||n==Is||n==Es||"ArrowUp"==n)){const s=t.map.getView(),o=s.getResolution()*this.pixelDelta_;let r=0,a=0;n==Rs?a=-o:n==Is?r=-o:n==Es?r=o:a=o;const l=[r,a];
1Le(l,s.getRotation()),function(t,e,i){const n=t.getCenterInternal();if(n){const s=[n[0]+e[0],n[1]+e[1]];t.animateInternal({duration:void 0!==i?i:250,easing:yi,center:t.getConstrainedCenter(s)})}}(s,l,this.duration_),i.preventDefault(),e=!0}}return!e}},Ms=class extends as{constructor(t){super(),t=t||{},this.condition_=t.condition?t.condition:function(t){return!function(t){const e=t.originalEvent;return X?e.metaKey:e.ctrlKey}(t)&&ys(t)},this.delta_=t.delta?t.delta:1,this.duration_=void 0!==t.duration?t.duration:100}handleEvent(t){let e=!1;if(t.type==C||t.type==S){const i=t.originalEvent,n=i.key;if(this.condition_(t)&&("+"===n||"-"===n)){const s=t.map,o="+"===n?this.delta_:-this.delta_;rs(s.getView(),o,void 0,this.duration_),i.preventDefault(),e=!0}}return!e}},As=class extends as{constructor(t){super(t=t||{}),this.totalDelta_=0,this.lastDelta_=0,this.maxDelta_=void 0!==t.maxDelta?t.maxDelta:1,this.duration_=void 0!==t.duration?t.duration:250,this.timeout_=void 0!==t.timeout?t.timeout:80,this.useAnchor_=void 0===t.useAnchor||t.useAnchor,this.constrainResolution_=void 0!==t.constrainResolution&&t.constrainResolution;const e=t.condition?t.condition:gs;this.condition_=t.onFocusOnly?cs(ps,e):e,this.lastAnchor_=null,this.startTime_=void 0,this.timeoutId_,this.mode_=void 0,this.trackpadEventGap_=400,this.trackpadTimeoutId_,this.deltaPerZoom_=300}endInteraction_(){this.trackpadTimeoutId_=void 0;const t=this.getMap();t&&t.getView().endInteraction(void 0,this.lastDelta_?this.lastDelta_>0?1:-1:0,this.lastAnchor_)}handleEvent(t){if(!this.condition_(t))return!0;if(t.type!==b)return!0;const e=t.map,i=t.originalEvent;let n;if(i.preventDefault(),this.useAnchor_&&(this.lastAnchor_=t.coordinate),t.type==b&&(n=i.deltaY,V&&i.deltaMode===WheelEvent.DOM_DELTA_PIXEL&&(n/=K),i.deltaMode===WheelEvent.DOM_DELTA_LINE&&(n*=40)),0===n)return!1;this.lastDelta_=n;const s=Date.now();void 0===this.startTime_&&(this.startTime_=s),(!this.mode_||s-this.startTime_>this.trackpadEventGap_)&&(this.mode_=Math.abs(n)<4?"trackpad":"wheel");const o=e.getView();if("trackpad"===this.mode_&&!o.getConstrainResolution()&&!this.constrainResolution_)return this.trackpadTimeoutId_?clearTimeout(this.trackpadTimeoutId_):(o.getAnimating()&&o.cancelAnimations(),o.beginInteraction()),this.trackpadTimeoutId_=setTimeout(this.endInteraction_.bind(this),this.timeout_),o.adjustZoom(-n/this.deltaPerZoom_,this.lastAnchor_),this.startTime_=s,!1;this.totalDelta_+=n;const r=Math.max(this.timeout_-(s-this.startTime_),0);return clearTimeout(this.timeoutId_),this.timeoutId_=setTimeout(this.handleWheelZoom_.bind(this,e),r),!1}handleWheelZoom_(t){const e=t.getView();e.getAnimating()&&e.cancelAnimations();let i=-Ft(this.totalDelta_,-this.maxDelta_*this.deltaPerZoom_,this.maxDelta_*this.deltaPerZoom_)/this.deltaPerZoom_;(e.getConstrainResolution()||this.constrainResolution_)&&(i=i?i>0?1:-1:0),rs(e,i,this.lastAnchor_,this.duration_),this.mode_=void 0,this.totalDelta_=0,this.lastAnchor_=null,this.startTime_=void 0,this.timeoutId_=void 0}setMouseAnchor(t){this.useAnchor_=t,t||(this.lastAnchor_=null)}},Ls=class extends ds{constructor(t){const e=t=t||{};e.stopDown||(e.stopDown=g),super(e),this.anchor_=null,this.lastAngle_=void 0,this.rotating_=!1,this.rotationDelta_=0,this.threshold_=void 0!==t.threshold?t.threshold:.3,this.duration_=void 0!==t.duration?t.duration:250}handleDragEvent(t){let e=0;const i=this.targetPointers[0],n=this.targetPointers[1],s=Math.atan2(n.clientY-i.clientY,n.clientX-i.clientX);if(void 0!==this.lastAngle_){const t=s-this.lastAngle_;this.rotationDelta_+=t,!this.rotating_&&Math.abs(this.rotationDelta_)>this.threshold_&&(this.rotating_=!0),e=t}this.lastAngle_=s;const o=t.map,r=o.getView();r.getConstraints().rotation!==pi&&(this.anchor_=o.getCoordinateFromPixelInternal(o.getEventPixel(hs(this.targetPointers))),this.rotating_&&(o.render(),r.adjustRotationInternal(e,this.anchor_)))}handleUpEvent(t){return!(this.targetPointers.length<2)||(t.map.getView().endInteraction(this.duration_),!1)}handleDownEvent(t){if(this.targetPointers.length>=2){const e=t.map;return this.anchor_=null,this.lastAngle_=void 0,this.rotating_=!1,this.rotationDelta_=0,this.handlingDownUpSequence||e.getView().beginInteraction(),!0}return!1}},Os=class extends ds{constructor(t){const e=t=t||{};e.stopDown||(e.stopDown=g),super(e),this.anchor_=null,this.duration_=void 0!==t.duration?t.duration:400,this.lastDistance_=void 0,this.lastScaleDelta_=1}handleDragEvent(t){let e=1;const i=this.targetPointers[0],n=this.targetPointers[1],s=i.clientX-n.clientX,o=i.clientY-n.clientY,r=Math.sqrt(s*s+o*o);void 0!==this.lastDistance_&&(e=this.lastDistance_/r),this.lastDistance_=r;const a=t.map,l=a.getView();1!=e&&(this.lastScaleDelta_=e),this.anchor_=a.getCoordinateFromPixelInternal(a.getEventPixel(hs(this.targetPointers))),a.render(),l.adjustResolutionInternal(e,this.anchor_)}handleUpEvent(t){if(this.targetPointers.length<2){const e=t.map.getView(),i=this.lastScaleDelta_>1?1:-1;return e.endInteraction(this.duration_,i),!1}return!0}handleDownEvent(t){if(this.targetPointers.length>=2){const e=t.map;return this.anchor_=null,this.lastDistance_=void 0,this.lastScaleDelta_=1,this.handlingDownUpSequence||e.getView().beginInteraction(),!0}return!1}};function Fs(t){t=t||{};const e=new G,i=new class{constructor(t,e,i){this.decay_=t,this.minVelocity_=e,this.delay_=i,this.points_=[],this.angle_=0,this.initialVelocity_=0}begin(){this.points_.length=0,this.angle_=0,this.initialVelocity_=0}update(t,e){this.points_.push(t,e,Date.now())}end(){if(this.points_.length<6)return!1;const t=Date.now()-this.delay_,e=this.points_.length-3;if(this.points_[e+2]<t)return!1;let i=e-3;for(;i>0&&this.points_[i+2]>t;)i-=3;const n=this.points_[e+2]-this.points_[i+2];if(n<1e3/60)return!1;const s=this.points_[e]-this.points_[i],o=this.points_[e+1]-this.points_[i+1];return this.angle_=Math.atan2(o,s),this.initialVelocity_=Math.sqrt(s*s+o*o)/n,this.initialVelocity_>this.minVelocity_}getDistance(){return(this.minVelocity_-this.initialVelocity_)/this.decay_}getAngle(){return this.angle_}}(-.005,.05,100);return(void 0===t.altShiftDragRotate||t.altShiftDragRotate)&&e.push(new Cs),(void 0===t.doubleClickZoom||t.doubleClickZoom)&&e.push(new ls({delta:t.zoomDelta,duration:t.zoomDuration})),(void 0===t.dragPan||t.dragPan)&&e.push(new ws({onFocusOnly:t.onF
1ocusOnly,kinetic:i})),(void 0===t.pinchRotate||t.pinchRotate)&&e.push(new Ls),(void 0===t.pinchZoom||t.pinchZoom)&&e.push(new Os({duration:t.zoomDuration})),(void 0===t.keyboard||t.keyboard)&&(e.push(new Ps),e.push(new Ms({delta:t.zoomDelta,duration:t.zoomDuration}))),(void 0===t.mouseWheelZoom||t.mouseWheelZoom)&&e.push(new As({onFocusOnly:t.onFocusOnly,duration:t.zoomDuration})),(void 0===t.shiftDragZoom||t.shiftDragZoom)&&e.push(new ks({duration:t.zoomDuration})),e}function Ds(t){return t[0]>0&&t[1]>0}function Zs(t,e){return Array.isArray(t)?t:(void 0===e?e=[t,t]:(e[0]=t,e[1]=t),e)}function Ns(t){t instanceof en?t.setMapInternal(null):t instanceof zn&&t.getLayers().forEach(Ns)}function zs(t,e){if(t instanceof en)t.setMapInternal(e);else if(t instanceof zn){const i=t.getLayers().getArray();for(let t=0,n=i.length;t<n;++t)zs(i[t],e)}}const js=class extends F{constructor(t){super(),t=t||{},this.on,this.once,this.un;const e=function(t){let e=null;void 0!==t.keyboardEventTarget&&(e="string"==typeof t.keyboardEventTarget?document.getElementById(t.keyboardEventTarget):t.keyboardEventTarget);const i={},n=t.layers&&"function"==typeof t.layers.getLayers?t.layers:new zn({layers:t.layers});let s,o,r;return i[Kn]=n,i[Hn]=t.target,i[qn]=t.view instanceof Qi?t.view:new Qi,void 0!==t.controls&&(Array.isArray(t.controls)?s=new G(t.controls.slice()):(J("function"==typeof t.controls.getArray,47),s=t.controls)),void 0!==t.interactions&&(Array.isArray(t.interactions)?o=new G(t.interactions.slice()):(J("function"==typeof t.interactions.getArray,48),o=t.interactions)),void 0!==t.overlays?Array.isArray(t.overlays)?r=new G(t.overlays.slice()):(J("function"==typeof t.overlays.getArray,49),r=t.overlays):r=new G,{controls:s,interactions:o,keyboardEventTarget:e,overlays:r,values:i}}(t);this.renderComplete_,this.loaded_=!0,this.boundHandleBrowserEvent_=this.handleBrowserEvent.bind(this),this.maxTilesLoading_=void 0!==t.maxTilesLoading?t.maxTilesLoading:16,this.pixelRatio_=void 0!==t.pixelRatio?t.pixelRatio:K,this.postRenderTimeoutHandle_,this.animationDelayKey_,this.animationDelay_=this.animationDelay_.bind(this),this.coordinateToPixelTransform_=[1,0,0,1,0,0],this.pixelToCoordinateTransform_=[1,0,0,1,0,0],this.frameIndex_=0,this.frameState_=null,this.previousExtent_=null,this.viewPropertyListenerKey_=null,this.viewChangeListenerKey_=null,this.layerGroupPropertyListenerKeys_=null,this.viewport_=document.createElement("div"),this.viewport_.className="ol-viewport"+("ontouchstart"in window?" ol-touch":""),this.viewport_.style.position="relative",this.viewport_.style.overflow="hidden",this.viewport_.style.width="100%",this.viewport_.style.height="100%",this.overlayContainer_=document.createElement("div"),this.overlayContainer_.style.position="absolute",this.overlayContainer_.style.zIndex="0",this.overlayContainer_.style.width="100%",this.overlayContainer_.style.height="100%",this.overlayContainer_.style.pointerEvents="none",this.overlayContainer_.className="ol-overlaycontainer",this.viewport_.appendChild(this.overlayContainer_),this.overlayContainerStopEvent_=document.createElement("div"),this.overlayContainerStopEvent_.style.position="absolute",this.overlayContainerStopEvent_.style.zIndex="0",this.overlayContainerStopEvent_.style.width="100%",this.overlayContainerStopEvent_.style.height="100%",this.overlayContainerStopEvent_.style.pointerEvents="none",this.overlayContainerStopEvent_.className="ol-overlaycontainer-stopevent",this.viewport_.appendChild(this.overlayContainerStopEvent_),this.mapBrowserEventHandler_=null,this.moveTolerance_=t.moveTolerance,this.keyboardEventTarget_=e.keyboardEventTarget,this.targetChangeHandlerKeys_=null,this.targetElement_=null,this.resizeObserver_=new ResizeObserver((()=>this.updateSize())),this.controls=e.controls||function(t){t=t||{};const e=new G;return(void 0===t.zoom||t.zoom)&&e.push(new ss(t.zoomOptions)),(void 0===t.rotate||t.rotate)&&e.push(new ns(t.rotateOptions)),(void 0===t.attribution||t.attribution)&&e.push(new is(t.attributionOptions)),e}(),this.interactions=e.interactions||Fs({onFocusOnly:!0}
1),this.overlays_=e.overlays,this.overlayIdIndex_={},this.renderer_=null,this.postRenderFunctions_=[],this.tileQueue_=new ts(this.getTilePriority.bind(this),this.handleTileChange_.bind(this)),this.addChangeListener(Kn,this.handleLayerGroupChanged_),this.addChangeListener(qn,this.handleViewChanged_),this.addChangeListener(Yn,this.handleSizeChanged_),this.addChangeListener(Hn,this.handleTargetChanged_),this.setProperties(e.values);const i=this;!t.view||t.view instanceof Qi||t.view.then((function(t){i.setView(new Qi(t))})),this.controls.addEventListener(z,(t=>{t.element.setMap(this)})),this.controls.addEventListener(j,(t=>{t.element.setMap(null)})),this.interactions.addEventListener(z,(t=>{t.element.setMap(this)})),this.interactions.addEventListener(j,(t=>{t.element.setMap(null)})),this.overlays_.addEventListener(z,(t=>{this.addOverlayInternal_(t.element)})),this.overlays_.addEventListener(j,(t=>{const e=t.element.getId();void 0!==e&&delete this.overlayIdIndex_[e.toString()],t.element.setMap(null)})),this.controls.forEach((t=>{t.setMap(this)})),this.interactions.forEach((t=>{t.setMap(this)})),this.overlays_.forEach(this.addOverlayInternal_.bind(this))}addControl(t){this.getControls().push(t)}addInteraction(t){this.getInteractions().push(t)}addLayer(t){this.getLayerGroup().getLayers().push(t)}handleLayerAdd_(t){zs(t.layer,this)}addOverlay(t){this.getOverlays().push(t)}addOverlayInternal_(t){const e=t.getId();void 0!==e&&(this.overlayIdIndex_[e.toString()]=t),t.setMap(this)}disposeInternal(){this.controls.clear(),this.interactions.clear(),this.overlays_.clear(),this.resizeObserver_.disconnect(),this.setTarget(null),super.disposeInternal()}forEachFeatureAtPixel(t,e,i){if(!this.frameState_||!this.renderer_)return;const n=this.getCoordinateFromPixelInternal(t),s=void 0!==(i=void 0!==i?i:{}).hitTolerance?i.hitTolerance:0,o=void 0!==i.layerFilter?i.layerFilter:p,r=!1!==i.checkWrapped;return this.renderer_.forEachFeatureAtCoordinate(n,this.frameState_,s,r,e,null,o,null)}getFeaturesAtPixel(t,e){const i=[];return this.forEachFeatureAtPixel(t,(function(t){i.push(t)}),e),i}getAllLayers(){const t=[];return function e(i){i.forEach((function(i){i instanceof zn?e(i.getLayers()):t.push(i)}))}(this.getLayers()),t}hasFeatureAtPixel(t,e){if(!this.frameState_||!this.renderer_)return!1;const i=this.getCoordinateFromPixelInternal(t),n=void 0!==(e=void 0!==e?e:{}).layerFilter?e.layerFilter:p,s=void 0!==e.hitTolerance?e.hitTolerance:0,o=!1!==e.checkWrapped;return this.renderer_.hasFeatureAtCoordinate(i,this.frameState_,s,o,n,null)}getEventCoordinate(t){return this.getCoordinateFromPixel(this.getEventPixel(t))}getEventCoordinateInternal(t){return this.getCoordinateFromPixelInternal(this.getEventPixel(t))}getEventPixel(t){const e=this.viewport_.getBoundingClientRect(),i=this.getSize(),n=e.width/i[0],s=e.height/i[1],o="changedTouches"in t?t.changedTouches[0]:t;return[(o.clientX-e.left)/n,(o.clientY-e.top)/s]}getTarget(){return this.get(Hn)}getTargetElement(){return this.targetElement_}getCoordinateFromPixel(t){return ti(this.getCoordinateFromPixelInternal(t),this.getView().getProjection())}getCoordinateFromPixelInternal(t){const e=this.frameState_;return e?Q(e.pixelToCoordinateTransform,t.slice()):null}getControls(){return this.controls}getOverlays(){return this.overlays_}getOverlayById(t){const e=this.overlayIdIndex_[t.toString()];return void 0!==e?e:null}getInteractions(){return this.interactions}getLayerGroup(){return this.get(Kn)}setLayers(t){const e=this.getLayerGroup();if(t instanceof G)return void e.setLayers(t);const i=e.getLayers();i.clear(),i.extend(t)}getLayers(){return this.getLayerGroup().getLayers()}getLoadingOrNotReady(){const t=this.getLayerGroup().getLayerStatesArray();for(let e=0,i=t.length;e<i;++e){const i=t[e];if(!i.visible)continue;const n=i.layer.getRenderer();if(n&&!n.ready)return!0;const s=i.layer.getSource();if(s&&s.loading)return!0}return!1}getPixelFromCoordinate(t){const e=ei(t,this.getView().getProjection());return this.getPixelFromCoordinateInternal(e)}getPixelFromCoordinateInternal(t){const e=this.frameState_;return e?Q(e.coordinateToPixelTransform,t.slice(0,2)):null}getRenderer(){return this.renderer_}getSize(){return this.get(Yn)}getView(){return this.get(qn)}getViewport(){return this.viewport_}getOverlayContainer(){return this.overlayContainer_}getOverlayContainerStopEvent(){return this.overlayContainerStopEvent_}getOwnerDocument(){const t=this.getTargetElement();return t?t.ownerDocument:document}
1getTilePriority(t,e,i,n){return function(t,e,i,n,s){if(!t||!(i in t.wantedTiles))return Jn;if(!t.wantedTiles[i][e.getKey()])return Jn;const o=t.viewState.center,r=n[0]-o[0],a=n[1]-o[1];return 65536*Math.log(s)+Math.sqrt(r*r+a*a)/s}(this.frameState_,t,e,i,n)}handleBrowserEvent(t,e){e=e||t.type;const i=new $n(e,this,t);this.handleMapBrowserEvent(i)}handleMapBrowserEvent(t){if(!this.frameState_)return;const e=t.originalEvent,i=e.type;if(i===Gn||i===b||i===C){const t=this.getOwnerDocument(),i=this.viewport_.getRootNode?this.viewport_.getRootNode():t,n=e.target;if(this.overlayContainerStopEvent_.contains(n)||!(i===t?t.documentElement:i).contains(n))return}if(t.frameState=this.frameState_,!1!==this.dispatchEvent(t)){const e=this.getInteractions().getArray().slice();for(let i=e.length-1;i>=0;i--){const n=e[i];if(n.getMap()===this&&n.getActive()&&this.getTargetElement()&&(!n.handleEvent(t)||t.propagationStopped))break}}}handlePostRender(){const t=this.frameState_,e=this.tileQueue_;if(!e.isEmpty()){let i=this.maxTilesLoading_,n=i;if(t){const e=t.viewHints;if(e[0]||e[1]){const e=Date.now()-t.time>8;i=e?0:8,n=e?0:2}}e.getTilesLoading()<i&&(e.reprioritize(),e.loadMoreTiles(i,n))}t&&this.renderer_&&!t.animate&&(!0===this.renderComplete_?(this.hasListener(ue)&&this.renderer_.dispatchRenderEvent(ue,t),!1===this.loaded_&&(this.loaded_=!0,this.dispatchEvent(new jn(Xn,this,t)))):!0===this.loaded_&&(this.loaded_=!1,this.dispatchEvent(new jn(Un,this,t))));const i=this.postRenderFunctions_;for(let e=0,n=i.length;e<n;++e)i[e](this,t);i.length=0}handleSizeChanged_(){this.getView()&&!this.getView().getAnimating()&&this.getView().resolveConstraints(0),this.render()}handleTargetChanged_(){if(this.mapBrowserEventHandler_){for(let t=0,e=this.targetChangeHandlerKeys_.length;t<e;++t)E(this.targetChangeHandlerKeys_[t]);this.targetChangeHandlerKeys_=null,this.viewport_.removeEventListener(x,this.boundHandleBrowserEvent_),this.viewport_.removeEventListener(b,this.boundHandleBrowserEvent_),this.mapBrowserEventHandler_.dispose(),this.mapBrowserEventHandler_=null,mn(this.viewport_)}if(this.targetElement_){this.resizeObserver_.unobserve(this.targetElement_);const t=this.targetElement_.getRootNode();t instanceof ShadowRoot&&this.resizeObserver_.unobserve(t.host),this.setSize(void 0)}const t=this.getTarget(),e="string"==typeof t?document.getElementById(t):t;if(this.targetElement_=e,e){e.appendChild(this.viewport_),this.renderer_||(this.renderer_=new Fn(this)),this.mapBrowserEventHandler_=new Bn(this,this.moveTolerance_);for(const t in Wn)this.mapBrowserEventHandler_.addEventListener(Wn[t],this.handleMapBrowserEvent.bind(this));this.viewport_.addEventListener(x,this.boundHandleBrowserEvent_,!1),this.viewport_.addEventListener(b,this.boundHandleBrowserEvent_,!!q&&{passive:!1});const t=this.keyboardEventTarget_?this.keyboardEventTarget_:e;this.targetChangeHandlerKeys_=[k(t,C,this.handleBrowserEvent,this),k(t,S,this.handleBrowserEvent,this)];const i=e.getRootNode();i instanceof ShadowRoot&&this.resizeObserver_.observe(i.host),this.resizeObserver_.observe(e)}else this.renderer_&&(clearTimeout(this.postRenderTimeoutHandle_),this.postRenderTimeoutHandle_=void 0,this.postRenderFunctions_.length=0,this.renderer_.dispose(),this.renderer_=null),this.animationDelayKey_&&(cancelAnimationFrame(this.animationDelayKey_),this.animationDelayKey_=void 0);this.updateSize()}handleTileChange_(){this.render()}handleViewPropertyChanged_(){this.render()}handleViewChanged_(){this.viewPropertyListenerKey_&&(E(this.viewPropertyListenerKey_),this.viewPropertyListenerKey_=null),this.viewChangeListenerKey_&&(E(this.viewChangeListenerKey_),this.viewChangeListenerKey_=null);const t=this.getView();t&&(this.updateViewportSize_(),this.viewPropertyListenerKey_=k(t,r,this.handleViewPropertyChanged_,this),this.viewChangeListenerKey_=k(t,v,this.handleViewPropertyChanged_,this),t.resolveConstraints(0)),this.render()}handleLayerGroupChanged_(){this.layerGroupPropertyListenerKeys_&&(this.layerGroupPropertyListenerKeys_.forEach(E),this.layerGroupPropertyListenerKeys_=null);const t=this.getLayerGroup();t&&(this.handleLayerAdd_(new Dn("addlayer",t)),this.layerGroupPropertyListenerKeys_=[k(t,r,this.render,this),k(t,v,this.render,this),k(t,"addlayer",this.handleLayerAdd_,this),k(t,"removelayer",this.handleLayerRemove_,this)]),this.render()}isRendered(){return!!this.frameState_}animationDelay_(){this.animationDelayKey_=void 0,this.renderFrame_(Date.now())}renderSync(){this.animationDelayKey_&&cancelAnimationFrame(this.animationDelayKey_),this.animationDelay_()}redrawText(){const t=this.getLayerGroup().getLayerStatesArray();for(let e=0,i=t.length;e<i;++e){const i=t[e].layer;i.hasRenderer()&&i.getRenderer().handleFontsChanged()}}render(){this.renderer_&&void 0===this.animationDelayKey_&&(this.animationDelayKey_=requestAnimationFrame(this.animationDelay_))}flushDeclutterItems(){const t=this.frameState_;t&&this.renderer_.flushDeclutterItems(t)}
1removeControl(t){return this.getControls().remove(t)}removeInteraction(t){return this.getInteractions().remove(t)}removeLayer(t){return this.getLayerGroup().getLayers().remove(t)}handleLayerRemove_(t){Ns(t.layer)}removeOverlay(t){return this.getOverlays().remove(t)}renderFrame_(t){const e=this.getSize(),i=this.getView(),n=this.frameState_;let s=null;if(void 0!==e&&Ds(e)&&i&&i.isDef()){const n=i.getHints(this.frameState_?this.frameState_.viewHints:void 0),o=i.getState();if(s={animate:!1,coordinateToPixelTransform:this.coordinateToPixelTransform_,declutterTree:null,extent:bt(o.center,o.resolution,o.rotation,e),index:this.frameIndex_++,layerIndex:0,layerStatesArray:this.getLayerGroup().getLayerStatesArray(),pixelRatio:this.pixelRatio_,pixelToCoordinateTransform:this.pixelToCoordinateTransform_,postRenderFunctions:[],size:e,tileQueue:this.tileQueue_,time:t,usedTiles:{},viewState:o,viewHints:n,wantedTiles:{},mapId:L(this),renderTargets:{}},o.nextCenter&&o.nextResolution){const t=isNaN(o.nextRotation)?o.rotation:o.nextRotation;s.nextExtent=bt(o.nextCenter,o.nextResolution,t,e)}}this.frameState_=s,this.renderer_.renderFrame(s),s&&(s.animate&&this.render(),Array.prototype.push.apply(this.postRenderFunctions_,s.postRenderFunctions),n&&(!this.previousExtent_||!Lt(this.previousExtent_)&&!ft(s.extent,this.previousExtent_))&&(this.dispatchEvent(new jn("movestart",this,n)),this.previousExtent_=gt(this.previousExtent_)),this.previousExtent_&&!s.viewHints[0]&&!s.viewHints[1]&&!ft(s.extent,this.previousExtent_)&&(this.dispatchEvent(new jn("moveend",this,s)),at(s.extent,this.previousExtent_))),this.dispatchEvent(new jn(Vn,this,s)),this.renderComplete_=this.hasListener(Un)||this.hasListener(Xn)||this.hasListener(ue)?!this.tileQueue_.getTilesLoading()&&!this.tileQueue_.getCount()&&!this.getLoadingOrNotReady():void 0,this.postRenderTimeoutHandle_||(this.postRenderTimeoutHandle_=setTimeout((()=>{this.postRenderTimeoutHandle_=void 0,this.handlePostRender()}),0))}setLayerGroup(t){const e=this.getLayerGroup();e&&this.handleLayerRemove_(new Dn("removelayer",e)),this.set(Kn,t)}setSize(t){this.set(Yn,t)}setTarget(t){this.set(Hn,t)}setView(t){if(!t||t instanceof Qi)return void this.set(qn,t);this.set(qn,new Qi);const e=this;t.then((function(t){e.setView(new Qi(t))}))}updateSize(){const t=this.getTargetElement();let e;if(t){const i=getComputedStyle(t),n=t.offsetWidth-parseFloat(i.borderLeftWidth)-parseFloat(i.paddingLeft)-parseFloat(i.paddingRight)-parseFloat(i.borderRightWidth),s=t.offsetHeight-parseFloat(i.borderTopWidth)-parseFloat(i.paddingTop)-parseFloat(i.paddingBottom)-parseFloat(i.borderBottomWidth);isNaN(n)||isNaN(s)||(e=[n,s],!Ds(e)&&(t.offsetWidth||t.offsetHeight||t.getClientRects().length)&&ze("No map visible because the map container's width or height are 0."))}const i=this.getSize();!e||i&&u(e,i)||(this.setSize(e),this.updateViewportSize_())}updateViewportSize_(){const t=this.getView();if(t){let e;const i=getComputedStyle(this.viewport_);i.width&&i.height&&(e=[parseInt(i.width,10),parseInt(i.height,10)]),t.setViewportSize(e)}}},$s="preload",Ws="useInterimTilesOnError",Gs=class extends en{constructor(t){t=t||{};const e=Object.assign({},t);delete e.preload,delete e.useInterimTilesOnError,super(e),this.on,this.once,this.un,this.setPreload(void 0!==t.preload?t.preload:0),this.setUseInterimTilesOnError(void 0===t.useInterimTilesOnError||t.useInterimTilesOnError)}getPreload(){return this.get($s)}setPreload(t){this.set($s,t)}getUseInterimTilesOnError(){return this.get(Ws)}setUseInterimTilesOnError(t){this.set(Ws,t)}getData(t){return super.getData(t)}},Bs=class extends P{constructor(t){super(),this.ready=!0,this.boundHandleImageChange_=this.handleImageChange_.bind(this),this.layer_=t,this.declutterExecutorGroup=null}getFeatures(t){return M()}getData(t){return null}prepareFrame(t){return M()}renderFrame(t,e){return M()}loadedTileCallback(t,e,i){t[e]||(t[e]={}),t[e][i.tileCoord.toString()]=i}createLoadedTileFinder(t,e,i){return(n,s)=>{const o=this.loadedTileCallback.bind(this,i,n);return t.forEachLoadedTile(e,n,s,o)}}forEachFeatureAtCoordinate(t,e,i,n,s){}getLayer(){return this.layer_}handleFontsChanged(){}handleImageChange_(t){const e=t.target;2!==e.getState()&&3!==e.getState()||this.renderIfReadyAndVisible()}loadImage(t){let e=t.getState();return 2!=e&&3!=e&&t.addEventListener(v,this.boundHandleImageChange_),0==e&&(t.load(),e=t.getState()),2==e}renderIfReadyAndVisible(){const t=this.getLayer();t&&t.getVisible()&&"ready"===t.getSourceState()&&t.changed()}disposeInternal(){delete this.layer_,super.disposeInternal()}},Vs=[];let Us=null;const Xs=class extends Bs{constructor(t){super(t),this.container=null,this.renderedResolution,this.tempTransform=[1,0,0,1,0,0],this.pixelTransform=[1,0,0,1,0,0],this.inversePixelTransform=[1,0,0,1,0,0],this.context=null,this.containerReused=!1,this.pixelContext_=null,this.frameState=null}
vendor: 1,643 bytes, line 1
1getImageData(t,e,i){let n;Us||(Us=pn(1,1,void 0,{willReadFrequently:!0})),Us.clearRect(0,0,1,1);try{Us.drawImage(t,e,i,1,1,0,0,1,1),n=Us.getImageData(0,0,1,1).data}catch(t){return Us=null,null}return n}getBackground(t){let e=this.getLayer().getBackground();return"function"==typeof e&&(e=e(t.viewState.resolution)),e||void 0}useContainer(t,e,i){const n=this.getLayer().getClassName();let s,o;if(t&&t.className===n&&(!i||t&&t.style.backgroundColor&&u(Kt(t.style.backgroundColor),Kt(i)))){const e=t.firstElementChild;e instanceof HTMLCanvasElement&&(o=e.getContext("2d"))}if(o&&o.canvas.style.transform===e?(this.container=t,this.context=o,this.containerReused=!0):this.containerReused?(this.container=null,this.context=null,this.containerReused=!1):this.container&&(this.container.style.backgroundColor=null),!this.container){s=document.createElement("div"),s.className=n;let t=s.style;t.position="absolute",t.width="100%",t.height="100%",o=pn();const e=o.canvas;s.appendChild(e),t=e.style,t.position="absolute",t.left="0",t.transformOrigin="top left",this.container=s,this.context=o}this.containerReused||!i||this.container.style.backgroundColor||(this.container.style.backgroundColor=i)}clipUnrotated(t,e,i){const n=Rt(i),s=Pt(i),o=Ct(i),r=wt(i);Q(e.coordinateToPixelTransform,n),Q(e.coordinateToPixelTransform,s),Q(e.coordinateToPixelTransform,o),Q(e.coordinateToPixelTransform,r);const a=this.inversePixelTransform;Q(a,n),Q(a,s),Q(a,o),Q(a,r),t.save(),t.beginPath(),t.moveTo(Math.round(n[0]),Math.round(n[1])),t.lineTo(Math.round(s[0]),Math.round(s[1])),t.lineTo(Math.round(o[0]),Math.round(o[1])),t.lineTo(Math.round(r[0]),Math.round(r[1])
1),t.clip()}dispatchRenderEvent_(t,e,i){const n=this.getLayer();if(n.hasListener(t)){const s=new on(t,this.inversePixelTransform,i,e);n.dispatchEvent(s)}}preRender(t,e){this.frameState=e,this.dispatchRenderEvent_(he,t,e)}postRender(t,e){this.dispatchRenderEvent_(de,t,e)}getRenderTransform(t,e,i,n,s,o,r){const a=s/2,l=o/2,h=n/e,d=-h,c=-t[0]+r,u=-t[1];return tt(this.tempTransform,a,l,h,d,-i,c,u)}disposeInternal(){delete this.frameState,super.disposeInternal()}},Ks=class extends y{constructor(t,e,i){super(),i=i||{},this.tileCoord=t,this.state=e,this.interimTile=null,this.key="",this.transition_=void 0===i.transition?250:i.transition,this.transitionStarts_={},this.interpolate=!!i.interpolate}changed(){this.dispatchEvent(v)}release(){3===this.state&&this.setState(4)}getKey(){return this.key+"/"+this.tileCoord}getInterimTile(){if(!this.interimTile)return this;let t=this.interimTile;do{if(2==t.getState())return this.transition_=0,t;t=t.interimTile}while(t);return this}refreshInterimChain(){if(!this.interimTile)return;let t=this.interimTile,e=this;do{if(2==t.getState()){t.interimTile=null;break}1==t.getState()?e=t:0==t.getState()?e.interimTile=t.interimTile:e=t,t=e.interimTile}while(t)}getTileCoord(){return this.tileCoord}getState(){return this.state}setState(t){if(3!==this.state&&this.state>t)throw new Error("Tile load sequence violation");this.state=t,this.changed()}load(){M()}getAlpha(t,e){if(!this.transition_)return 1;let i=this.transitionStarts_[t];if(i){if(-1===i)return 1}else i=e,this.transitionStarts_[t]=i;const n=e-i+1e3/60;return n>=this.transition_?1:fi(n/this.transition_)}inTransition(t){return!!this.transition_&&-1!==this.transitionStarts_[t]}endTransition(t){this.transition_&&(this.transitionStarts_[t]=-1)}};function Ys(t,e,i){const n=t;let s=!0,o=!1,r=!1;const a=[I(n,"load",(function(){r=!0,o||e()}))];return n.src&&H?(o=!0,n.decode().then((function(){s&&e()})).catch((function(t){s&&(r?e():i())}))):a.push(I(n,"error",i)),function(){s=!1,a.forEach(E)}}const Hs=class extends Ks{constructor(t,e,i,n,s,o){super(t,e,o),this.crossOrigin_=n,this.src_=i,this.key=i,this.image_=new Image,null!==n&&(this.image_.crossOrigin=n),this.unlisten_=null,this.tileLoadFunction_=s}getImage(){return this.image_}setImage(t){this.image_=t,this.state=2,this.unlistenImage_(),this.changed()}handleImageError_(){this.state=3,this.unlistenImage_(),this.image_=function(){const t=pn(1,1);return t.fillStyle="rgba(0,0,0,0)",t.fillRect(0,0,1,1),t.canvas}(),this.changed()}handleImageLoad_(){const t=this.image_;t.naturalWidth&&t.naturalHeight?this.state=2:this.state=4,this.unlistenImage_(),this.changed()}load(){3==this.state&&(this.state=0,this.image_=new Image,null!==this.crossOrigin_&&(this.image_.crossOrigin=this.crossOrigin_)),0==this.state&&(this.state=1,this.changed(),this.tileLoadFunction_(this,this.src_),this.unlisten_=Ys(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this)))}unlistenImage_(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)}};let qs;const Js=[];function Qs(t,e,i,n,s){t.beginPath(),t.moveTo(0,0),t.lineTo(e,i),t.lineTo(n,s),t.closePath(),t.save(),t.clip(),t.fillRect(0,0,Math.max(e,n)+1,Math.max(i,s)),t.restore()}function to(t,e){return Math.abs(t[4*e]-210)>2||Math.abs(t[4*e+3]-191.25)>2}function eo(t,e,i,n){const s=qe(i,e,t);let o=Ve(e,n,i);const r=e.getMetersPerUnit();void 0!==r&&(o*=r);const a=t.getMetersPerUnit();void 0!==a&&(o/=a);const l=t.getExtent();if(!l||ht(l,s)){const e=Ve(t,o,s)/o;isFinite(e)&&e>0&&(o/=e)}return o}const io=class extends Ks{constructor(t,e,i,n,s,o,r,a,l,h,d,c){super(s,0,{interpolate:!!c}),this.renderEdges_=void 0!==d&&d,this.pixelRatio_=r,this.gutter_=a,this.canvas_=null,this.sourceTileGrid_=e,this.targetTileGrid_=n,this.wrappedTileCoord_=o||s,this.sourceTiles_=[],this.sourcesListenerKeys_=null,this.sourceZ_=0;const u=n.getTileCoordExtent(this.wrappedTileCoord_),p=this.targetTileGrid_.getExtent();let g=this.sourceTileGrid_.getExtent();const f=p?Et(u,p):u;if(0===xt(f))return void(this.state=4);const m=t.getExtent();m&&(g=g?Et(g,m):m);const _=n.getResolution(this.wrappedTileCoord_[0]),y=function(t,e,
1i,n){const s=St(i);let o=eo(t,e,s,n);return(!isFinite(o)||o<=0)&&vt(i,(function(i){return o=eo(t,e,i,n),isFinite(o)&&o>0})),o}(t,i,f,_);if(!isFinite(y)||y<=0)return void(this.state=4);const v=void 0!==h?h:.5;if(this.triangulation_=new class{constructor(t,e,i,n,s,o){this.sourceProj_=t,this.targetProj_=e;let r={};const a=He(this.targetProj_,this.sourceProj_);this.transformInv_=function(t){const e=t[0]+"/"+t[1];return r[e]||(r[e]=a(t)),r[e]},this.maxSourceExtent_=n,this.errorThresholdSquared_=s*s,this.triangles_=[],this.wrapsXInSource_=!1,this.canWrapXInSource_=this.sourceProj_.canWrapX()&&!!n&&!!this.sourceProj_.getExtent()&&Mt(n)>=Mt(this.sourceProj_.getExtent()),this.sourceWorldWidth_=this.sourceProj_.getExtent()?Mt(this.sourceProj_.getExtent()):null,this.targetWorldWidth_=this.targetProj_.getExtent()?Mt(this.targetProj_.getExtent()):null;const l=Rt(i),h=Pt(i),d=Ct(i),c=wt(i),u=this.transformInv_(l),p=this.transformInv_(h),g=this.transformInv_(d),f=this.transformInv_(c),m=10+(o?Math.max(0,Math.ceil(Math.log2(xt(i)/(o*o*256*256)))):0);if(this.addQuad_(l,h,d,c,u,p,g,f,m),this.wrapsXInSource_){let t=1/0;this.triangles_.forEach((function(e,i,n){t=Math.min(t,e.source[0][0],e.source[1][0],e.source[2][0])})),this.triangles_.forEach((e=>{if(Math.max(e.source[0][0],e.source[1][0],e.source[2][0])-t>this.sourceWorldWidth_/2){const i=[[e.source[0][0],e.source[0][1]],[e.source[1][0],e.source[1][1]],[e.source[2][0],e.source[2][1]]];i[0][0]-t>this.sourceWorldWidth_/2&&(i[0][0]-=this.sourceWorldWidth_),i[1][0]-t>this.sourceWorldWidth_/2&&(i[1][0]-=this.sourceWorldWidth_),i[2][0]-t>this.sourceWorldWidth_/2&&(i[2][0]-=this.sourceWorldWidth_);const n=Math.min(i[0][0],i[1][0],i[2][0]);Math.max(i[0][0],i[1][0],i[2][0])-n<this.sourceWorldWidth_/2&&(e.source=i)}}))}r={}}addTriangle_(t,e,i,n,s,o){this.triangles_.push({source:[n,s,o],target:[t,e,i]})}addQuad_(t,e,i,n,s,o,r,a,l){const h=ot([s,o,r,a]),d=this.sourceWorldWidth_?Mt(h)/this.sourceWorldWidth_:null,c=this.sourceWorldWidth_,u=this.sourceProj_.canWrapX()&&d>.5&&d<1;let p=!1;if(l>0&&(this.targetProj_.isGlobal()&&this.targetWorldWidth_&&(p=Mt(ot([t,e,i,n]))/this.targetWorldWidth_>.25||p),!u&&this.sourceProj_.isGlobal()&&d&&(p=d>.25||p)),!p&&this.maxSourceExtent_&&isFinite(h[0])&&isFinite(h[1])&&isFinite(h[2])&&isFinite(h[3])&&!At(h,this.maxSourceExtent_))return;let g=0;if(!(p||isFinite(s[0])&&isFinite(s[1])&&isFinite(o[0])&&isFinite(o[1])&&isFinite(r[0])&&isFinite(r[1])&&isFinite(a[0])&&isFinite(a[1])))if(l>0)p=!0;else if(g=(isFinite(s[0])&&isFinite(s[1])?0:8)+(isFinite(o[0])&&isFinite(o[1])?0:4)+(isFinite(r[0])&&isFinite(r[1])?0:2)+(isFinite(a[0])&&isFinite(a[1])?0:1),1!=g&&2!=g&&4!=g&&8!=g)return;if(l>0){if(!p){const e=[(t[0]+i[0])/2,(t[1]+i[1])/2],n=this.transformInv_(e);let o;o=u?(zt(s[0],c)+zt(r[0],c))/2-zt(n[0],c):(s[0]+r[0])/2-n[0];const a=(s[1]+r[1])/2-n[1];p=o*o+a*a>this.errorThresholdSquared_}if(p){if(Math.abs(t[0]-i[0])<=Math.abs(t[1]-i[1])){const h=[(e[0]+i[0])/2,(e[1]+i[1])/2],d=this.transformInv_(h),c=[(n[0]+t[0])/2,(n[1]+t[1])/2],u=this.transformInv_(c);this.addQuad_(t,e,h,c,s,o,d,u,l-1),this.addQuad_(c,h,i,n,u,d,r,a,l-1)}else{const h=[(t[0]+e[0])/2,(t[1]+e[1])/2],d=this.transformInv_(h),c=[(i[0]+n[0])/2,(i[1]+n[1])/2],u=this.transformInv_(c);this.addQuad_(t,h,c,n,s,d,u,a,l-1),this.addQuad_(h,e,i,c,d,o,r,u,l-1)}return}}if(u){if(!this.canWrapXInSource_)return;this.wrapsXInSource_=!0}0==(11&g)&&this.addTriangle_(t,i,n,s,r,a),0==(14&g)&&this.addTriangle_(t,i,e,s,r,o),g&&(0==(13&g)&&this.addTriangle_(e,n,t,o,a,s),0==(7&g)&&this.addTriangle_(e,n,i,o,a,r))}calculateSourceExtent(){const t=[1/0,1/0,-1/0,-1/0];return this.triangles_.forEach((function(e,i,n){const s=e.source;mt(t,s[0]),mt(t,s[1]),mt(t,s[2])})),t}getTriangles(){return this.triangles_}}(t,i,f,g,y*v,_),0===this.triangulation_.getTriangles().length)return void(this.state=4);this.sourceZ_=e.getZForResolution(y);let x=this.triangulation_.calculateSourceExtent();if(g&&(t.canWrapX()?(x[1]=Ft(x[1],g[1],g[3]),x[3]=Ft(x[3],g[1],g[3])):x=Et(x,g)),xt(x)){const t=e.getTileRangeForExtentAndZ(x,this.sourceZ_);for(let e=t.minX;e<=t.maxX;e++)for(let i=t.minY;i<=t.maxY;i++){const t=l(this.sourceZ_,e,i,r);t&&this.sourceTiles_.push(t)}0===this.sourceTiles_.length&&(this.state=4)}else this.state=4}getImage(){return this.canvas_}reproject_(){const t=[];if(this.sourceTiles_.forEach((e=>
1{e&&2==e.getState()&&t.push({extent:this.sourceTileGrid_.getTileCoordExtent(e.tileCoord),image:e.getImage()})})),this.sourceTiles_.length=0,0===t.length)this.state=3;else{const e=this.wrappedTileCoord_[0],i=this.targetTileGrid_.getTileSize(e),n="number"==typeof i?i:i[0],s="number"==typeof i?i:i[1],o=this.targetTileGrid_.getResolution(e),r=this.sourceTileGrid_.getResolution(this.sourceZ_),a=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_);this.canvas_=function(t,e,i,n,s,o,r,a,l,h,d,c){const u=pn(Math.round(i*t),Math.round(i*e),Js);if(c||(u.imageSmoothingEnabled=!1),0===l.length)return u.canvas;function p(t){return Math.round(t*i)/i}u.scale(i,i),u.globalCompositeOperation="lighter";const g=[1/0,1/0,-1/0,-1/0];l.forEach((function(t,e,i){var n,s;n=g,(s=t.extent)[0]<n[0]&&(n[0]=s[0]),s[2]>n[2]&&(n[2]=s[2]),s[1]<n[1]&&(n[1]=s[1]),s[3]>n[3]&&(n[3]=s[3])}));const f=Mt(g),m=It(g),_=pn(Math.round(i*f/n),Math.round(i*m/n),Js);c||(_.imageSmoothingEnabled=!1);const y=i/n;l.forEach((function(t,e,i){const n=t.extent[0]-g[0],s=-(t.extent[3]-g[3]),o=Mt(t.extent),r=It(t.extent);t.image.width>0&&t.image.height>0&&_.drawImage(t.image,h,h,t.image.width-2*h,t.image.height-2*h,n*y,s*y,o*y,r*y)}));const v=Rt(r);
1return a.getTriangles().forEach((function(t,e,s){const r=t.source,a=t.target;let l=r[0][0],h=r[0][1],d=r[1][0],f=r[1][1],m=r[2][0],y=r[2][1];const x=p((a[0][0]-v[0])/o),w=p(-(a[0][1]-v[1])/o),C=p((a[1][0]-v[0])/o),S=p(-(a[1][1]-v[1])/o),T=p((a[2][0]-v[0])/o),b=p(-(a[2][1]-v[1])/o),k=l,I=h;l=0,h=0,d-=k,f-=I,m-=k,y-=I;const E=function(t){const e=t.length;for(let i=0;i<e;i++){let n=i,s=Math.abs(t[i][i]);for(let o=i+1;o<e;o++){const e=Math.abs(t[o][i]);e>s&&(s=e,n=o)}if(0===s)return null;const o=t[n];t[n]=t[i],t[i]=o;for(let n=i+1;n<e;n++){const s=-t[n][i]/t[i][i];for(let o=i;o<e+1;o++)i==o?t[n][o]=0:t[n][o]+=s*t[i][o]}}const i=new Array(e);for(let n=e-1;n>=0;n--){i[n]=t[n][e]/t[n][n];for(let s=n-1;s>=0;s--)t[s][e]-=t[s][n]*i[n]}return i}([[d,f,0,0,C-x],[m,y,0,0,T-x],[0,0,d,f,S-w],[0,0,m,y,b-w]]);if(E){if(u.save(),u.beginPath(),function(){if(void 0===qs){const t=pn(6,6,Js);t.globalCompositeOperation="lighter",t.fillStyle="rgba(210, 0, 0, 0.75)",Qs(t,4,5,4,0),Qs(t,4,5,0,5);const e=t.getImageData(0,0,3,3).data;qs=to(e,0)||to(e,4)||to(e,8),gn(t),Js.push(t.canvas)}return qs}()||!c){u.moveTo(C,S);const t=4,e=x-C,i=w-S;for(let n=0;n<t;n++)u.lineTo(C+p((n+1)*e/t),S+p(n*i/(t-1))),n!=t-1&&u.lineTo(C+p((n+1)*e/t),S+p((n+1)*i/(t-1)));u.lineTo(T,b)}else u.moveTo(C,S),u.lineTo(x,w),u.lineTo(T,b);u.clip(),u.transform(E[0],E[2],E[1],E[3],x,w),u.translate(g[0]-k,g[3]-I),u.scale(n/i,-n/i),u.drawImage(_.canvas,0,0),u.restore()}})),gn(_),Js.push(_.canvas),d&&(u.save(),u.globalCompositeOperation="source-over",u.strokeStyle="black",u.lineWidth=1,a.getTriangles().forEac
1h((function(t,e,i){const n=t.target,s=(n[0][0]-v[0])/o,r=-(n[0][1]-v[1])/o,a=(n[1][0]-v[0])/o,l=-(n[1][1]-v[1])/o,h=(n[2][0]-v[0])/o,d=-(n[2][1]-v[1])/o;u.beginPath(),u.moveTo(a,l),u.lineTo(s,r),u.lineTo(h,d),u.closePath(),u.stroke()})),u.restore()),u.canvas}(n,s,this.pixelRatio_,r,this.sourceTileGrid_.getExtent(),o,a,this.triangulation_,t,this.gutter_,this.renderEdges_,this.interpolate),this.state=2}this.changed()}load(){if(0==this.state){this.state=1,this.changed();let t=0;this.sourcesListenerKeys_=[],this.sourceTiles_.forEach((e=>{const i=e.getState();if(0==i||1==i){t++;const i=k(e,v,(function(n){const s=e.getState();2!=s&&3!=s&&4!=s||(E(i),t--,0===t&&(this.unlistenSources_(),this.reproject_()))}),this);this.sourcesListenerKeys_.push(i)}})),0===t?setTimeout(this.reproject_.bind(this),0):this.sourceTiles_.forEach((function(t,e,i){0==t.getState()&&t.load()}))}}unlistenSources_(){this.sourcesListenerKeys_.forEach(E),this.sourcesListenerKeys_=null}release(){this.canvas_&&(gn(this.canvas_.getContext("2d")),Js.push(this.canvas_),this.canvas_=null),super.release()}};class no{constructor(t,e,i,n){this.minX=t,this.maxX=e,this.minY=i,this.maxY=n}contains(t){return this.containsXY(t[1],t[2])}containsTileRange(t){return this.minX<=t.minX&&t.maxX<=this.maxX&&this.minY<=t.minY&&t.maxY<=this.maxY}containsXY(t,e){return this.minX<=t&&t<=this.maxX&&this.minY<=e&&e<=this.maxY}equals(t){return this.minX==t.minX&&this.minY==t.minY&&this.maxX==t.maxX&&this.maxY==t.maxY}extend(t){t.minX<this.minX&&(this.minX=t.minX),t.maxX>this.maxX&&(this.maxX=t.maxX),t.minY<this.minY&&(this.minY=t.minY),t.maxY>this.maxY&&(this.maxY=t.maxY)}
1getHeight(){return this.maxY-this.minY+1}getSize(){return[this.getWidth(),this.getHeight()]}getWidth(){return this.maxX-this.minX+1}intersects(t){return this.minX<=t.maxX&&this.maxX>=t.minX&&this.minY<=t.maxY&&this.maxY>=t.minY}}function so(t,e,i,n,s){return void 0!==s?(s.minX=t,s.maxX=e,s.minY=i,s.maxY=n,s):new no(t,e,i,n)}const oo=no,ro=class extends Xs{constructor(t){super(t),this.extentChanged=!0,this.renderedExtent_=null,this.renderedPixelRatio,this.renderedProjection=null,this.renderedRevision,this.renderedTiles=[],this.newTiles_=!1,this.tmpExtent=[1/0,1/0,-1/0,-1/0],this.tmpTileRange_=new oo(0,0,0,0)}isDrawableTile(t){const e=this.getLayer(),i=t.getState(),n=e.getUseInterimTilesOnError();return 2==i||4==i||3==i&&!n}getTile(t,e,i,n){const s=n.pixelRatio,o=n.viewState.projection,r=this.getLayer();let a=r.getSource().getTile(t,e,i,s,o);return 3==a.getState()&&r.getUseInterimTilesOnError()&&r.getPreload()>0&&(this.newTiles_=!0),this.isDrawableTile(a)||(a=a.getInterimTile()),a}getData(t){const e=this.frameState;if(!e)return null;const i=this.getLayer(),n=Q(e.pixelToCoordinateTransform,t.slice()),s=i.getExtent();if(s&&!ht(s,n))return null;const o=e.pixelRatio,r=e.viewState.projection,a=e.viewState,l=i.getRenderSource(),h=l.getTileGridForProjection(a.projection),d=l.getTilePixelRatio(e.pixelRatio);for(let t=h.getZForResolution(a.resolution);t>=h.getMinZoom();--t){const e=h.getTileCoordForCoordAndZ(n,t),i=l.getTile(t,e[1],e[2],o,r);if(!(i instanceof Hs||i instanceof io)||i instanceof io&&4===i.getState())return null;if(2!==i.getState())continue;const s=h.getOrigin(t),c=Zs(h.getTileSize(t)),u=h.getResolution(t),p=Math.floor(d*((n[0]-s[0])/u-e[1]*c[0])),g=Math.floor(d*((s[1]-n[1])/u-e[2]*c[1])),f=Math.round(d*l.getGutterForProjection(a.projection));return this.getImageData(i.getImage(),p+f,g+f)}return null}loadedTileCallback(t,e,i){return!!this.isDrawableTile(i)&&super.loadedTileCallback(t,e,i)}prepareFrame(t){return!!this.getLayer().getSource()}renderFrame(t,e){const i=t.layerStatesArray[t.layerIndex],n=t.viewState,s=n.projection,o=n.resolution,r=n.center,a=n.rotation,h=t.pixelRatio,d=this.getLayer(),c=d.getSource(),u=c.getRevision(),p=c.getTileGridForProjection(s),g=p.getZForResolution(o,c.zDirection),f=p.getResolution(g);let m=t.extent;const _=t.viewState.resolution,y=c.getTilePixelRatio(h),v=Math.round(Mt(m)/_*h),x=Math.round(It(m)/_*h),w=i.extent&&ni(i.extent);w&&(m=Et(m,ni(i.extent)));const C=f*v/2/y,S=f*x/2/y,T=[r[0]-C,r[1]-S,r[0]+C,r[1]+S],b=p.getTileRangeForExtentAndZ(m,g),k={};k[g]={};const I=this.createLoadedTileFinder(c,s,k),E=this.tmpExtent,R=this.tmpTileRange_;this.newTiles_=!1;const P=a?kt(n.center,_,a,t.size):void 0;for(let e=b.minX;e<=b.maxX;++e)for(let n=b.minY;n<=b.maxY;++n){if(a&&!p.tileCoordIntersectsViewport([g,e,n],P))continue;const s=this.getTile(g,e,n,t);if(this.isDrawableTile(s)){const e=L(this);if(2==s.getState()){k[g][s.tileCoord.toString()]=s;let t=s.inTransition(e);t&&1!==i.opacity&&(s.endTransition(e),t=!1),this.newTiles_||!t&&this.renderedTiles.includes(s)||(this.newTiles_=!0)}if(1===s.getAlpha(e,t.time))continue}const o=p.getTileCoordChildTileRange(s.tileCoord,R,E);let r=!1;o&&(r=I(g+1,o)),r||p.forEachTileCoordParentTileRange(s.tileCoord,I,R,E)}const M=f/o*h/y;tt(this.pixelTransform,t.size[0]/2,t.size[1]/2,1/h,1/h,a,-v/2,-x/2);const A=nt(this.pixelTransform);this.useContainer(e,A,this.getBackground(t));const O=this.context,F=O.canvas;et(this.inversePixelTransform,this.pixelTransform),tt(this.tempTransform,v/2,x/2,M,M,0,-v/2,-x/2),F.width!=v||F.height!=x?(F.width=v,F.height=x):this.containerReused||O.clearRect(0,0,v,x),w&&this.clipUnrotated(O,t,w),c.getInterpolate()||(O.imageSmoothingEnabled=!1),this.preRender(O,t),this.renderedTiles.length=0;let D,Z,N,z=Object.keys(k).map(Number);z.sort(l),1!==i.opacity||this.containerReused&&!c.getOpaque(t.viewState.projection)?(D=[],Z=[]):z=z.reverse();for(let e=z.length-1;e>=0;--e){const i=z[e],n=c.getTilePixelSize(i,h,s),o=p.getResolution(i)/f,r=n[0]*o*M,a=n[1]*o*M,l=p.getTileCoordForCoordAndZ(Rt(T),i),d=p.getTileCoordExtent(l),u=Q(this.tempTransform,[y*(d[0]-T[0])/f,y*(T[3]-d[3])/f]),m=y*c.getGutterForProjection(s),_=k[i];for(const e in _){const n=_[e],s=n.tileCoord,o=l[1]-s[1],h=Math.round(u[0]-(o-1)*r),d=l[2]-s[2],p=Math.round(u[1]-(d-1)*a),f=Math.round(u[0]-o*r),y=Math.round(u[1]-d*a),v=h-f,x=p-y,w=g===i,C=w&&1!==n.getAlpha(L(this),t.time);let S=!1;if(!C)if(D){N=[f,y,f+v,y,f+v,y+x,f,y+x];for(let t=0,e=D.length;t<e;++t)if(g!==i&&i<Z[t]){const e=D[t];At([f,y,f+v,y+x],[e[0],e[3],e[4],e[7]])&&(S||(O.save(),S=!0),O.beginPath(),O.moveTo(N[0],N[1]),O.lineTo(N[2],N[3]),O.lineTo(N[4],N[5]),O.lineTo(N[6],N[7]),O.moveTo(e[6],e[7]),O.lineTo(e[4],e[5]),O.lineTo(e[2],e[3]),O.lineTo(e[0],e[1]),O.clip())}D.push(N),Z.push(i)}else O.clearRect(f,y,v,x);
1this.drawTileImage(n,t,f,y,v,x,m,w),D&&!C?(S&&O.restore(),this.renderedTiles.unshift(n)):this.renderedTiles.push(n),this.updateUsedTiles(t.usedTiles,c,n)}}return this.renderedRevision=u,this.renderedResolution=f,this.extentChanged=!this.renderedExtent_||!ft(this.renderedExtent_,T),this.renderedExtent_=T,this.renderedPixelRatio=h,this.renderedProjection=s,this.manageTilePyramid(t,c,p,h,s,m,g,d.getPreload()),this.scheduleExpireCache(t,c),this.postRender(O,t),i.extent&&O.restore(),O.imageSmoothingEnabled=!0,A!==F.style.transform&&(F.style.transform=A),this.container}drawTileImage(t,e,i,n,s,o,r,a){const l=this.getTileImage(t);if(!l)return;const h=L(this),d=e.layerStatesArray[e.layerIndex],c=d.opacity*(a?t.getAlpha(h,e.time):1),u=c!==this.context.globalAlpha;u&&(this.context.save(),this.context.globalAlpha=c),this.context.drawImage(l,r,r,l.width-2*r,l.height-2*r,i,n,s,o),u&&this.context.restore(),c!==d.opacity?e.animate=!0:a&&t.endTransition(h)}getImage(){const t=this.context;return t?t.canvas:null}getTileImage(t){return t.getImage()}scheduleExpireCache(t,e){if(e.canExpireCache()){const i=function(t,e,i){const n=L(t);n in i.usedTiles&&t.expireCache(i.viewState.projection,i.usedTiles[n])}.bind(null,e);t.postRenderFunctions.push(i)}}updateUsedTiles(t,e,i){const n=L(e);n in t||(t[n]={}),t[n][i.getKey()]=!0}manageTilePyramid(t,e,i,n,s,o,r,a,l){const h=L(e);h in t.wantedTiles||(t.wantedTiles[h]={});const d=t.wantedTiles[h],c=t.tileQueue,u=i.getMinZoom(),p=t.viewState.rotation,g=p?kt(t.viewState.center,t.viewState.resolution,p,t.size):void 0;let f,m,_,y,v,x,w=0;for(x=u;x<=r;++x)for(m=i.getTileRangeForExtentAndZ(o,x,m),_=i.getResolution(x),y=m.minX;y<=m.maxX;++y)for(v=m.minY;v<=m.maxY;++v)p&&!i.tileCoordIntersectsViewport([x,y,v],g)||(r-x<=a?(++w,f=e.getTile(x,y,v,n,s),0==f.getState()&&(d[f.getKey()]=!0,c.isKeyQueued(f.getKey())||c.enqueue([f,h,i.getTileCoordCenter(f.tileCoord),_])),void 0!==l&&l(f)):e.useTile(x,y,v,s));e.updateCacheSize(w,s)}},ao=class extends Gs{constructor(t){super(t)}createRenderer(){return new ro(this)}},lo=class{constructor(t){this.highWaterMark=void 0!==t?t:2048,this.count_=0,this.entries_={},this.oldest_=null,this.newest_=null}canExpireCache(){return this.highWaterMark>0&&this.getCount()>this.highWaterMark}expireCache(t){for(;this.canExpireCache();)this.pop()}clear(){this.count_=0,this.entries_={},this.oldest_=null,this.newest_=null}containsKey(t){return this.entries_.hasOwnProperty(t)}forEach(t){let e=this.oldest_;for(;e;)t(e.value_,e.key_,this),e=e.newer}get(t,e){const i=this.entries_[t];return J(void 0!==i,15),i===this.newest_||(i===this.oldest_?(this.oldest_=this.oldest_.newer,this.oldest_.older=null):(i.newer.older=i.older,i.older.newer=i.newer),i.newer=null,i.older=this.newest_,this.newest_.newer=i,this.newest_=i),i.value_}remove(t){const e=this.entries_[t];return J(void 0!==e,15),e===this.newest_?(this.newest_=e.older,this.newest_&&(this.newest_.newer=null)):e===this.oldest_?(this.oldest_=e.newer,this.oldest_&&(this.oldest_.older=null)):(e.newer.older=e.older,e.older.newer=e.newer),delete this.entries_[t],--this.count_,e.value_}getCount(){return this.count_}getKeys(){const t=new Array(this.count_);let e,i=0;for(e=this.newest_;e;e=e.older)t[i++]=e.key_;return t}getValues(){const t=new Array(this.count_);let e,i=0;for(e=this.newest_;e;e=e.older)t[i++]=e.value_;return t}peekLast(){return this.oldest_.value_}peekLastKey(){return this.oldest_.key_}peekFirstKey(){return this.newest_.key_}peek(t){if(this.containsKey(t))return this.entries_[t].value_}pop(){const t=this.oldest_;return delete this.entries_[t.key_],t.newer&&(t.newer.older=null),this.oldest_=t.newer,this.oldest_||(this.newest_=null),--this.count_,t.value_}replace(t,e){this.get(t),this.entries_[t].value_=e}set(t,e){J(!(t in this.entries_),16);const i={key_:t,newer:null,older:this.newest_,value_:e};this.newest_?this.newest_.newer=i:this.oldest_=i,this.newest_=i,this.entries_[t]=i,++this.count_}setSize(t){this.highWaterMark=t}};function ho(t,e,i,n){return void 0!==n?(n[0]=t,n[1]=e,n[2]=i,n):[t,e,i]}function co(t,e,i){return t+"/"+e+"/"+i}function uo(t){return co(t[0],t[1],t[2])}const po=class extends lo{clear(){for(;this.getCount()>0;)this.pop().release();super.clear()}expireCache(t){for(;this.canExpireCache()&&!(this.peekLast().getKey()in t);)this.pop().release()}pruneExceptNewestZ(){if(0===this.getCount())return;const t=this.peekFirstKey().split("/").map(Number)[0];this.forEach((e=>
1{e.tileCoord[0]!==t&&(this.remove(uo(e.tileCoord)),e.release())}))}};function go(t){return t?Array.isArray(t)?function(e){return t}:"function"==typeof t?t:function(e){return[t]}:null}const fo=class extends F{constructor(t){super(),this.projection=Be(t.projection),this.attributions_=go(t.attributions),this.attributionsCollapsible_=void 0===t.attributionsCollapsible||t.attributionsCollapsible,this.loading=!1,this.state_=void 0!==t.state?t.state:"ready",this.wrapX_=void 0!==t.wrapX&&t.wrapX,this.interpolate_=!!t.interpolate,this.viewResolver=null,this.viewRejector=null;const e=this;this.viewPromise_=new Promise((function(t,i){e.viewResolver=t,e.viewRejector=i}))}getAttributions(){return this.attributions_}getAttributionsCollapsible(){return this.attributionsCollapsible_}getProjection(){return this.projection}getResolutions(t){return null}getView(){return this.viewPromise_}getState(){return this.state_}getWrapX(){return this.wrapX_}getInterpolate(){return this.interpolate_}refresh(){this.changed()}setAttributions(t){this.attributions_=go(t),this.changed()}setState(t){this.state_=t,this.changed()}},mo=[0,0,0],_o=class{constructor(t){let e;if(this.minZoom=void 0!==t.minZoom?t.minZoom:0,this.resolutions_=t.resolutions,J(function(t,e,i){const n=function(t,e){return e-t}||l;return t.every((function(e,i){if(0===i)return!0;const s=n(t[i-1],e);return!(s>0||0===s)}))}(this.resolutions_),17),!t.origins)for(let t=0,i=this.resolutions_.length-1;t<i;++t)if(e){if(this.resolutions_[t]/this.resolutions_[t+1]!==e){e=void 0;break}}else e=this.resolutions_[t]/this.resolutions_[t+1];this.zoomFactor_=e,this.maxZoom=this.resolutions_.length-1,this.origin_=void 0!==t.origin?t.origin:null,this.origins_=null,void 0!==t.origins&&(this.origins_=t.origins,J(this.origins_.length==this.resolutions_.length,20));const i=t.extent;void 0===i||this.origin_||this.origins_||(this.origin_=Rt(i)),J(!this.origin_&&this.origins_||this.origin_&&!this.origins_,18),this.tileSizes_=null,void 0!==t.tileSizes&&(this.tileSizes_=t.tileSizes,J(this.tileSizes_.length==this.resolutions_.length,19)),this.tileSize_=void 0!==t.tileSize?t.tileSize:this.tileSizes_?null:fe,J(!this.tileSize_&&this.tileSizes_||this.tileSize_&&!this.tileSizes_,22),this.extent_=void 0!==i?i:null,this.fullTileRanges_=null,this.tmpSize_=[0,0],this.tmpExtent_=[0,0,0,0],void 0!==t.sizes?this.fullTileRanges_=t.sizes.map((function(t,e){const n=new oo(Math.min(0,t[0]),Math.max(t[0]-1,-1),Math.min(0,t[1]),Math.max(t[1]-1,-1));if(i){const t=this.getTileRangeForExtentAndZ(i,e);n.minX=Math.max(t.minX,n.minX),n.maxX=Math.min(t.maxX,n.maxX),n.minY=Math.max(t.minY,n.minY),n.maxY=Math.min(t.maxY,n.maxY)}return n}),this):i&&this.calculateTileRanges_(i)}forEachTileCoord(t,e,i){const n=this.getTileRangeForExtentAndZ(t,e);for(let t=n.minX,s=n.maxX;t<=s;++t)for(let s=n.minY,o=n.maxY;s<=o;++s)i([e,t,s])}forEachTileCoordParentTileRange(t,e,i,n){let s,o,r,a=null,l=t[0]-1;for(2===this.zoomFactor_?(o=t[1],r=t[2]):a=this.getTileCoordExtent(t,n);l>=this.minZoom;){if(2===this.zoomFactor_?(o=Math.floor(o/2),r=Math.floor(r/2),s=so(o,o,r,r,i)):s=this.getTileRangeForExtentAndZ(a,l,i),e(l,s))return!0;--l}return!1}getExtent(){return this.extent_}getMaxZoom(){return this.maxZoom}getMinZoom(){return this.minZoom}getOrigin(t){return this.origin_?this.origin_:this.origins_[t]}getResolution(t){return this.resolutions_[t]}getResolutions(){return this.resolutions_}getTileCoordChildTileRange(t,e,i){if(t[0]<this.maxZoom){if(2===this.zoomFactor_){const i=2*t[1],n=2*t[2];return so(i,i+1,n,n+1,e)}const n=this.getTileCoordExtent(t,i||this.tmpExtent_);return this.getTileRangeForExtentAndZ(n,t[0]+1,e)}return null}getTileRangeForTileCoordAndZ(t,e,i){if(e>this.maxZoom||e<this.minZoom)return null;const n=t[0],s=t[1],o=t[2];if(e===n)return so(s,o,s,o,i);if(this.zoomFactor_){const t=Math.pow(this.zoomFactor_,e-n),r=Math.floor(s*t),a=Math.floor(o*t);return e<n?so(r,r,a,a,i):so(r,Math.floor(t*(s+1))-1,a,Math.floor(t*(o+1))-1,i)}const r=this.getTileCoordExtent(t,this.tmpExtent_);return this.getTileRangeForExtentAndZ(r,e,i)}getTileRangeForExtentAndZ(t,e,i){this.getTileCoordForXYAndZ_(t[0],t[3],e,!1,mo);const n=mo[1],s=mo[2];return this.getTileCoordForXYAndZ_(t[2],t[1],e,!0,mo),so(n,mo[1],s,mo[2],i)}getTileCoordCenter(t){const e=this.getOrigin(t[0]),i=this.getResolution(t[0]),n=Zs(this.getTileSize(t[0]),this.tmpSize_);return[e[0]+(t[1]+.5)*n[0]*i,e[1]-(t[2]+.5)*n[1]*i]}getTileCoordExtent(t,e){const i=this.getOrigin(t[0]),n=this.getResolution(t[0]),s=Zs(this.getTileSize(t[0]),this.tmpSize_),o=i[0]+t[1]*s[0]*n,r=i[1]-(t[2]+1)*s[1]*n;return pt(o,r,o+s[0]*n,r+s[1]*n,e)}
1getTileCoordForCoordAndResolution(t,e,i){return this.getTileCoordForXYAndResolution_(t[0],t[1],e,!1,i)}getTileCoordForXYAndResolution_(t,e,i,n,s){const o=this.getZForResolution(i),r=i/this.getResolution(o),a=this.getOrigin(o),l=Zs(this.getTileSize(o),this.tmpSize_);let h=r*(t-a[0])/i/l[0],d=r*(a[1]-e)/i/l[1];return n?(h=Gt(h,5)-1,d=Gt(d,5)-1):(h=Wt(h,5),d=Wt(d,5)),ho(o,h,d,s)}getTileCoordForXYAndZ_(t,e,i,n,s){const o=this.getOrigin(i),r=this.getResolution(i),a=Zs(this.getTileSize(i),this.tmpSize_);let l=(t-o[0])/r/a[0],h=(o[1]-e)/r/a[1];return n?(l=Gt(l,5)-1,h=Gt(h,5)-1):(l=Wt(l,5),h=Wt(h,5)),ho(i,l,h,s)}getTileCoordForCoordAndZ(t,e,i){return this.getTileCoordForXYAndZ_(t[0],t[1],e,!1,i)}getTileCoordResolution(t){return this.resolutions_[t[0]]}getTileSize(t){return this.tileSize_?this.tileSize_:this.tileSizes_[t]}getFullTileRange(t){return this.fullTileRanges_?this.fullTileRanges_[t]:this.extent_?this.getTileRangeForExtentAndZ(this.extent_,t):null}getZForResolution(t,e){return Ft(h(this.resolutions_,t,e||0),this.minZoom,this.maxZoom)}tileCoordIntersectsViewport(t,e){return Gi(e,0,e.length,2,this.getTileCoordExtent(t))}calculateTileRanges_(t){const e=this.resolutions_.length,i=new Array(e);for(let n=this.minZoom;n<e;++n)i[n]=this.getTileRangeForExtentAndZ(t,n);this.fullTileRanges_=i}};function yo(t){let e=t.getDefaultTileGrid();return e||(e=function(t,e,i,n){return function(t,e,i,n){n=void 0!==n?n:"top-left";const s=vo(t,undefined,i);return new _o({extent:t,origin:Tt(t,n),resolutions:s,tileSize:i})}(xo(t),0,void 0,void 0)}(t),t.setDefaultTileGrid(e)),e}function vo(t,e,i,n){e=void 0!==e?e:ge,i=Zs(void 0!==i?i:fe);const s=It(t),o=Mt(t);n=n>0?n:Math.max(o/i[0],s/i[1]);const r=e+1,a=new Array(r);for(let t=0;t<r;++t)a[t]=n/Math.pow(2,t);return a}function xo(t){let e=(t=Be(t)).getExtent();if(!e){const i=180*me.degrees/t.getMetersPerUnit();e=pt(-i,-i,i,i)}return e}class wo extends o{constructor(t,e){super(t),this.tile=e}}const Co=class extends fo{constructor(t){super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,projection:t.projection,state:t.state,wrapX:t.wrapX,interpolate:t.interpolate}),this.on,this.once,this.un,this.opaque_=void 0!==t.opaque&&t.opaque,this.tilePixelRatio_=void 0!==t.tilePixelRatio?t.tilePixelRatio:1,this.tileGrid=void 0!==t.tileGrid?t.tileGrid:null;this.tileGrid&&Zs(this.tileGrid.getTileSize(this.tileGrid.getMinZoom()),[256,256]),this.tileCache=new po(t.cacheSize||0),this.tmpSize=[0,0],this.key_=t.key||"",this.tileOptions={transition:t.transition,interpolate:t.interpolate},this.zDirection=t.zDirection?t.zDirection:0}canExpireCache(){return this.tileCache.canExpireCache()}expireCache(t,e){const i=this.getTileCacheForProjection(t);i&&i.expireCache(e)}forEachLoadedTile(t,e,i,n){const s=this.getTileCacheForProjection(t);if(!s)return!1;let o,r,a,l=!0;for(let t=i.minX;t<=i.maxX;++t)for(let h=i.minY;h<=i.maxY;++h)r=co(e,t,h),a=!1,s.containsKey(r)&&(o=s.get(r),a=2===o.getState(),a&&(a=!1!==n(o))),a||(l=!1);return l}getGutterForProjection(t){return 0}getKey(){return this.key_}setKey(t){this.key_!==t&&(this.key_=t,this.changed())}getOpaque(t){return this.opaque_}getResolutions(t){const e=t?this.getTileGridForProjection(t):this.tileGrid;return e?e.getResolutions():null}getTile(t,e,i,n,s){return M()}getTileGrid(){return this.tileGrid}getTileGridForProjection(t){return this.tileGrid?this.tileGrid:yo(t)}getTileCacheForProjection(t){const e=this.getProjection();return J(null===e||Ke(e,t),68),this.tileCache}getTilePixelRatio(t){return this.tilePixelRatio_}getTilePixelSize(t,e,i){const n=this.getTileGridForProjection(i),s=this.getTilePixelRatio(e),o=Zs(n.getTileSize(t),this.tmpSize);return 1==s?o:(r=o,a=s,void 0===(l=this.tmpSize)&&(l=[0,0]),l[0]=r[0]*a+.5|0,l[1]=r[1]*a+.5|0,l);var r,a,l}getTileCoordForTileUrlFunction(t,e){e=void 0!==e?e:this.getProjection();const i=this.getTileGridForProjection(e);return this.getWrapX()&&e.isGlobal()&&(t=function(t,e,i){const n=e[0],s=t.getTileCoordCenter(e),o=xo(i);if(!ht(o,s)){const e=Mt(o),i=Math.ceil((o[0]-s[0])/e);return s[0]+=e*i,t.getTileCoordForCoordAndZ(s,n)}return e}(i,t,e)),function(t,e){const i=t[0],n=t[1],s=t[2];
1if(e.getMinZoom()>i||i>e.getMaxZoom())return!1;const o=e.getFullTileRange(i);return!o||o.containsXY(n,s)}(t,i)?t:null}clear(){this.tileCache.clear()}refresh(){this.clear(),super.refresh()}updateCacheSize(t,e){const i=this.getTileCacheForProjection(e);t>i.highWaterMark&&(i.highWaterMark=t)}useTile(t,e,i,n){}};function So(t,e){const i=/\{z\}/g,n=/\{x\}/g,s=/\{y\}/g,o=/\{-y\}/g;return function(r,a,l){if(r)return t.replace(i,r[0].toString()).replace(n,r[1].toString()).replace(s,r[2].toString()).replace(o,(function(){const t=r[0],i=e.getFullTileRange(t);return J(i,55),(i.getHeight()-r[2]-1).toString()}))}}class To extends Co{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,opaque:t.opaque,projection:t.projection,state:t.state,tileGrid:t.tileGrid,tilePixelRatio:t.tilePixelRatio,wrapX:t.wrapX,transition:t.transition,interpolate:t.interpolate,key:t.key,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection}),this.generateTileUrlFunction_=this.tileUrlFunction===To.prototype.tileUrlFunction,this.tileLoadFunction=t.tileLoadFunction,t.tileUrlFunction&&(this.tileUrlFunction=t.tileUrlFunction),this.urls=null,t.urls?this.setUrls(t.urls):t.url&&this.setUrl(t.url),this.tileLoadingKeys_={}}getTileLoadFunction(){return this.tileLoadFunction}getTileUrlFunction(){return Object.getPrototypeOf(this).tileUrlFunction===this.tileUrlFunction?this.tileUrlFunction.bind(this):this.tileUrlFunction}getUrls(){return this.urls}handleTileChange(t){const e=t.target,i=L(e),n=e.getState();let s;1==n?(this.tileLoadingKeys_[i]=!0,s="tileloadstart"):i in this.tileLoadingKeys_&&(delete this.tileLoadingKeys_[i],s=3==n?"tileloaderror":2==n?"tileloadend":void 0),null!=s&&this.dispatchEvent(new wo(s,e))}setTileLoadFunction(t){this.tileCache.clear(),this.tileLoadFunction=t,this.changed()}setTileUrlFunction(t,e){this.tileUrlFunction=t,this.tileCache.pruneExceptNewestZ(),void 0!==e?this.setKey(e):this.changed()}setUrl(t){const e=function(t){const e=[];let i=/\{([a-z])-([a-z])\}/.exec(t);if(i){const n=i[1].charCodeAt(0),s=i[2].charCodeAt(0);let o;for(o=n;o<=s;++o)e.push(t.replace(i[0],String.fromCharCode(o)));return e}if(i=/\{(\d+)-(\d+)\}/.exec(t),i){const n=parseInt(i[2],10);for(let s=parseInt(i[1],10);s<=n;s++)e.push(t.replace(i[0],s.toString()));return e}return e.push(t),e}(t);this.urls=e,this.setUrls(e)}setUrls(t){this.urls=t;const e=t.join("\n");this.generateTileUrlFunction_?this.setTileUrlFunction(function(t,e){const i=t.length,n=new Array(i);for(let s=0;s<i;++s)n[s]=So(t[s],e);return function(t){return 1===t.length?t[0]:function(e,i,n){if(!e)return;const s=function(t){return(t[1]<<t[0])+t[2]}(e),o=zt(s,t.length);return t[o](e,i,n)}}(n)}(t,this.tileGrid),e):this.setKey(e)}tileUrlFunction(t,e,i){}useTile(t,e,i){const n=co(t,e,i);this.tileCache.containsKey(n)&&this.tileCache.get(n)}}const bo=To;function ko(t,e){t.getImage().src=e}const Io=class extends bo{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,opaque:t.opaque,projection:t.projection,state:t.state,tileGrid:t.tileGrid,tileLoadFunction:t.tileLoadFunction?t.tileLoadFunction:ko,tilePixelRatio:t.tilePixelRatio,tileUrlFunction:t.tileUrlFunction,url:t.url,urls:t.urls,wrapX:t.wrapX,transition:t.transition,interpolate:void 0===t.interpolate||t.interpolate,key:t.key,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection}),this.crossOrigin=void 0!==t.crossOrigin?t.crossOrigin:null,this.tileClass=void 0!==t.tileClass?t.tileClass:Hs,this.tileCacheForProjection={},this.tileGridForProjection={},this.reprojectionErrorThreshold_=t.reprojectionErrorThreshold,this.renderReprojectionEdges_=!1}canExpireCache(){if(this.tileCache.canExpireCache())return!0;for(const t in this.tileCacheForProjection)if(this.tileCacheForProjection[t].canExpireCache())return!0;return!1}expireCache(t,e){const i=this.getTileCacheForProjection(t);this.tileCache.expireCache(this.tileCache==i?e:{});for(const t in this.tileCacheForProjection){const n=this.tileCacheForProjection[t];n.expireCache(n==i?e:{})}}getGutterForProjection(t){return this.getProjection()&&t&&!Ke(this.getProjection(),t)?0:this.getGutter()}getGutter(){return 0}getKey(){let t=super.getKey();return this.getInterpolate()||(t+=":disable-interpolation"),t}getOpaque(t){return!(this.getProjection()&&t&&!Ke(this.getProjection(),t))&&super.getOpaque(t)}getTileGridForProjection(t){const e=this.getProjection();
1if(this.tileGrid&&(!e||Ke(e,t)))return this.tileGrid;const i=L(t);return i in this.tileGridForProjection||(this.tileGridForProjection[i]=yo(t)),this.tileGridForProjection[i]}getTileCacheForProjection(t){const e=this.getProjection();if(!e||Ke(e,t))return this.tileCache;const i=L(t);return i in this.tileCacheForProjection||(this.tileCacheForProjection[i]=new po(this.tileCache.highWaterMark)),this.tileCacheForProjection[i]}createTile_(t,e,i,n,s,o){const r=[t,e,i],a=this.getTileCoordForTileUrlFunction(r,s),l=a?this.tileUrlFunction(a,n,s):void 0,h=new this.tileClass(r,void 0!==l?0:4,void 0!==l?l:"",this.crossOrigin,this.tileLoadFunction,this.tileOptions);return h.key=o,h.addEventListener(v,this.handleTileChange.bind(this)),h}getTile(t,e,i,n,s){const o=this.getProjection();if(!o||!s||Ke(o,s))return this.getTileInternal(t,e,i,n,o||s);const r=this.getTileCacheForProjection(s),a=[t,e,i];let l;const h=uo(a);r.containsKey(h)&&(l=r.get(h));const d=this.getKey();if(l&&l.key==d)return l;const c=this.getTileGridForProjection(o),u=this.getTileGridForProjection(s),p=this.getTileCoordForTileUrlFunction(a,s),g=new io(o,c,s,u,a,p,this.getTilePixelRatio(n),this.getGutter(),((t,e,i,n)=>this.getTileInternal(t,e,i,n,o)),this.reprojectionErrorThreshold_,this.renderReprojectionEdges_,this.getInterpolate());return g.key=d,l?(g.interimTile=l,g.refreshInterimChain(),r.replace(h,g)):r.set(h,g),g}getTileInternal(t,e,i,n,s){let o=null;const r=co(t,e,i),a=this.getKey();if(this.tileCache.containsKey(r)){if(o=this.tileCache.get(r),o.key!=a){const l=o;o=this.createTile_(t,e,i,n,s,a),0==l.getState()?o.interimTile=l.interimTile:o.interimTile=l,o.refreshInterimChain(),this.tileCache.replace(r,o)}}else o=this.createTile_(t,e,i,n,s,a),this.tileCache.set(r,o);return o}setRenderReprojectionEdges(t){if(this.renderReprojectionEdges_!=t){this.renderReprojectionEdges_=t;for(const t in this.tileCacheForProjection)this.tileCacheForProjection[t].clear();this.changed()}}setTileGridForProjection(t,e){const i=Be(t);if(i){const t=L(i);t in this.tileGridForProjection||(this.tileGridForProjection[t]=e)}}clear(){super.clear();for(const t in this.tileCacheForProjection)this.tileCacheForProjection[t].clear()}},Eo=class extends Io{constructor(t){const e=void 0!==(t=t||{}).projection?t.projection:"EPSG:3857",i=void 0!==t.tileGrid?t.tileGrid:function(t){const e=t||{},i=e.extent||Be("EPSG:3857").getExtent(),n={extent:i,minZoom:e.minZoom,tileSize:e.tileSize,resolutions:vo(i,e.maxZoom,e.tileSize,e.maxResolution)};return new _o(n)}({extent:xo(e),maxResolution:t.maxResolution,maxZoom:t.maxZoom,minZoom:t.minZoom,tileSize:t.tileSize});super({attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,opaque:t.opaque,projection:e,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileGrid:i,tileLoadFunction:t.tileLoadFunction,tilePixelRatio:t.tilePixelRatio,tileUrlFunction:t.tileUrlFunction,url:t.url,urls:t.urls,wrapX:void 0===t.wrapX||t.wrapX,transition:t.transition,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection}),this.gutter_=void 0!==t.gutter?t.gutter:0}getGutter(){return this.gutter_}},Ro=class extends Eo{constructor(t){let e;e=void 0!==(t=t||{}).attributions?t.attributions:['&#169; <a href="https://www.openstreetmap.org/copyright" target="_blank">OpenStreetMap</a> contributors.'];const i=void 0!==t.crossOrigin?t.crossOrigin:"anonymous",n=void 0!==t.url?t.url:"https://tile.openstreetmap.org/{z}/{x}/{y}.png";super({attributions:e,attributionsCollapsible:!1,cacheSize:t.cacheSize,crossOrigin:i,interpolate:t.interpolate,maxZoom:void 0!==t.maxZoom?t.maxZoom:19,opaque:void 0===t.opaque||t.opaque,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileLoadFunction:t.tileLoadFunction,transition:t.transition,url:n,wrapX:t.wrapX,zDirection:t.zDirection})}};var Po=i(2582);class Mo{constructor(t){this.opacity_=t.opacity,this.rotateWithView_=t.rotateWithView,this.rotation_=t.rotation,this.scale_=t.scale,this.scaleArray_=Zs(t.scale),this.displacement_=t.displacement,this.declutterMode_=t.declutterMode}clone(){const t=this.getScale();return new Mo({opacity:this.getOpacity(),scale:Array.isArray(t)?t.slice():t,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()})}getOpacity(){return this.opacity_}getRotateWithView(){return this.rotateWithView_}getRotation(){return this.rotation_}getScale(){return this.scale_}getScaleArray(){return this.scaleArray_}getDisplacement(){return this.displacement_}getDeclutterMode(){return this.declutterMode_}getAnchor(){return M()}getImage(t){return M()}getHitDetectionImage(){return M()}getPixelRatio(t){return 1}getImageState(){return M()}getImageSize(){return M()}getOrigin(){return M()}getSize(){return M()}setDisplacement(t){this.displacement_=t}setOpacity(t){this.opacity_=t}setRotateWithView(t){this.rotateWithView_=t}setRotation(t){this.rotation_=t}setScale(t){this.scale_=t,this.scaleArray_=Zs(t)}listenImageChange(t){M()}load(){M()}unlistenImageChange(t){M()}}const Ao=Mo;function Lo(t){return Array.isArray(t)?Ht(t):t}class Oo extends Ao{constructor(t){super({opacity:1,rotateWithView:void 0!==t.rotateWithView&&t.rotateWithView,rotation:void 0!==t.rotation?t.rotation:0,scale:void 0!==t.scale?t.scale:1,displacement:void 0!==t.displacement?t.dis
1placement:[0,0],declutterMode:t.declutterMode}),this.canvas_=void 0,this.hitDetectionCanvas_=null,this.fill_=void 0!==t.fill?t.fill:null,this.origin_=[0,0],this.points_=t.points,this.radius_=void 0!==t.radius?t.radius:t.radius1,this.radius2_=t.radius2,this.angle_=void 0!==t.angle?t.angle:0,this.stroke_=void 0!==t.stroke?t.stroke:null,this.size_=null,this.renderOptions_=null,this.render()}clone(){const t=this.getScale(),e=new Oo({fill:this.getFill()?this.getFill().clone():void 0,points:this.getPoints(),radius:this.getRadius(),radius2:this.getRadius2(),angle:this.getAngle(),stroke:this.getStroke()?this.getStroke().clone():void 0,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),scale:Array.isArray(t)?t.slice():t,displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()});return e.setOpacity(this.getOpacity()),e}getAnchor(){const t=this.size_;if(!t)return null;const e=this.getDisplacement(),i=this.getScaleArray();return[t[0]/2-e[0]/i[0],t[1]/2+e[1]/i[1]]}getAngle(){return this.angle_}getFill(){return this.fill_}setFill(t){this.fill_=t,this.render()}getHitDetectionImage(){return this.hitDetectionCanvas_||this.createHitDetectionCanvas_(this.renderOptions_),this.hitDetectionCanvas_}getImage(t){let e=this.canvas_[t];if(!e){const i=this.renderOptions_,n=pn(i.size*t,i.size*t);this.draw_(i,n,t),e=n.canvas,this.canvas_[t]=e}return e}getPixelRatio(t){return t}getImageSize(){return this.size_}getImageState(){return 2}getOrigin(){return this.origin_}getPoints(){return this.points_}getRadius(){return this.radius_}getRadius2(){return this.radius2_}getSize(){return this.size_}getStroke(){return this.stroke_}setStroke(t){this.stroke_=t,this.render()}listenImageChange(t){}load(){}unlistenImageChange(t){}calculateLineJoinSize_(t,e,i){if(0===e||this.points_===1/0||"bevel"!==t&&"miter"!==t)return e;let n=this.radius_,s=void 0===this.radius2_?n:this.radius2_;if(n<s){const t=n;n=s,s=t}const o=void 0===this.radius2_?this.points_:2*this.points_,r=2*Math.PI/o,a=s*Math.sin(r),l=n-Math.sqrt(s*s-a*a),h=Math.sqrt(a*a+l*l),d=h/a;if("miter"===t&&d<=i)return d*e;const c=e/2/d,u=e/2*(l/h),p=Math.sqrt((n+c)*(n+c)+u*u)-n;if(void 0===this.radius2_||"bevel"===t)return 2*p;const g=n*Math.sin(r),f=s-Math.sqrt(n*n-g*g),m=Math.sqrt(g*g+f*f)/g;if(m<=i){const t=m*e/2-s-n;return 2*Math.max(p,t)}return 2*p}createRenderOptions(){let t,e=wn,i=0,n=null,s=0,o=0;this.stroke_&&(t=this.stroke_.getColor(),null===t&&(t=Cn),t=Lo(t),o=this.stroke_.getWidth(),void 0===o&&(o=1),n=this.stroke_.getLineDash(),s=this.stroke_.getLineDashOffset(),e=this.stroke_.getLineJoin(),void 0===e&&(e=wn),i=this.stroke_.getMiterLimit(),void 0===i&&(i=10));const r=this.calculateLineJoinSize_(e,o,i),a=Math.max(this.radius_,this.radius2_||0);return{strokeStyle:t,strokeWidth:o,size:Math.ceil(2*a+r),lineDash:n,lineDashOffset:s,lineJoin:e,miterLimit:i}}render(){this.renderOptions_=this.createRenderOptions();const t=this.renderOptions_.size;this.canvas_={},this.size_=[t,t]}draw_(t,e,i){if(e.scale(i,i),e.translate(t.size/2,t.size/2),this.createPath_(e),this.fill_){let t=this.fill_.getColor();null===t&&(t=yn),e.fillStyle=Lo(t),e.fill()}this.stroke_&&(e.strokeStyle=t.strokeStyle,e.lineWidth=t.strokeWidth,t.lineDash&&(e.setLineDash(t.lineDash),e.lineDashOffset=t.lineDashOffset),e.lineJoin=t.lineJoin,e.miterLimit=t.miterLimit,e.stroke())}createHitDetectionCanvas_(t){if(this.fill_){let e=this.fill_.getColor(),i=0;if("string"==typeof e&&(e=Kt(e)),null===e?i=1:Array.isArray(e)&&(i=4===e.length?e[3]:1),0===i){const e=pn(t.size,t.size);this.hitDetectionCanvas_=e.canvas,this.drawHitDetectionCanvas_(t,e)}}this.hitDetectionCanvas_||(this.hitDetectionCanvas_=this.getImage(1))}createPath_(t){let e=this.points_;const i=this.radius_;if(e===1/0)t.arc(0,0,i,0,2*Math.PI);else{const n=void 0===this.radius2_?i:this.radius2_;void 0!==this.radius2_&&(e*=2);const s=this.angle_-Math.PI/2,o=2*Math.PI/e;for(let r=0;r<e;r++){const e=s+r*o,a=r%2==0?i:n;t.lineTo(a*Math.cos(e),a*Math.sin(e))}t.closePath()}}drawHitDetectionCanvas_(t,e){e.translate(t.size/2,t.size/2),this.createPath_(e),e.fillStyle=yn,e.fill(),this.stroke_&&(e.strokeStyle=t.strokeStyle,e.lineWidth=t.strokeWidth,t.lineDash&&(e.setLineDash(t.lineDash),e.lineDashOffset=t.lineDashOffset),e.lineJoin=t.lineJoin,e.miterLimit=t.miterLimit,e.stroke())}}const Fo=Oo;class Do extends Fo{constructor(t){super({points:1/0,fill:(t=t||{radius:5}).fill,radius:t.radius,stroke:t.stroke,scale:void 0!==t.scale?t.scale:1,rotation:void 0!==t.rotation?t.rotation:0,rotateWithView:void 0!==t.rotateWithView&&t.rotateWithView,displacement:void 0!==t.displacement?t.dis
1placement:[0,0],declutterMode:t.declutterMode})}clone(){const t=this.getScale(),e=new Do({fill:this.getFill()?this.getFill().clone():void 0,stroke:this.getStroke()?this.getStroke().clone():void 0,radius:this.getRadius(),scale:Array.isArray(t)?t.slice():t,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()});return e.setOpacity(this.getOpacity()),e}setRadius(t){this.radius_=t,this.render()}}const Zo=Do;class No{constructor(t){t=t||{},this.color_=void 0!==t.color?t.color:null}clone(){const t=this.getColor();return new No({color:Array.isArray(t)?t.slice():t||void 0})}getColor(){return this.color_}setColor(t){this.color_=t}}const zo=No;class jo{constructor(t){t=t||{},this.color_=void 0!==t.color?t.color:null,this.lineCap_=t.lineCap,this.lineDash_=void 0!==t.lineDash?t.lineDash:null,this.lineDashOffset_=t.lineDashOffset,this.lineJoin_=t.lineJoin,this.miterLimit_=t.miterLimit,this.width_=t.width}clone(){const t=this.getColor();return new jo({color:Array.isArray(t)?t.slice():t||void 0,lineCap:this.getLineCap(),lineDash:this.getLineDash()?this.getLineDash().slice():void 0,lineDashOffset:this.getLineDashOffset(),lineJoin:this.getLineJoin(),miterLimit:this.getMiterLimit(),width:this.getWidth()})}getColor(){return this.color_}getLineCap(){return this.lineCap_}getLineDash(){return this.lineDash_}getLineDashOffset(){return this.lineDashOffset_}getLineJoin(){return this.lineJoin_}getMiterLimit(){return this.miterLimit_}getWidth(){return this.width_}setColor(t){this.color_=t}setLineCap(t){this.lineCap_=t}setLineDash(t){this.lineDash_=t}setLineDashOffset(t){this.lineDashOffset_=t}setLineJoin(t){this.lineJoin_=t}setMiterLimit(t){this.miterLimit_=t}setWidth(t){this.width_=t}}const $o=jo;class Wo{constructor(t){t=t||{},this.geometry_=null,this.geometryFunction_=Vo,void 0!==t.geometry&&this.setGeometry(t.geometry),this.fill_=void 0!==t.fill?t.fill:null,this.image_=void 0!==t.image?t.image:null,this.renderer_=void 0!==t.renderer?t.renderer:null,this.hitDetectionRenderer_=void 0!==t.hitDetectionRenderer?t.hitDetectionRenderer:null,this.stroke_=void 0!==t.stroke?t.stroke:null,this.text_=void 0!==t.text?t.text:null,this.zIndex_=t.zIndex}clone(){let t=this.getGeometry();return t&&"object"==typeof t&&(t=t.clone()),new Wo({geometry:t,fill:this.getFill()?this.getFill().clone():void 0,image:this.getImage()?this.getImage().clone():void 0,renderer:this.getRenderer(),stroke:this.getStroke()?this.getStroke().clone():void 0,text:this.getText()?this.getText().clone():void 0,zIndex:this.getZIndex()})}getRenderer(){return this.renderer_}setRenderer(t){this.renderer_=t}setHitDetectionRenderer(t){this.hitDetectionRenderer_=t}getHitDetectionRenderer(){return this.hitDetectionRenderer_}getGeometry(){return this.geometry_}getGeometryFunction(){return this.geometryFunction_}getFill(){return this.fill_}setFill(t){this.fill_=t}getImage(){return this.image_}setImage(t){this.image_=t}getStroke(){return this.stroke_}setStroke(t){this.stroke_=t}getText(){return this.text_}setText(t){this.text_=t}getZIndex(){return this.zIndex_}setGeometry(t){"function"==typeof t?this.geometryFunction_=t:"string"==typeof t?this.geometryFunction_=function(e){return e.get(t)}:t?void 0!==t&&(this.geometryFunction_=function(){return t}):this.geometryFunction_=Vo,this.geometry_=t}setZIndex(t){this.zIndex_=t}}let Go=null;function Bo(t,e){if(!Go){const t=new zo({color:"rgba(255,255,255,0.4)"}),e=new $o({color:"#3399CC",width:1.25});Go=[new Wo({image:new Zo({fill:t,stroke:e,radius:5}),fill:t,stroke:e})]}return Go}function Vo(t){return t.getGeometry()}const Uo=Wo;let Xo=null;class Ko extends y{constructor(t,e,i,n,s,o){super(),this.hitDetectionImage_=null,this.image_=t,this.crossOrigin_=n,this.canvas_={},this.color_=o,this.unlisten_=null,this.imageState_=s,this.size_=i,this.src_=e,this.tainted_}initializeImage_(){this.image_=new Image,null!==this.crossOrigin_&&(this.image_.crossOrigin=this.crossOrigin_)}isTainted_(){if(void 0===this.tainted_&&2===this.imageState_){Xo||(Xo=pn(1,1,void 0,{willReadFrequently:!0}
1)),Xo.drawImage(this.image_,0,0);try{Xo.getImageData(0,0,1,1),this.tainted_=!1}catch(t){Xo=null,this.tainted_=!0}}return!0===this.tainted_}dispatchChangeEvent_(){this.dispatchEvent(v)}handleImageError_(){this.imageState_=3,this.unlistenImage_(),this.dispatchChangeEvent_()}handleImageLoad_(){this.imageState_=2,this.size_?(this.image_.width=this.size_[0],this.image_.height=this.size_[1]):this.size_=[this.image_.width,this.image_.height],this.unlistenImage_(),this.dispatchChangeEvent_()}getImage(t){return this.image_||this.initializeImage_(),this.replaceColor_(t),this.canvas_[t]?this.canvas_[t]:this.image_}getPixelRatio(t){return this.replaceColor_(t),this.canvas_[t]?t:1}getImageState(){return this.imageState_}getHitDetectionImage(){if(this.image_||this.initializeImage_(),!this.hitDetectionImage_)if(this.isTainted_()){const t=this.size_[0],e=this.size_[1],i=pn(t,e);i.fillRect(0,0,t,e),this.hitDetectionImage_=i.canvas}else this.hitDetectionImage_=this.image_;return this.hitDetectionImage_}getSize(){return this.size_}getSrc(){return this.src_}load(){if(0===this.imageState_){this.image_||this.initializeImage_(),this.imageState_=1;try{this.image_.src=this.src_}catch(t){this.handleImageError_()}this.unlisten_=Ys(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this))}}replaceColor_(t){if(!this.color_||this.canvas_[t]||2!==this.imageState_)return;const e=this.image_,i=document.createElement("canvas");i.width=Math.ceil(e.width*t),i.height=Math.ceil(e.height*t);const n=i.getContext("2d");n.scale(t,t),n.drawImage(e,0,0),n.globalCompositeOperation="multiply",n.fillStyle=Ut(this.color_),n.fillRect(0,0,i.width/t,i.height/t),n.globalCompositeOperation="destination-in",n.drawImage(e,0,0),this.canvas_[t]=i}unlistenImage_(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)}}function Yo(t,e,i,n){return void 0!==i&&void 0!==n?[i/t,n/e]:void 0!==i?i/t:void 0!==n?n/e:1}class Ho extends Ao{constructor(t){const e=void 0!==(t=t||{}).opacity?t.opacity:1,i=void 0!==t.rotation?t.rotation:0,n=void 0!==t.scale?t.scale:1,s=void 0!==t.rotateWithView&&t.rotateWithView;super({opacity:e,rotation:i,scale:n,displacement:void 0!==t.displacement?t.displacement:[0,0],rotateWithView:s,declutterMode:t.declutterMode}),this.anchor_=void 0!==t.anchor?t.anchor:[.5,.5],this.normalizedAnchor_=null,this.anchorOrigin_=void 0!==t.anchorOrigin?t.anchorOrigin:"top-left",this.anchorXUnits_=void 0!==t.anchorXUnits?t.anchorXUnits:"fraction",this.anchorYUnits_=void 0!==t.anchorYUnits?t.anchorYUnits:"fraction",this.crossOrigin_=void 0!==t.crossOrigin?t.crossOrigin:null;const o=void 0!==t.img?t.img:null;this.imgSize_=t.imgSize;let r=t.src;J(!(void 0!==r&&o),4),J(!o||o&&this.imgSize_,5),void 0!==r&&0!==r.length||!o||(r=o.src||L(o)),J(void 0!==r&&r.length>0,6),J(!((void 0!==t.width||void 0!==t.height)&&void 0!==t.scale),69);const a=void 0!==t.src?0:2;if(this.color_=void 0!==t.color?Kt(t.color):null,this.iconImage_=function(t,e,i,n,s,o){let r=Jt.get(e,n,o);return r||(r=new Ko(t,e,i,n,s,o),Jt.set(e,n,o,r)),r}(o,r,void 0!==this.imgSize_?this.imgSize_:null,this.crossOrigin_,a,this.color_),this.offset_=void 0!==t.offset?t.offset:[0,0],this.offsetOrigin_=void 0!==t.offsetOrigin?t.offsetOrigin:"top-left",this.origin_=null,this.size_=void 0!==t.size?t.size:null,void 0!==t.width||void 0!==t.height){let e,i;if(t.size)[e,i]=t.size;else{const n=this.getImage(1);if(!(n instanceof HTMLCanvasElement||n.src&&n.complete)){this.initialOptions_=t;const e=()=>{if(this.unlistenImageChange(e),!this.initialOptions_)return;const i=this.iconImage_.getSize();this.setScale(Yo(i[0],i[1],t.width,t.height))};return void this.listenImageChange(e)}e=n.width,i=n.height}void 0!==e&&this.setScale(Yo(e,i,t.width,t.height))}}clone(){let t,e,i;return this.initialOptions_?(e=this.initialOptions_.width,i=this.initialOptions_.height):(t=this.getScale(),t=Array.isArray(t)?t.slice():t),new Ho({anchor:this.anchor_.slice(),anchorOrigin:this.anchorOrigin_,anchorXUnits:this.anchorXUnits_,anchorYUnits:this.anchorYUnits_,color:this.color_&&this.color_.slice?this.color_.slice():this.color_||void 0,crossOrigin:this.crossOrigin_,imgSize:this.imgSize_,offset:this.offset_.slice(),offsetOrigin:this.offsetOrigin_,opacity:this.getOpacity(),rotateWithView:this.getRotateWithView(),rotation:this.getRotation(),scale:t,width:e,height:i,size:null!==this.size_?this.size_.slice():void 0,src:this.getSrc(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()})}getAnchor(){let t=this.normalizedAnchor_;if(!t){t=this.anchor_;const e=this.getSize();if("fraction"==this.anchorXUnits_||"fraction"==this.anchorYUnits_){if(!e)return null;t=this.anchor_.slice(),"fraction"==this.anchorXUnits_&&(t[0]*=e[0]),"fraction"==this.anchorYUnits_&&(t[1]*=e[1])}if("top-left"!=this.anchorOrigin_){if(!e)return null;t===this.anchor_&&(t=this.anchor_.slice()),"top-right"!=this.anchorOrigin_&&"bottom-right"!=this.anchorOrigin_||(t[0]=-t[0]+e[0]),"bottom-left"!=this.anchorOrigin_&&"bottom-right"!=this.anchorOrigin_||(t[1]=-t[1]+e[1])}this.normalizedAnchor_=t}const e=this.getDisplacement(),i=this.getScaleArray();return[t[0]-e[0]/i[0],t[1]+e[1]/i[1]]}setAnchor(t){this.anchor_=t,this.normalizedAnchor_=null}getColor(){return this.color_}getImage(t){return this.iconImage_.getImage(t)}getPixelRatio(t){return this.iconImage_.getPixelRatio(t)}getImageSize(){return this.iconImage_.getSize()}getImageState(){return this.iconImage_.getImageState()}getHitDetectionImage(){return this.iconImage_.getHitDetectionImage()}getOrigin(){if(this.origin_)return this.origin_;let t=this.offset_;if("top-left"!=this.offsetOrigin_){const e=this.getSize(),i=this.iconImage_.getSize();if(!e||!i)return null;t=t.slice(),"top-right"!=this.offsetOrigin_&&"bottom-right"!=this.offsetOrigin_||(t[0]=i[0]-e[0]-t[0]),"bottom-left"!=this.offsetOrigin_&&"bottom-right"!=this.offsetOrigin_||(t[1]=i[1]-e[1]-t[1])}return this.origin_=t,this.origin_}getSrc(){return this.iconImage_.getSrc()}getSize(){return this.size_?this.size_:this.iconImage_.getSize()}getWidth(){const t=this.getScaleArray();return this.size_?this.size_[0]*t[0]:2==this.iconImage_.getImageState()?this.iconImage_.getSize()[0]*t[0]:void 0}getHeight(){const t=this.getScaleArray();return this.size_?this.size_[1]*t[1]:2==this.iconImage_.getImageState()?this.iconImage_.getSize()[1]*t[1]:void 0}setScale(t){delete this.initialOptions_,super.setScale(t)}listenImageChange(t){this.iconImage_.addEventListener(v,t)}load(){this.iconImage_.load()}unlistenImageChange(t){this.iconImage_.removeEventListener(v,t)}}const qo=Ho;class Jo{constructor(t){t=t||{},this.font_=t.font,this.rotation_=t.rotation,this.rotateWithView_=t.rotateWithView,this.scale_=t.scale,this.scaleArray_=Zs(void 0!==t.scale?t.scale:1),this.text_=t.text,this.textAlign_=t.textAlign,this.justify_=t.justify,this.repeat_=t.repeat,this.textBaseline_=t.textBaseline,this.fill_=void 0!==t.fill?t.fill:new zo({color:"#333"}),this.maxAngle_=void 0!==t.maxAngle?t.maxAngle:Math.PI/4,this.placement_=void 0!==t.placement?t.placement:"point",this.overflow_=!!t.overflow,this.stroke_=void 0!==t.stroke?t.stroke:null,this.offsetX_=void 0!==t.offsetX?t.offsetX:0,this.offsetY_=void 0!==t.offsetY?t.offsetY:0,this.backgroundFill_=t.backgroundFill?t.backgroundFill:null,this.backgroundStroke_=t.backgroundStroke?t.backgroundStroke:null,this.padding_=void 0===t.padding?null:t.padding}clone(){const t=this.getScale();return new Jo({font:this.getFont(),placement:this.getPlacement(),repeat:this.getRepeat(),maxAngle:this.getMaxAngle(),overflow:this.getOverflow(),rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),scale:Array.isArray(t)?t.slice():t,text:this.getText(),textAlign:this.getTextAlign(),justify:this.getJustify(),textBaseline:this.getTextBaseline(),fill:this.getFill()?this.getFill().clone():void 0,stroke:this.getStroke()?this.get
1Stroke().clone():void 0,offsetX:this.getOffsetX(),offsetY:this.getOffsetY(),backgroundFill:this.getBackgroundFill()?this.getBackgroundFill().clone():void 0,backgroundStroke:this.getBackgroundStroke()?this.getBackgroundStroke().clone():void 0,padding:this.getPadding()||void 0})}getOverflow(){return this.overflow_}getFont(){return this.font_}getMaxAngle(){return this.maxAngle_}getPlacement(){return this.placement_}getRepeat(){return this.repeat_}getOffsetX(){return this.offsetX_}getOffsetY(){return this.offsetY_}getFill(){return this.fill_}getRotateWithView(){return this.rotateWithView_}getRotation(){return this.rotation_}getScale(){return this.scale_}getScaleArray(){return this.scaleArray_}getStroke(){return this.stroke_}getText(){return this.text_}getTextAlign(){return this.textAlign_}getJustify(){return this.justify_}getTextBaseline(){return this.textBaseline_}getBackgroundFill(){return this.backgroundFill_}getBackgroundStroke(){return this.backgroundStroke_}getPadding(){return this.padding_}setOverflow(t){this.overflow_=t}setFont(t){this.font_=t}setMaxAngle(t){this.maxAngle_=t}setOffsetX(t){this.offsetX_=t}setOffsetY(t){this.offsetY_=t}setPlacement(t){this.placement_=t}setRepeat(t){this.repeat_=t}setRotateWithView(t){this.rotateWithView_=t}setFill(t){this.fill_=t}setRotation(t){this.rotation_=t}setScale(t){this.scale_=t,this.scaleArray_=Zs(void 0!==t?t:1)}setStroke(t){this.stroke_=t}setText(t){this.text_=t}setTextAlign(t){this.textAlign_=t}setJustify(t){this.justify_=t}setTextBaseline(t){this.textBaseline_=t}setBackgroundFill(t){this.backgroundFill_=t}setBackgroundStroke(t){this.backgroundStroke_=t}setPadding(t){this.padding_=t}}const Qo=Jo;function tr(t){return new Uo({fill:er(t,""),stroke:ir(t,""),text:nr(t),image:sr(t)})}function er(t,e){const i=t[e+"fill-color"];if(i)return"none"===i?null:new zo({color:i})}function ir(t,e){const i=t[e+"stroke-width"],n=t[e+"stroke-color"];if(i||n)return new $o({width:i,color:n,lineCap:t[e+"stroke-line-cap"],lineJoin:t[e+"stroke-line-join"],lineDash:t[e+"stroke-line-dash"],lineDashOffset:t[e+"stroke-line-dash-offset"],miterLimit:t[e+"stroke-miter-limit"]})}function nr(t){const e=t["text-value"];if(e)return new Qo({text:e,font:t["text-font"],maxAngle:t["text-max-angle"],offsetX:t["text-offset-x"],offsetY:t["text-offset-y"],overflow:t["text-overflow"],placement:t["text-placement"],repeat:t["text-repeat"],scale:t["text-scale"],rotateWithView:t["text-rotate-with-view"],rotation:t["text-rotation"],textAlign:t["text-align"],justify:t["text-justify"],textBaseline:t["text-baseline"],padding:t["text-padding"],fill:er(t,"text-"),backgroundFill:er(t,"text-background-"),stroke:ir(t,"text-"),backgroundStroke:ir(t,"text-background-")})}function sr(t){const e=t["icon-src"],i=t["icon-img"];if(e||i)return new qo({src:e,img:i,imgSize:t["icon-img-size"],anchor:t["icon-anchor"],anchorOrigin:t["icon-anchor-origin"],anchorXUnits:t["icon-anchor-x-units"],anchorYUnits:t["icon-anchor-y-units"],color:t["icon-color"],crossOrigin:t["icon-cross-origin"],offset:t["icon-offset"],displacement:t["icon-displacement"],opacity:t["icon-opacity"],scale:t["icon-scale"],width:t["icon-width"],height:t["icon-height"],rotation:t["icon-rotation"],rotateWithView:t["icon-rotate-with-view"],size:t["icon-size"],declutterMode:t["icon-declutter-mode"]});const n=t["shape-points"];if(n){const e="shape-";return new Fo({points:n,fill:er(t,e),stroke:ir(t,e),radius:t["shape-radius"],radius1:t["shape-radius1"],radius2:t["shape-radius2"],angle:t["shape-angle"],displacement:t["shape-displacement"],rotation:t["shape-rotation"],rotateWithView:t["shape-rotate-with-view"],scale:t["shape-scale"],declutterMode:t["shape-declutter-mode"]})}const s=t["circle-radius"];if(s){const e="circle-";return new Zo({radius:s,fill:er(t,e),stroke:ir(t,e),displacement:t["circle-displacement"],scale:t["circle-scale"],rotation:t["circle-rotation"],rotateWithView:t["circle-rotate-with-view"],declutterMode:t["circle-declutter-mode"]})}}const or="renderOrder",rr=class extends en{constructor(t){t=t||{};const e=Object.assign({},t);delete e.style,delete e.renderBuffer,delete e.updateWhileAnimating,delete e.updateWhileInteracting,super(e),this.declutter_=void 0!==t.declutter&&t.declutter,this.renderBuffer_=void 0!==t.renderBuffer?t.renderBuffer:100,this.style_=null,this.styleFunction_=void 0,this.setStyle(t.style),this.updateWhileAnimating_=void 0!==t.updateWhileAnimating&&t.updateWhileAnimating,this.updateWhileInteracting_=void 0!==t.updateWhileInteracting&&t.updateWhileInteracting}getDeclutter(){return this.declutter_}getFeatures(t){return super.getFeatures(t)}getRenderBuffer(){return this.renderBuffer_}getRenderOrder(){return this.get(or)}getStyle(){return this.style_}getStyleFunction(){return this.styleFunction_}getUpdateWhileAnimating(){return this.updateWhileAnimating_}getUpdateWhileInteracting(){return this.updateWhileInteracting_}renderDeclutter(t){t.declutterTree||(t.declutterTree=new Po(9)),this.getRenderer().renderDeclutter(t)}setRenderOrder(t){this.set(or,t)}setStyle(t){let e;if(void 0===t)e=Bo;else if(null===t)e=null;else if("function"==typeof t)e=t;else if(t instanceof Uo)e=t;else if(Array.isArray(t)){const i=t.length,n=new Array(i);for(let e=0;e<i;++e){const i=t[e];n[e]=i instanceof Uo?i:tr(i)}e=n}else e=tr(t);this.style_=e,this.styleFunction_=null===t?void 0:function(t){let e;if("function"==typeof t)e=t;else{let i;Array.isArray(t)?i=t:(J("function"==typeof t.getZIndex,41),i=[t]),e=function(){return i}}return e}(this.style_),this.changed()}},ar={BEGIN_GEOMETRY:0,BEGIN_PATH:1,CIRCLE:2,CLOSE_PATH:3,CUSTOM:4,DRAW_CHARS:5,DRAW_IMAGE:6,END_GEOMETRY:7,FILL:8,MOVE_TO_LINE_TO:9,SET_FILL_STYLE:10,SET_STROKE_STYLE:11,STROKE:12},lr=[ar.FILL],hr=[ar.STROKE],dr=[ar.BEGIN_PATH],cr=[ar.CLOSE_PATH],ur=ar,pr=class{drawCustom(t,e,i,n){}drawGeometry(t){}setStyle(t){}drawCircle(t,e){}drawFeature(t,e){}drawGeometryCollection(t,e){}drawLineString(t,e){}drawMultiLineString(t,e){}drawMultiPoint(t,e){}drawMultiPolygon(t,e){}drawPoint(t,e){}drawPolygon(t,e){}drawText(t,e){}setFillStrokeStyle(t,e){}setImageStyle(t,e){}setTextStyle(t,e){}},gr=class extends pr{constructor(t,e,i,n){super(),this.tolerance=t,this.maxExtent=e,this.pixelRatio=n,this.maxLineWidth=0,this.resolution=i,this.beginGeometryInstruction1_=null,this.beginGeometryInstruction2_=null,this.bufferedMaxExtent_=null,this.instructions=[],this.coordinates=[],this.tmpCoordinate_=[],this.hitDetectionInstructions=[],this.state={}}applyPixelRatio(t){const e=this.pixelRatio;return 1==e?t:t.map((function(t){return t*e}))}appendFlatPointCoordinates(t,e){const i=this.getBufferedMaxExtent(),n=this.tmpCoordinate_,s=this.coordinates;let o=s.length;for(let r=0,a=t.length;r<a;r+=e)n[0]=t[r],n[1]=t[r+1],ht(i,n)&&(s[o++]=n[0],s[o++]=n[1]);return o}appendFlatLineCoordinates(t,e,i,n,s,o){const r=this.coordinates;let a=r.length;const l=this.getBufferedMaxExtent();o&&(e+=n);let h=t[e],d=t[e+1];const c=this.tmpCoordinate_;let u,p,g,f=!0;for(u=e+n;u<i;u+=n)c[0]=t[u],c[1]=t[u+1],g=ut(l,c),g!==p?(f&&(r[a++]=h,r[a++]=d,f=!1),r[a++]=c[0],r[a++]=c[1]):g===st.INTERSECTING?(r[a++]=c[0],r[a++]=c[1],f=!1):f=!0,h=c[0],d=c[1],p=g;return(s&&f||u===e+n)&&(r[a++]=h,r[a++]=d),a}drawCustomCoordinates_(t,e,i,n,s){for(let o=0,r=i.length;o<r;++o){const r=i[o],a=this.appendFlatLineCoordinates(t,e,r,n,!1,!1);s.push(a),e=r}return e}drawCustom(t,e,i,n){this.beginGeometry(t,e);const s=t.getType(),o=t.getStride(),r=this.coordinates.length;let a,l,h,d,c;switch(s){case"MultiPolygon":a=t.getOrientedFlatCoordinates(),d=[];const e=t.getEndss();c=0;for(let t=0,i=e.length;t<i;++t){const i=[];c=this.drawCustomCoordinates_(a,c,e[t],o,i),d.push(i)}
1this.instructions.push([ur.CUSTOM,r,d,t,i,Li]),this.hitDetectionInstructions.push([ur.CUSTOM,r,d,t,n||i,Li]);break;case"Polygon":case"MultiLineString":h=[],a="Polygon"==s?t.getOrientedFlatCoordinates():t.getFlatCoordinates(),c=this.drawCustomCoordinates_(a,0,t.getEnds(),o,h),this.instructions.push([ur.CUSTOM,r,h,t,i,Ai]),this.hitDetectionInstructions.push([ur.CUSTOM,r,h,t,n||i,Ai]);break;case"LineString":case"Circle":a=t.getFlatCoordinates(),l=this.appendFlatLineCoordinates(a,0,a.length,o,!1,!1),this.instructions.push([ur.CUSTOM,r,l,t,i,Mi]),this.hitDetectionInstructions.push([ur.CUSTOM,r,l,t,n||i,Mi]);break;case"MultiPoint":a=t.getFlatCoordinates(),l=this.appendFlatPointCoordinates(a,o),l>r&&(this.instructions.push([ur.CUSTOM,r,l,t,i,Mi]),this.hitDetectionInstructions.push([ur.CUSTOM,r,l,t,n||i,Mi]));break;case"Point":a=t.getFlatCoordinates(),this.coordinates.push(a[0],a[1]),l=this.coordinates.length,this.instructions.push([ur.CUSTOM,r,l,t,i]),this.hitDetectionInstructions.push([ur.CUSTOM,r,l,t,n||i])}this.endGeometry(e)}beginGeometry(t,e){this.beginGeometryInstruction1_=[ur.BEGIN_GEOMETRY,e,0,t],this.instructions.push(this.beginGeometryInstruction1_),this.beginGeometryInstruction2_=[ur.BEGIN_GEOMETRY,e,0,t],this.hitDetectionInstructions.push(this.beginGeometryInstruction2_)}finish(){return{instructions:this.instructions,hitDetectionInstructions:this.hitDetectionInstructions,coordinates:this.coordinates}}reverseHitDetectionInstructions(){const t=this.hitDetectionInstructions;let e;t.reverse();const i=t.length;let n,s,o=-1;for(e=0;e<i;++e)n=t[e],s=n[0],s==ur.END_GEOMETRY?o=e:s==ur.BEGIN_GEOMETRY&&(n[2]=e,d(this.hitDetectionInstructions,o,e),o=-1)}setFillStrokeStyle(t,e){const i=this.state;if(t){const e=t.getColor();i.fillStyle=Lo(e||yn)}else i.fillStyle=void 0;if(e){const t=e.getColor();i.strokeStyle=Lo(t||Cn);const n=e.getLineCap();i.lineCap=void 0!==n?n:vn;const s=e.getLineDash();i.lineDash=s?s.slice():xn;const o=e.getLineDashOffset();i.lineDashOffset=o||0;const r=e.getLineJoin();i.lineJoin=void 0!==r?r:wn;const a=e.getWidth();i.lineWidth=void 0!==a?a:1;const l=e.getMiterLimit();i.miterLimit=void 0!==l?l:10,i.lineWidth>this.maxLineWidth&&(this.maxLineWidth=i.lineWidth,this.bufferedMaxExtent_=null)}else i.strokeStyle=void 0,i.lineCap=void 0,i.lineDash=null,i.lineDashOffset=void 0,i.lineJoin=void 0,i.lineWidth=void 0,i.miterLimit=void 0}createFill(t){const e=t.fillStyle,i=[ur.SET_FILL_STYLE,e];return"string"!=typeof e&&i.push(!0),i}applyStroke(t){this.instructions.push(this.createStroke(t))}createStroke(t){return[ur.SET_STROKE_STYLE,t.strokeStyle,t.lineWidth*this.pixelRatio,t.lineCap,t.lineJoin,t.miterLimit,this.applyPixelRatio(t.lineDash),t.lineDashOffset*this.pixelRatio]}updateFillStyle(t,e){const i=t.fillStyle;"string"==typeof i&&t.currentFillStyle==i||(void 0!==i&&this.instructions.push(e.call(this,t)),t.currentFillStyle=i)}updateStrokeStyle(t,e){const i=t.strokeStyle,n=t.lineCap,s=t.lineDash,o=t.lineDashOffset,r=t.lineJoin,a=t.lineWidth,l=t.miterLimit;(t.currentStrokeStyle!=i||t.currentLineCap!=n||s!=t.currentLineDash&&!u(t.currentLineDash,s)||t.currentLineDashOffset!=o||t.currentLineJoin!=r||t.currentLineWidth!=a||t.currentMiterLimit!=l)&&(void 0!==i&&e.call(this,t),t.currentStrokeStyle=i,t.currentLineCap=n,t.currentLineDash=s,t.currentLineDashOffset=o,t.currentLineJoin=r,t.currentLineWidth=a,t.currentMiterLimit=l)}endGeometry(t){this.beginGeometryInstruction1_[2]=this.instructions.length,this.beginGeometryInstruction1_=null,this.beginGeometryInstruction2_[2]=this.hitDetectionInstructions.length,this.beginGeometryInstruction2_=null;const e=[ur.END_GEOMETRY,t];this.instructions.push(e),this.hitDetectionInstructions.push(e)}getBufferedMaxExtent(){if(!this.bufferedMaxExtent_&&(this.bufferedMaxExtent_=at(this.maxExtent),this.maxLineWidth>0)){const t=this.resolution*(this.maxLineWidth+1)/2;rt(this.bufferedMaxExtent_,t,this.bufferedMaxExtent_)}return this.bufferedMaxExtent_}},fr=class extends gr{constructor(t,e,i,n){super(t,e,i,n)}drawFlatCoordinatess_(t,e,i,n){const s=this.state,o=void 0!==s.fillStyle,r=void 0!==s.strokeStyle,a=i.length;this.instructions.push(dr),this.hitDetectionInstructions.push(dr);for(let s=0;s<a;++s){const o=i[s],a=this.coordinates.length,l=this.appendFlatLineCoordinates(t,e,o,n,!0,!r),h=[ur.MOVE_TO_LINE_TO,a,l];this.instructions.push(h),this.hitDetectionInstructions.push(h),r&&(this.instructions.push(cr),this.hitDetectionInstructions.push(cr)),e=o}return o&&(this.instructions.push(lr),this.hitDetectionInstructions.push(lr)),r&&(this.instructions.push(hr),this.hitDetectionInstructions.push(hr)),e}drawCircle(t,e){const i=this.state,n=i.fillStyle,s=i.strokeStyle;if(void 0===n&&void 0===s)return;this.setFillStrokeStyles_(),this.beginGeometry(t,e),void 0!==i.fillStyle&&this.hitDetectionInstructions.push([ur.
1SET_FILL_STYLE,yn]),void 0!==i.strokeStyle&&this.hitDetectionInstructions.push([ur.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,xn,0]);const o=t.getFlatCoordinates(),r=t.getStride(),a=this.coordinates.length;this.appendFlatLineCoordinates(o,0,o.length,r,!1,!1);const l=[ur.CIRCLE,a];this.instructions.push(dr,l),this.hitDetectionInstructions.push(dr,l),void 0!==i.fillStyle&&(this.instructions.push(lr),this.hitDetectionInstructions.push(lr)),void 0!==i.strokeStyle&&(this.instructions.push(hr),this.hitDetectionInstructions.push(hr)),this.endGeometry(e)}drawPolygon(t,e){const i=this.state,n=i.fillStyle,s=i.strokeStyle;if(void 0===n&&void 0===s)return;this.setFillStrokeStyles_(),this.beginGeometry(t,e),void 0!==i.fillStyle&&this.hitDetectionInstructions.push([ur.SET_FILL_STYLE,yn]),void 0!==i.strokeStyle&&this.hitDetectionInstructions.push([ur.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,xn,0]);const o=t.getEnds(),r=t.getOrientedFlatCoordinates(),a=t.getStride();this.drawFlatCoordinatess_(r,0,o,a),this.endGeometry(e)}drawMultiPolygon(t,e){const i=this.state,n=i.fillStyle,s=i.strokeStyle;if(void 0===n&&void 0===s)return;this.setFillStrokeStyles_(),this.beginGeometry(t,e),void 0!==i.fillStyle&&this.hitDetectionInstructions.push([ur.SET_FILL_STYLE,yn]),void 0!==i.strokeStyle&&this.hitDetectionInstructions.push([ur.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,xn,0]);const o=t.getEndss(),r=t.getOrientedFlatCoordinates(),a=t.getStride();let l=0;for(let t=0,e=o.length;t<e;++t)l=this.drawFlatCoordinatess_(r,l,o[t],a);this.endGeometry(e)}finish(){this.reverseHitDetectionInstructions(),this.state=null;const t=this.tolerance;if(0!==t){const e=this.coordinates;for(let i=0,n=e.length;i<n;++i)e[i]=Ri(e[i],t)}return super.finish()}setFillStrokeStyles_(){const t=this.state;void 0!==t.fillStyle&&this.updateFillStyle(t,this.createFill),void 0!==t.strokeStyle&&this.updateStrokeStyle(t,this.applyStroke)}};function mr(t,e,i,n,s){const o=[];let r=i,a=0,l=e.slice(i,2);for(;a<t&&r+s<n;){const[i,n]=l.slice(-2),h=e[r+s],d=e[r+s+1],c=Math.sqrt((h-i)*(h-i)+(d-n)*(d-n));if(a+=c,a>=t){const e=(t-a+c)/c,u=jt(i,h,e),p=jt(n,d,e);l.push(u,p),o.push(l),l=[u,p],a==t&&(r+=s),a=0}else if(a<t)l.push(e[r+s],e[r+s+1]),r+=s;else{const t=c-a,e=jt(i,h,t/c),u=jt(n,d,t/c);l.push(e,u),o.push(l),l=[e,u],a=0,r+=s}}return a>0&&o.push(l),o}function _r(t,e,i,n,s){let o,r,a,l,h,d,c,u,p,g,f=i,m=i,_=0,y=0,v=i;for(r=i;r<n;r+=s){const i=e[r],n=e[r+1];void 0!==h&&(p=i-h,g=n-d,l=Math.sqrt(p*p+g*g),void 0!==c&&(y+=a,o=Math.acos((c*p+u*g)/(a*l)),o>t&&(y>_&&(_=y,f=v,m=r),y=0,v=r-s)),a=l,c=p,u=g),h=i,d=n}return y+=l,y>_?[v,r]:[f,m]}const yr={left:0,center:.5,right:1,top:0,middle:.5,hanging:.2,alphabetic:.8,ideographic:.8,bottom:1},vr={Circle:fr,Default:gr,Image:class extends gr{constructor(t,e,i,n){super(t,e,i,n),this.hitDetectionImage_=null,this.image_=null,this.imagePixelRatio_=void 0,this.anchorX_=void 0,this.anchorY_=void 0,this.height_=void 0,this.opacity_=void 0,this.originX_=void 0,this.originY_=void 0,this.rotateWithView_=void 0,this.rotation_=void 0,this.scale_=void 0,this.width_=void 0,this.declutterMode_=void 0,this.declutterImageWithText_=void 0}drawPoint(t,e){if(!this.image_)return;this.beginGeometry(t,e);const i=t.getFlatCoordinates(),n=t.getStride(),s=this.coordinates.length,o=this.appendFlatPointCoordinates(i,n);this.instructions.push([ur.DRAW_IMAGE,s,o,this.image_,this.anchorX_*this.imagePixelRatio_,this.anchorY_*this.imagePixelRatio_,Math.ceil(this.height_*this.imagePixelRatio_),this.opacity_,this.originX_*this.imagePixelRatio_,this.originY_*this.imagePixelRatio_,this.rotateWithView_,this.rotation_,[this.scale_[0]*this.pixelRatio/this.imagePixelRatio_,this.scale_[1]*this.pixelRatio/this.imagePixelRatio_],Math.ceil(this.width_*this.imagePixelRatio_),this.declutterMode_,this.declutterImageWithText_]),this.hitDetectionInstructions.push([ur.DRAW_IMAGE,s,o,this.hitDetectionImage_,this.anchorX_,this.anchorY_,this.height_,1,this.originX_,this.originY_,this.rotateWithView_,this.rotation_,this.scale_,this.width_,this.declutterMode_,this.declutterImageWithText_]),this.endGeometry(e)}drawMultiPoint(t,e){if(!this.image_)return;this.beginGeometry(t,e);const i=t.getFlatCoordinates(),n=t.getStride(),s=this.coordinates.length,o=this.appendFlatPointCoordinates(i,n);this.instructions.push([ur.DRAW_IMAGE,s,o,this.image_,this.anchorX_*this.imagePixelRatio_,this.anchorY_*this.imagePixelRatio_,Math.
1ceil(this.height_*this.imagePixelRatio_),this.opacity_,this.originX_*this.imagePixelRatio_,this.originY_*this.imagePixelRatio_,this.rotateWithView_,this.rotation_,[this.scale_[0]*this.pixelRatio/this.imagePixelRatio_,this.scale_[1]*this.pixelRatio/this.imagePixelRatio_],Math.ceil(this.width_*this.imagePixelRatio_),this.declutterMode_,this.declutterImageWithText_]),this.hitDetectionInstructions.push([ur.DRAW_IMAGE,s,o,this.hitDetectionImage_,this.anchorX_,this.anchorY_,this.height_,1,this.originX_,this.originY_,this.rotateWithView_,this.rotation_,this.scale_,this.width_,this.declutterMode_,this.declutterImageWithText_]),this.endGeometry(e)}finish(){return this.reverseHitDetectionInstructions(),this.anchorX_=void 0,this.anchorY_=void 0,this.hitDetectionImage_=null,this.image_=null,this.imagePixelRatio_=void 0,this.height_=void 0,this.scale_=void 0,this.opacity_=void 0,this.originX_=void 0,this.originY_=void 0,this.rotateWithView_=void 0,this.rotation_=void 0,this.width_=void 0,super.finish()}setImageStyle(t,e){const i=t.getAnchor(),n=t.getSize(),s=t.getOrigin();this.imagePixelRatio_=t.getPixelRatio(this.pixelRatio),this.anchorX_=i[0],this.anchorY_=i[1],this.hitDetectionImage_=t.getHitDetectionImage(),this.image_=t.getImage(this.pixelRatio),this.height_=n[1],this.opacity_=t.getOpacity(),this.originX_=s[0],this.originY_=s[1],this.rotateWithView_=t.getRotateWithView(),this.rotation_=t.getRotation(),this.scale_=t.getScaleArray(),this.width_=n[0],this.declutterMode_=t.getDeclutterMode(),this.declutterImageWithText_=e}},LineString:class extends gr{constructor(t,e,i,n){super(t,e,i,n)}drawFlatCoordinates_(t,e,i,n){const s=this.coordinates.length,o=this.appendFlatLineCoordinates(t,e,i,n,!1,!1),r=[ur.MOVE_TO_LINE_TO,s,o];return this.instructions.push(r),this.hitDetectionInstructions.push(r),i}drawLineString(t,e){const i=this.state,n=i.strokeStyle,s=i.lineWidth;if(void 0===n||void 0===s)return;this.updateStrokeStyle(i,this.applyStroke),this.beginGeometry(t,e),this.hitDetectionInstructions.push([ur.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,xn,0],dr);const o=t.getFlatCoordinates(),r=t.getStride();this.drawFlatCoordinates_(o,0,o.length,r),this.hitDetectionInstructions.push(hr),this.endGeometry(e)}drawMultiLineString(t,e){const i=this.state,n=i.strokeStyle,s=i.lineWidth;if(void 0===n||void 0===s)return;this.updateStrokeStyle(i,this.applyStroke),this.beginGeometry(t,e),this.hitDetectionInstructions.push([ur.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,xn,0],dr);const o=t.getEnds(),r=t.getFlatCoordinates(),a=t.getStride();let l=0;for(let t=0,e=o.length;t<e;++t)l=this.drawFlatCoordinates_(r,l,o[t],a);this.hitDetectionInstructions.push(hr),this.endGeometry(e)}finish(){const t=this.state;return null!=t.lastStroke&&t.lastStroke!=this.coordinates.length&&this.instructions.push(hr),this.reverseHitDetectionInstructions(),this.state=null,super.finish()}applyStroke(t){null!=t.lastStroke&&t.lastStroke!=this.coordinates.length&&(this.instructions.push(hr),t.lastStroke=this.coordinates.length),t.lastStroke=0,super.applyStroke(t),this.instructions.push(dr)}},Polygon:fr,Text:class extends gr{constructor(t,e,i,n){super(t,e,i,n),this.labels_=null,this.text_="",this.textOffsetX_=0,this.textOffsetY_=0,this.textRotateWithView_=void 0,this.textRotation_=0,this.textFillState_=null,this.fillStates={},this.fillStates[yn]={fillStyle:yn},this.textStrokeState_=null,this.strokeStates={},this.textState_={},this.textStates={},this.textKey_="",this.fillKey_="",this.strokeKey_="",this.declutterImageWithText_=void 0}finish(){const t=super.finish();return t.textStates=this.textStates,t.fillStates=this.fillStates,t.strokeStates=this.strokeStates,t}drawText(t,e){const i=this.textFillState_,n=this.textStrokeState_,s=this.textState_;if(""===this.text_||!s||!i&&!n)return;const o=this.coordinates;let r=o.length;const a=t.getType();let l=null,h=t.getStride();if("line"!==s.placement||"LineString"!=a&&"MultiLineString"!=a&&"Polygon"!=a&&"MultiPolygon"!=a){let i=s.overflow?null:[];switch(a){case"Point":case"MultiPoint":l=t.getFlatCoordinates();break;case"LineString":l=t.getFlatMidpoint();break;case"Circle":l=t.getCenter();break;case"MultiLineString":l=t.getFlatMidpoints(),h=2;break;case"Polygon":l=t.getFlatInteriorPoint(),s.overflow||i.push(l[2]/this.resolution),h=3;break;case"MultiPolygon":const e=t.getFlatInteriorPoints();l=[];for(let t=0,n=e.length;t<n;t+=3)s.overflow||i.push(e[t+2]/this.resolution),l.push(e[t],e[t+1]);if(0===l.length)return;h=2}const n=this.appendFlatPointCoordinates(l,h);if(n===r)return;if(i&&(n-r)/2!=l.length/h){let t=r/2;i=i.filter(((e,i)=>
1{const n=o[2*(t+i)]===l[i*h]&&o[2*(t+i)+1]===l[i*h+1];return n||--t,n}))}this.saveTextStates_(),(s.backgroundFill||s.backgroundStroke)&&(this.setFillStrokeStyle(s.backgroundFill,s.backgroundStroke),s.backgroundFill&&this.updateFillStyle(this.state,this.createFill),s.backgroundStroke&&(this.updateStrokeStyle(this.state,this.applyStroke),this.hitDetectionInstructions.push(this.createStroke(this.state)))),this.beginGeometry(t,e);let d=s.padding;if(d!=bn&&(s.scale[0]<0||s.scale[1]<0)){let t=s.padding[0],e=s.padding[1],i=s.padding[2],n=s.padding[3];s.scale[0]<0&&(e=-e,n=-n),s.scale[1]<0&&(t=-t,i=-i),d=[t,e,i,n]}const c=this.pixelRatio;this.instructions.push([ur.DRAW_IMAGE,r,n,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[1,1],NaN,void 0,this.declutterImageWithText_,d==bn?bn:d.map((function(t){return t*c})),!!s.backgroundFill,!!s.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_,this.textOffsetX_,this.textOffsetY_,i]);const u=1/c,p=this.state.fillStyle;s.backgroundFill&&(this.state.fillStyle=yn,this.hitDetectionInstructions.push(this.createFill(this.state))),this.hitDetectionInstructions.push([ur.DRAW_IMAGE,r,n,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[u,u],NaN,void 0,this.declutterImageWithText_,d,!!s.backgroundFill,!!s.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_?yn:this.fillKey_,this.textOffsetX_,this.textOffsetY_,i]),s.backgroundFill&&(this.state.fillStyle=p,this.hitDetectionInstructions.push(this.createFill(this.state))),this.endGeometry(e)}else{if(!At(this.getBufferedMaxExtent(),t.getExtent()))return;let i;if(l=t.getFlatCoordinates(),"LineString"==a)i=[l.length];else if("MultiLineString"==a)i=t.getEnds();else if("Polygon"==a)i=t.getEnds().slice(0,1);else if("MultiPolygon"==a){const e=t.getEndss();i=[];for(let t=0,n=e.length;t<n;++t)i.push(e[t][0])}this.beginGeometry(t,e);const n=s.repeat,d=n?void 0:s.textAlign;let c=0;for(let t=0,e=i.length;t<e;++t){let e;e=n?mr(n*this.resolution,l,c,i[t],h):[l.slice(c,i[t])];for(let n=0,a=e.length;n<a;++n){const a=e[n];let l=0,u=a.length;if(null==d){const t=_r(s.maxAngle,a,0,a.length,2);l=t[0],u=t[1]}for(let t=l;t<u;t+=h)o.push(a[t],a[t+1]);const p=o.length;c=i[t],this.drawChars_(r,p),r=p}}this.endGeometry(e)}}saveTextStates_(){const t=this.textStrokeState_,e=this.textState_,i=this.textFillState_,n=this.strokeKey_;t&&(n in this.strokeStates||(this.strokeStates[n]={strokeStyle:t.strokeStyle,lineCap:t.lineCap,lineDashOffset:t.lineDashOffset,lineWidth:t.lineWidth,lineJoin:t.lineJoin,miterLimit:t.miterLimit,lineDash:t.lineDash}));const s=this.textKey_;s in this.textStates||(this.textStates[s]={font:e.font,textAlign:e.textAlign||Sn,justify:e.justify,textBaseline:e.textBaseline||Tn,scale:e.scale});const o=this.fillKey_;i&&(o in this.fillStates||(this.fillStates[o]={fillStyle:i.fillStyle}))}drawChars_(t,e){const i=this.textStrokeState_,n=this.textState_,s=this.strokeKey_,o=this.textKey_,r=this.fillKey_;this.saveTextStates_();const a=this.pixelRatio,l=yr[n.textBaseline],h=this.textOffsetY_*a,d=this.text_,c=i?i.lineWidth*Math.abs(n.scale[0])/2:0;this.instructions.push([ur.DRAW_CHARS,t,e,l,n.overflow,r,n.maxAngle,a,h,s,c*a,d,o,1]),this.hitDetectionInstructions.push([ur.DRAW_CHARS,t,e,l,n.overflow,r?yn:r,n.maxAngle,1,h,s,c,d,o,1/a])}setTextStyle(t,e){let i,n,s;
vendor: 4,435 bytes, line 1
1if(t){const e=t.getFill();e?(n=this.textFillState_,n||(n={},this.textFillState_=n),n.fillStyle=Lo(e.getColor()||yn)):(n=null,this.textFillState_=n);const o=t.getStroke();if(o){s=this.textStrokeState_,s||(s={},this.textStrokeState_=s);const t=o.getLineDash(),e=o.getLineDashOffset(),i=o.getWidth(),n=o.getMiterLimit();s.lineCap=o.getLineCap()||vn,s.lineDash=t?t.slice():xn,s.lineDashOffset=void 0===e?0:e,s.lineJoin=o.getLineJoin()||wn,s.lineWidth=void 0===i?1:i,s.miterLimit=void 0===n?10:n,s.strokeStyle=Lo(o.getColor()||Cn)}else s=null,this.textStrokeState_=s;i=this.textState_;const r=t.getFont()||_n;Pn(r);const a=t.getScaleArray();i.overflow=t.getOverflow(),i.font=r,i.maxAngle=t.getMaxAngle(),i.placement=t.getPlacement(),i.textAlign=t.getTextAlign(),i.repeat=t.getRepeat(),i.justify=t.getJustify(),i.textBaseline=t.getTextBaseline()||Tn,i.backgroundFill=t.getBackgroundFill(),i.backgroundStroke=t.getBackgroundStroke(),i.padding=t.getPadding()||bn,i.scale=void 0===a?[1,1]:a;const l=t.getOffsetX(),h=t.getOffsetY(),d=t.getRotateWithView(),c=t.getRotation();this.text_=t.getText()||"",this.textOffsetX_=void 0===l?0:l,this.textOffsetY_=void 0===h?0:h,this.textRotateWithView_=void 0!==d&&d,this.textRotation_=void 0===c?0:c,this.strokeKey_=s?("string"==typeof s.strokeStyle?s.strokeStyle:L(s.strokeStyle))+s.lineCap+s.lineDashOffset+"|"+s.lineWidth+s.lineJoin+s.miterLimit+"["+s.lineDash.join()+"]":"",this.textKey_=i.font+i.scale+(i.textAlign||"?")+(i.repeat||"?")+(i.justify||"?")+(i.textBaseline||"?"),this.fillKey_=n?"string"==typeof n.fillStyle?n.fillStyle:"|"+L(n.fillStyle):""}else this.text_="";this.declutterImageWithText_=e}}},xr=class{constructor(t,e,i,n){this.tolerance_=t,this.maxExtent_=e,this.pixelRatio_=n,this.resolution_=i,this.buildersByZIndex_={}}finish(){const t={};for(const e in this.buildersByZIndex_){t[e]=t[e]||{};const i=this.buildersByZIndex_[e];for(const n in i){const s=i[n].finish();t[e][n]=s}}return t}getBuilder(t,e){const i=void 0!==t?t.toString():"0";let n=this.buildersByZIndex_[i];void 0===n&&(n={},this.buildersByZIndex_[i]=n);let s=n[e];return void 0===s&&(s=new(0,vr[e])(this.tolerance_,this.maxExtent_,this.resolution_,this.pixelRatio_),n[e]=s),s}};function wr(t,e,i,n,s,o,r,a,l,h,d,c){let u=t[e],p=t[e+1],g=0,f=0,m=0,_=0;function y(){g=u,f=p,u=t[e+=n],p=t[e+1],_+=m,m=Math.sqrt((u-g)*(u-g)+(p-f)*(p-f))}do{y()}while(e<i-n&&_+m<o);let v=0===m?0:(o-_)/m;const x=jt(g,u,v),w=jt(f,p,v),C=e-n,S=_,T=o+a*l(h,s,d);for(;e<i-n&&_+m<T;)y();v=0===m?0:(T-_)/m;const b=jt(g,u,v),k=jt(f,p,v);let I;if(c){const t=[x,w,b,k];xi(t,0,4,2,c,t,t),I=t[0]>t[2]}else I=x>b;const E=Math.PI,R=[],P=C+n===e;let M;if(m=0,_=S,u=t[e=C],p=t[e+1],P){y(),M=Math.atan2(p-f,u-g),I&&(M+=M>0?-E:E);const t=(b+x)/2,e=(k+w)/2;return R[0]=[t,e,(T-o)/2,M,s],R}for(let t=0,c=(s=s.replace(/\n/g," ")).length;t<c;){y();let x=Math.atan2(p-f,u-g);if(I&&(x+=x>0?-E:E),void 0!==M){let t=x-M;if(t+=t>E?-2*E:t<-E?2*E:0,Math.abs(t)>r)return null}M=x;const w=t;let C=0;for(;t<c;++t){const r=a*l(h,s[I?c-t-1:t],d);if(e+n<i&&_+m<o+C+r/2)break;C+=r}if(t===w)continue;const S=I?s.substring(c-w,c-t):s.substring(w,t);v=0===m?0:(o+C/2-_)/m;const T=jt(g,u,v),b=jt(f,p,v);R.push([T,b,C/2,x,S]),o+=C}return R}function Cr(t,e,i,n){let s=t[e],o=t[e+1],r=0;for(let a=e+n;a<i;a+=n){const e=t[a],i=t[a+1];r+=Math.sqrt((e-s)*(e-s)+(i-o)*(i-o)),s=e,o=i}return r}const Sr=[1/0,1/0,-1/0,-1/0],Tr=[],br=[],kr=[],Ir=[];function Er(t){return t[3].declutterBox}const Rr=new RegExp("["+String.fromCharCode(1425)+"-"+String.fromCharCode(2303)+String.fromCharCode(64285)+"-"+String.fromCharCode(65023)+String.fromCharCode(65136)+"-"+String.fromCharCode(65276)+String.fromCharCode(67584)+"-"+String.fromCharCode(69631)+String.fromCharCode(124928)+"-"+String.fromCharCode(126975)+"]");function Pr(t,e){return"start"===e?e=Rr.test(t)?"right":"left":"end"===e&&(e=Rr.test(t)?"left":"right"),yr[e]}function Mr(t,e,i){return i>0&&t.push("\n",""),t.push(e,""),t}const Ar=class{constructor(t,e,i,n){this.overlaps=i,this.pixelRatio=e,this.resolution=t,this.alignFill_,this.instructions=n.instructions,this.coordinates=n.coordinates,this.coordinateCache_={},this.renderedTransform_=[1,0,0,1,0,0],this.hitDetectionInstructions=n.hitDetectionInstructions,this.pixelCoordinates_=null,this.viewRotation_=0,this.fillStates=n.fillStates||{},this.strokeStates=n.strokeStates||{},this.textStates=n.textStates||{},this.widths_={},this.labels_={}}createLabel(t,e,i,n){const s=t+e+i+n;
1if(this.labels_[s])return this.labels_[s];const o=n?this.strokeStates[n]:null,r=i?this.fillStates[i]:null,a=this.textStates[e],l=this.pixelRatio,h=[a.scale[0]*l,a.scale[1]*l],d=Array.isArray(t),c=a.justify?yr[a.justify]:Pr(Array.isArray(t)?t[0]:t,a.textAlign||Sn),u=n&&o.lineWidth?o.lineWidth:0,p=d?t:t.split("\n").reduce(Mr,[]),{width:g,height:f,widths:m,heights:_,lineWidths:y}=function(t,e){const i=[],n=[],s=[];let o=0,r=0,a=0,l=0;for(let h=0,d=e.length;h<=d;h+=2){const c=e[h];if("\n"===c||h===d){o=Math.max(o,r),s.push(r),r=0,a+=l;continue}const u=e[h+1]||t.font,p=Ln(u,c);i.push(p),r+=p;const g=Mn(u);n.push(g),l=Math.max(l,g)}return{width:o,height:a,widths:i,heights:n,lineWidths:s}}(a,p),v=g+u,x=[],w=(v+2)*h[0],C=(f+u)*h[1],S={width:w<0?Math.floor(w):Math.ceil(w),height:C<0?Math.floor(C):Math.ceil(C),contextInstructions:x};1==h[0]&&1==h[1]||x.push("scale",h),n&&(x.push("strokeStyle",o.strokeStyle),x.push("lineWidth",u),x.push("lineCap",o.lineCap),x.push("lineJoin",o.lineJoin),x.push("miterLimit",o.miterLimit),x.push("setLineDash",[o.lineDash]),x.push("lineDashOffset",o.lineDashOffset)),i&&x.push("fillStyle",r.fillStyle),x.push("textBaseline","middle"),x.push("textAlign","center");const T=.5-c;let b=c*v+T*u;const k=[],I=[];let E,R=0,P=0,M=0,A=0;for(let t=0,e=p.length;t<e;t+=2){const e=p[t];if("\n"===e){P+=R,R=0,b=c*v+T*u,++A;continue}const s=p[t+1]||a.font;s!==E&&(n&&k.push("font",s),i&&I.push("font",s),E=s),R=Math.max(R,_[M]);const o=[e,b+T*m[M]+c*(m[M]-y[A]),.5*(u+R)+P];b+=m[M],n&&k.push("strokeText",o),i&&I.push("fillText",o),++M}return Array.prototype.push.apply(x,k),Array.prototype.push.apply(x,I),this.labels_[s]=S,S}replayTextBackground_(t,e,i,n,s,o,r){t.beginPath(),t.moveTo.apply(t,e),t.lineTo.apply(t,i),t.lineTo.apply(t,n),t.lineTo.apply(t,s),t.lineTo.apply(t,e),o&&(this.alignFill_=o[2],this.fill_(t)),r&&(this.setStrokeStyle_(t,r),t.stroke())}calculateImageOrLabelDimensions_(t,e,i,n,s,o,r,a,l,h,d,c,u,p,g,f){let m=i-(r*=c[0]),_=n-(a*=c[1]);const y=s+l>t?t-l:s,v=o+h>e?e-h:o,x=p[3]+y*c[0]+p[1],w=p[0]+v*c[1]+p[2],C=m-p[3],S=_-p[0];let T;return(g||0!==d)&&(Tr[0]=C,Ir[0]=C,Tr[1]=S,br[1]=S,br[0]=C+x,kr[0]=br[0],kr[1]=S+w,Ir[1]=kr[1]),0!==d?(T=tt([1,0,0,1,0,0],i,n,1,1,d,-i,-n),Q(T,Tr),Q(T,br),Q(T,kr),Q(T,Ir),pt(Math.min(Tr[0],br[0],kr[0],Ir[0]),Math.min(Tr[1],br[1],
1kr[1],Ir[1]),Math.max(Tr[0],br[0],kr[0],Ir[0]),Math.max(Tr[1],br[1],kr[1],Ir[1]),Sr)):pt(Math.min(C,C+x),Math.min(S,S+w),Math.max(C,C+x),Math.max(S,S+w),Sr),u&&(m=Math.round(m),_=Math.round(_)),{drawImageX:m,drawImageY:_,drawImageW:y,drawImageH:v,originX:l,originY:h,declutterBox:{minX:Sr[0],minY:Sr[1],maxX:Sr[2],maxY:Sr[3],value:f},canvasTransform:T,scale:c}}replayImageOrLabel_(t,e,i,n,s,o,r){const a=!(!o&&!r),l=n.declutterBox,h=t.canvas,d=r?r[2]*n.scale[0]/2:0;return l.minX-d<=h.width/e&&l.maxX+d>=0&&l.minY-d<=h.height/e&&l.maxY+d>=0&&(a&&this.replayTextBackground_(t,Tr,br,kr,Ir,o,r),function(t,e,i,n,s,o,r,a,l,h,d){t.save(),1!==i&&(t.globalAlpha*=i),e&&t.setTransform.apply(t,e),n.contextInstructions?(t.translate(l,h),t.scale(d[0],d[1]),function(t,e){const i=t.contextInstructions;for(let t=0,n=i.length;t<n;t+=2)Array.isArray(i[t+1])?e[i[t]].apply(e,i[t+1]):e[i[t]]=i[t+1]}(n,t)):d[0]<0||d[1]<0?(t.translate(l,h),t.scale(d[0],d[1]),t.drawImage(n,s,o,r,a,0,0,r,a)):t.drawImage(n,s,o,r,a,l,h,r*d[0],a*d[1]),t.restore()}(t,n.canvasTransform,s,i,n.originX,n.originY,n.drawImageW,n.drawImageH,n.drawImageX,n.drawImageY,n.scale)),!0}fill_(t){if(this.alignFill_){const e=Q(this.renderedTransform_,[0,0]),i=512*this.pixelRatio;t.save(),t.translate(e[0]%i,e[1]%i),t.rotate(this.viewRotation_)}t.fill(),this.alignFill_&&t.restore()}setStrokeStyle_(t,e){t.strokeStyle=e[1],t.lineWidth=e[2],t.lineCap=e[3],t.lineJoin=e[4],t.miterLimit=e[5],t.lineDashOffset=e[7],t.setLineDash(e[6])}drawLabelWithPointPlacement_(t,e,i,n){const s=this.textStates[e],o=this.createLabel(t,e,n,i),r=this.strokeStates[i],a=this.pixelRatio,l=Pr(Array.isArray(t)?t[0]:t,s.textAlign||Sn),h=yr[s.textBaseline||Tn],d=r&&r.lineWidth?r.lineWidth:0;return{label:o,anchorX:l*(o.width/a-2*s.scale[0])+2*(.5-l)*d,anchorY:h*o.height/a+2*(.5-h)*d}}execute_(t,e,i,n,s,o,r,a){let l;var h,d;this.pixelCoordinates_&&u(i,this.renderedTransform_)?l=this.pixelCoordinates_:(this.pixelCoordinates_||(this.pixelCoordinates_=[]),l=vi(this.coordinates,0,this.coordinates.length,2,i,this.pixelCoordinates_),d=i,(h=this.renderedTransform_)[0]=d[0],h[1]=d[1],h[2]=d[2],h[3]=d[3],h[4]=d[4],h[5]=d[5]);let c=0;const p=n.length;let g,f,m,_,y,v,x,w,C,S,T,b,k=0,I=0,E=0,R=null,P=null;const M=this.coordinateCache_,A=this.viewRotation_,L=Math.round(1e12*Math.atan2(-i[1],i[0]))/1e12,O={context:t,pixelRatio:this.pixelRatio,resolution:this.resolution,rotation:A},F=this.instructions!=n||this.overlaps?0:200;let D,Z,N,z;for(;c<p;){const i=n[c];switch(i[0]){case ur.BEGIN_GEOMETRY:D=i[1],z=i[3],D.getGeometry()?void 0===r||At(r,z.getExtent())?++c:c=i[2]+1:c=i[2];break;case ur.BEGIN_PATH:I>F&&(this.fill_(t),I=0),E>F&&(t.stroke(),E=0),I||E||(t.beginPath(),_=NaN,y=NaN),++c;break;case ur.CIRCLE:k=i[1];const n=l[k],h=l[k+1],d=l[k+2]-n,u=l[k+3]-h,p=Math.sqrt(d*d+u*u);t.moveTo(n+p,h),t.arc(n,h,p,0,2*Math.PI,!0),++c;break;case ur.CLOSE_PATH:t.closePath(),++c;break;case ur.CUSTOM:k=i[1],g=i[2];const j=i[3],$=i[4],W=6==i.length?i[5]:void 0;O.geometry=j,O.feature=D,c in M||(M[c]=[]);const G=M[c];W?W(l,k,g,2,G):(G[0]=l[k],G[1]=l[k+1],G.length=2),$(G,O),++c;break;case ur.DRAW_IMAGE:k=i[1],g=i[2],w=i[3],f=i[4],m=i[5];let B=i[6];const V=i[7],U=i[8],X=i[9],K=i[10];let Y=i[11];const H=i[12];let q=i[13];const J=i[14],Q=i[15];if(!w&&i.length>=20){C=i[19],S=i[20],T=i[21],b=i[22];const t=this.drawLabelWithPointPlacement_(C,S,T,b);w=t.label,i[3]=w;const e=i[23];f=(t.anchorX-e)*this.pixelRatio,i[4]=f;const n=i[24];m=(t.anchorY-n)*this.pixelRatio,i[5]=m,B=w.height,i[6]=B,q=w.width,i[13]=q}let tt,et,it,nt;i.length>25&&(tt=i[25]),i.length>17?(et=i[16],it=i[17],nt=i[18]):(et=bn,it=!1,nt=!1),K&&L?Y+=A:K||L||(Y-=A);let st=0;for(;k<g;k+=2){if(tt&&tt[st++]<q/this.pixelRatio)continue;const i=this.calculateImageOrLabelDimensions_(w.width,w.height,l[k],l[k+1],q,B,f,m,U,X,Y,H,s,et,it||nt,D),n=[t,e,w,i,V,it?R:null,nt?P:null];if(a){if("none"===J)continue;if("obstacle"===J){a.insert(i.declutterBox);continue}{let t,e;if(Q){const i=g-k;if(!Q[i]){Q[i]=n;continue}if(t=Q[i],delete Q[i],e=Er(t),a.collides(e))continue}if(a.collides(i.declutterBox))continue;t&&(a.insert(e),this.replayImageOrLabel_.apply(this,t)),a.insert(i.declutterBox)}}this.replayImageOrLabel_.apply(this,n)}++c;break;case ur.DRAW_CHARS:const ot=i[1],rt=i[2],at=i[3],lt=i[4];b=i[5];const ht=i[6],dt=i[7],ct=i[8];T=i[9];const ut=i[10];C=i[11],S=i[12];
1const pt=[i[13],i[13]],gt=this.textStates[S],ft=gt.font,mt=[gt.scale[0]*dt,gt.scale[1]*dt];let _t;ft in this.widths_?_t=this.widths_[ft]:(_t={},this.widths_[ft]=_t);const yt=Cr(l,ot,rt,2),vt=Math.abs(mt[0])*On(ft,C,_t);if(lt||vt<=yt){const i=wr(l,ot,rt,2,C,(yt-vt)*Pr(C,this.textStates[S].textAlign),ht,Math.abs(mt[0]),On,ft,_t,L?0:this.viewRotation_);t:if(i){const n=[];let s,o,r,l,h;if(T)for(s=0,o=i.length;s<o;++s){h=i[s],r=h[4],l=this.createLabel(r,S,"",T),f=h[2]+(mt[0]<0?-ut:ut),m=at*l.height+2*(.5-at)*ut*mt[1]/mt[0]-ct;const o=this.calculateImageOrLabelDimensions_(l.width,l.height,h[0],h[1],l.width,l.height,f,m,0,0,h[3],pt,!1,bn,!1,D);if(a&&a.collides(o.declutterBox))break t;n.push([t,e,l,o,1,null,null])}if(b)for(s=0,o=i.length;s<o;++s){h=i[s],r=h[4],l=this.createLabel(r,S,b,""),f=h[2],m=at*l.height-ct;const o=this.calculateImageOrLabelDimensions_(l.width,l.height,h[0],h[1],l.width,l.height,f,m,0,0,h[3],pt,!1,bn,!1,D);if(a&&a.collides(o.declutterBox))break t;n.push([t,e,l,o,1,null,null])}a&&a.load(n.map(Er));for(let t=0,e=n.length;t<e;++t)this.replayImageOrLabel_.apply(this,n[t])}}++c;break;case ur.END_GEOMETRY:if(void 0!==o){D=i[1];const t=o(D,z);if(t)return t}++c;break;case ur.FILL:F?I++:this.fill_(t),++c;break;case ur.MOVE_TO_LINE_TO:for(k=i[1],g=i[2],Z=l[k],N=l[k+1],v=Z+.5|0,x=N+.5|0,v===_&&x===y||(t.moveTo(Z,N),_=v,y=x),k+=2;k<g;k+=2)Z=l[k],N=l[k+1],v=Z+.5|0,x=N+.5|0,k!=g-2&&v===_&&x===y||(t.lineTo(Z,N),_=v,y=x);++c;break;case ur.SET_FILL_STYLE:R=i,this.alignFill_=i[2],I&&(this.fill_(t),I=0,E&&(t.stroke(),E=0)),t.fillStyle=i[1],++c;break;case ur.SET_STROKE_STYLE:P=i,E&&(t.stroke(),E=0),this.setStrokeStyle_(t,i),++c;break;case ur.STROKE:F?E++:t.stroke(),++c;break;default:++c}}I&&this.fill_(t),E&&t.stroke()}execute(t,e,i,n,s,o){this.viewRotation_=n,this.execute_(t,e,i,this.instructions,s,void 0,void 0,o)}executeHitDetection(t,e,i,n,s){return this.viewRotation_=i,this.execute_(t,1,e,this.hitDetectionInstructions,!0,n,s)}},Lr=["Polygon","Circle","LineString","Image","Text","Default"],Or={},Fr=class{constructor(t,e,i,n,s,o){this.maxExtent_=t,this.overlaps_=n,this.pixelRatio_=i,this.resolution_=e,this.renderBuffer_=o,this.executorsByZIndex_={},this.hitDetectionContext_=null,this.hitDetectionTransform_=[1,0,0,1,0,0],this.createExecutors_(s)}clip(t,e){const i=this.getClipCoords(e);t.beginPath(),t.moveTo(i[0],i[1]),t.lineTo(i[2],i[3]),t.lineTo(i[4],i[5]),t.lineTo(i[6],i[7]),t.clip()}createExecutors_(t){for(const e in t){let i=this.executorsByZIndex_[e];void 0===i&&(i={},this.executorsByZIndex_[e]=i);const n=t[e];for(const t in n){const e=n[t];i[t]=new Ar(this.resolution_,this.pixelRatio_,this.overlaps_,e)}}}hasExecutors(t){for(const e in this.executorsByZIndex_){const i=this.executorsByZIndex_[e];for(let e=0,n=t.length;e<n;++e)if(t[e]in i)return!0}return!1}forEachFeatureAtCoordinate(t,e,i,n,s,o){const r=2*(n=Math.round(n))+1,a=tt(this.hitDetectionTransform_,n+.5,n+.5,1/e,-1/e,-i,-t[0],-t[1]),h=!this.hitDetectionContext_;h&&(this.hitDetectionContext_=pn(r,r,void 0,{willReadFrequently:!0}));const d=this.hitDetectionContext_;let c;d.canvas.width!==r||d.canvas.height!==r?(d.canvas.width=r,d.canvas.height=r):h||d.clearRect(0,0,r,r),void 0!==this.renderBuffer_&&(c=[1/0,1/0,-1/0,-1/0],mt(c,t),rt(c,e*(this.renderBuffer_+n),c));const u=function(t){if(void 0!==Or[t])return Or[t];const e=2*t+1,i=t*t,n=new Array(i+1);for(let s=0;s<=t;++s)for(let o=0;o<=t;++o){const r=s*s+o*o;if(r>i)break;let a=n[r];a||(a=[],n[r]=a),a.push(4*((t+s)*e+(t+o))+3),s>0&&a.push(4*((t-s)*e+(t+o))+3),o>0&&(a.push(4*((t+s)*e+(t-o))+3),s>0&&a.push(4*((t-s)*e+(t-o))+3))}const s=[];for(let t=0,e=n.length;t<e;++t)n[t]&&s.push(...n[t]);return Or[t]=s,s}(n);let p;function g(t,e){const i=d.getImageData(0,0,r,r).data;for(let a=0,l=u.length;a<l;a++)if(i[u[a]]>0){if(!o||"Image"!==p&&"Text"!==p||o.includes(t)){const i=(u[a]-3)/4,o=n-i%r,l=n-(i/r|0),h=s(t,e,o*o+l*l);if(h)return h}d.clearRect(0,0,r,r);break}}const f=Object.keys(this.executorsByZIndex_).map(Number);let m,_,y,v,x;for(f.sort(l),m=f.length-1;m>=0;--m){const t=f[m].toString();for(y=this.executorsByZIndex_[t],_=Lr.length-1;_>=0;--_)if(p=Lr[_],v=y[p],void 0!==v&&(x=v.executeHitDetection(d,a,i,g,c),x))return x}}getClipCoords(t){const e=this.maxExtent_;if(!e)return null;const i=e[0],n=e[1],s=e[2],o=e[3],r=[i,n,i,o,s,o,s,n];return vi(r,0,8,2,t,r),r}isEmpty(){return _(this.executorsByZIndex_)}execute(t,e,i,n,s,o,r){const a=Object.keys(this.executorsByZIndex_).map(Number);let h,d,c,u,p,g;for(a.sort(l),this.maxExtent_&&(t.save(),this.clip(t,i)),o=o||Lr,r&&a.reverse(),h=0,d=a.length;h<d;++h){const l=a[h].toString();for(p=this.executorsByZIndex_[l],c=0,u=o.length;c<u;++c)g=p[o[c]],void 0!==g&&g.execute(t,e,i,n,s,r)}
vendor: 9,305 bytes, line 1
1this.maxExtent_&&t.restore()}},Dr=class extends pr{constructor(t,e,i,n,s,o,r){super(),this.context_=t,this.pixelRatio_=e,this.extent_=i,this.transform_=n,this.transformRotation_=n?$t(Math.atan2(n[1],n[0]),10):0,this.viewRotation_=s,this.squaredTolerance_=o,this.userTransform_=r,this.contextFillState_=null,this.contextStrokeState_=null,this.contextTextState_=null,this.fillState_=null,this.strokeState_=null,this.image_=null,this.imageAnchorX_=0,this.imageAnchorY_=0,this.imageHeight_=0,this.imageOpacity_=0,this.imageOriginX_=0,this.imageOriginY_=0,this.imageRotateWithView_=!1,this.imageRotation_=0,this.imageScale_=[0,0],this.imageWidth_=0,this.text_="",this.textOffsetX_=0,this.textOffsetY_=0,this.textRotateWithView_=!1,this.textRotation_=0,this.textScale_=[0,0],this.textFillState_=null,this.textStrokeState_=null,this.textState_=null,this.pixelCoordinates_=[],this.tmpLocalTransform_=[1,0,0,1,0,0]}drawImages_(t,e,i,n){if(!this.image_)return;const s=vi(t,e,i,n,this.transform_,this.pixelCoordinates_),o=this.context_,r=this.tmpLocalTransform_,a=o.globalAlpha;1!=this.imageOpacity_&&(o.globalAlpha=a*this.imageOpacity_);let l=this.imageRotation_;0===this.transformRotation_&&(l-=this.viewRotation_),this.imageRotateWithView_&&(l+=this.viewRotation_);for(let t=0,e=s.length;t<e;t+=2){const e=s[t]-this.imageAnchorX_,i=s[t+1]-this.imageAnchorY_;if(0!==l||1!=this.imageScale_[0]||1!=this.imageScale_[1]){const t=e+this.imageAnchorX_,n=i+this.imageAnchorY_;tt(r,t,n,1,1,l,-t,-n),o.setTransform.apply(o,r),o.translate(t,n),o.scale(this.imageScale_[0],this.imageScale_[1]),o.drawImage(this.image_,this.imageOriginX_,this.imageOriginY_,this.imageWidth_,this.imageHeight_,-this.imageAnchorX_,-this.imageAnchorY_,this.imageWidth_,this.imageHeight_),o.setTransform(1,0,0,1,0,0)}else o.drawImage(this.image_,this.imageOriginX_,this.imageOriginY_,this.imageWidth_,this.imageHeight_,e,i,this.imageWidth_,this.imageHeight_)}1!=this.imageOpacity_&&(o.globalAlpha=a)}drawText_(t,e,i,n){if(!this.textState_||""===this.text_)return;this.textFillState_&&this.setContextFillState_(this.textFillState_),this.textStrokeState_&&this.setContextStrokeState_(this.textStrokeState_),this.setContextTextState_(this.textState_);const s=vi(t,e,i,n,this.transform_,this.pixelCoordinates_),o=this.context_;let r=this.textRotation_;for(0===this.transformRotation_&&(r-=this.viewRotation_),this.textRotateWithView_&&(r+=this.viewRotation_);e<i;e+=n){const t=s[e]+this.textOffsetX_,i=s[e+1]+this.textOffsetY_;0!==r||1!=this.textScale_[0]||1!=this.textScale_[1]?(o.translate(t-this.textOffsetX_,i-this.textOffsetY_),o.rotate(r),o.translate(this.textOffsetX_,this.textOffsetY_),o.scale(this.textScale_[0],this.textScale_[1]),this.textStrokeState_&&o.strokeText(this.text_,0,0),this.textFillState_&&o.fillText(this.text_,0,0),o.setTransform(1,0,0,1,0,0)):(this.textStrokeState_&&o.strokeText(this.text_,t,i),this.textFillState_&&o.fillText(this.text_,t,i))}}moveToLineTo_(t,e,i,n,s){const o=this.context_,r=vi(t,e,i,n,this.transform_,this.pixelCoordinates_);o.moveTo(r[0],r[1]);let a=r.length;s&&(a-=2);for(let t=2;t<a;t+=2)o.lineTo(r[t],r[t+1]);return s&&o.closePath(),i}drawRings_(t,e,i,n){for(let s=0,o=i.length;s<o;++s)e=this.moveToLineTo_(t,e,i[s],n,!0);return e}drawCircle(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),At(this.extent_,t.getExtent())){if(this.fillState_||this.strokeState_){this.fillState_&&this.setContextFillState_(this.fillState_),this.strokeState_&&this.setContextStrokeState_(this.strokeState_);const e=function(t,e,i){const n=t.getFlatCoordinates();if(!n)return null;const s=t.getStride();return vi(n,0,n.length,s,e,i)}(t,this.transform_,this.pixelCoordinates_),i=e[2]-e[0],n=e[3]-e[1],s=Math.sqrt(i*i+n*n),o=this.context_;o.beginPath(),o.arc(e[0],e[1],s,0,2*Math.PI),this.fillState_&&o.fill(),this.strokeState_&&o.stroke()}""!==this.text_&&this.drawText_(t.getCenter(),0,2,2)}}setStyle(t){this.setFillStrokeStyle(t.getFill(),t.getStroke()),this.setImageStyle(t.getImage()),this.setTextStyle(t.getText())}setTransform(t){this.transform_=t}drawGeometry(t){switch(t.getType()){case"Point":this.drawPoint(t);break;case"LineString":this.drawLineString(t);break;case"Polygon":this.drawPolygon(t);break;case"MultiPoint":this.drawMultiPoint(t);break;case"MultiLineString":this.drawMultiLineString(t);break;case"MultiPolygon":this.drawMultiPolygon(t);break;case"GeometryCollection":this.drawGeometryCollection(t);break;case"Circle":this.drawCircle(t)}}drawFeature(t,e){const i=e.getGeometryFunction()(t);i&&(this.setStyle(e),this.drawGeometry(i))}drawGeometryCollection(t){const e=t.getGeometriesArray();for(let t=0,i=e.length;t<i;++t)this.drawGeometry(e[t])}drawPoint(t){this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_));const e=t.getFlatCoordinates(),i=t.getStride();this.image_&&this.drawImages_(e,0,e.length,i),""!==this.text_&&this.drawText_(e,0,e.length,i)}drawMultiPoint(t){this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_));const e=t.getFlatCoordinates(),i=t.getStride();this.image_&&this.drawImages_(e,0,e.length,i),""!==this.text_&&this.drawText_(e,0,e.length,i)}drawLineString(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),At(this.extent_,t.getExtent())){if(this.strokeState_){this.setContextStrokeState_(this.strokeState_);const e=this.context_,i=t.getFlatCoordinates();e.beginPath(),this.moveToLineTo_(i,0,i.length,t.getStride(),!1),e.stroke()}if(""!==this.text_){const e=t.getFlatMidpoint();this.drawText_(e,0,2,2)}}}drawMultiLineString(t){this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_));const e=t.getExtent();if(At(this.extent_,e)){if(this.strokeState_){this.setContextStrokeState_(this.strokeState_);const e=this.context_,i=t.getFlatCoordinates();let n=0;const s=t.getEnds(),o=t.getStride();e.beginPath();for(let t=0,e=s.length;t<e;++t)n=this.moveToLineTo_(i,n,s[t],o,!1);e.stroke()}if(""!==this.text_){const e=t.getFlatMidpoints();this.drawText_(e,0,e.length,2)}}}drawPolygon(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),At(this.extent_,t.getExtent())){if(this.strokeState_||this.fillState_){this.fillState_&&this.setContextFillState_(this.fillState_),this.strokeState_&&this.setContextStrokeState_(this.strokeState_);const e=this.context_;e.beginPath(),this.drawRings_(t.getOrientedFlatCoordinates(),0,t.getEnds(),t.getStride()),this.fillState_&&e.fill(),this.strokeState_&&e.stroke()}if(""!==this.text_){const e=t.getFlatInteriorPoint();this.drawText_(e,0,2,2)}}}drawMultiPolygon(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),At(this.extent_,t.getExtent())){if(this.strokeState_||this.fillState_){this.fillState_&&this.setContextFillState_(this.fillState_),this.strokeState_&&this.setContextStrokeState_(this.strokeState_);const e=this.context_,i=t.getOrientedFlatCoordinates();let n=0;const s=t.getEndss(),o=t.getStride();e.beginPath();for(let t=0,e=s.length;t<e;++t){const e=s[t];n=this.drawRings_(i,n,e,o)}this.fillState_&&e.fill(),this.strokeState_&&e.stroke()}if(""!==this.text_){const e=t.getFlatInteriorPoints();this.drawText_(e,0,e.length,2)}}}setContextFillState_(t){const e=this.context_,i=this.contextFillState_;i?i.fillStyle!=t.fillStyle&&(i.fillStyle=t.fillStyle,e.fillStyle=t.fillStyle):(e.fillStyle=t.fillStyle,this.contextFillState_={fillStyle:t.fillStyle})}setContextStrokeState_(t){const e=this.context_,i=this.contextStrokeState_;i?(i.lineCap!=t.lineCap&&(i.lineCap=t.lineCap,e.lineCap=t.lineCap),u(i.lineDash,t.lineDash)||e.setLineDash(i.lineDash=t.lineDash),i.lineDashOffset!=t.lineDashOffset&&(i.lineDashOffset=t.lineDashOffset,e.lineDashOffset=t.lineDashOffset),i.lineJoin!=t.lineJoin&&(i.lineJoin=t.lineJoin,e.lineJoin=t.lineJoin),i.lineWidth!=t.lineWidth&&(i.lineWidth=t.lineWidth,e.lineWidth=t.lineWidth),i.miterLimit!=t.miterLimit&&(i.miterLimit=t.miterLimit,e.miterLimit=t.miterLimit),i.strokeStyle!=t.strokeStyle&&(i.strokeStyle=t.strokeStyle,e.strokeStyle=t.strokeStyle)):(e.lineCap=t.lineCap,e.setLineDash(t.lineDash),e.lineDashOffset=t.lineDashOffset,e.lineJoin=t.lineJoin,e.lineWidth=t.lineWidth,e.miterLimit=t.miterLimit,e.strokeStyle=t.strokeStyle,this.contextStrokeState_={lineCap:t.lineCap,lineDash:t.lineDash,lineDashOffset:t.lineDashOffset,lineJoin:t.lineJoin,lineWidth:t.lineWidth,miterLimit:t.miterLimit,strokeStyle:t.strokeStyle})}setContextTextState_(t){const e=this.context_,i=this.contextTextState_,n=t.textAlign?t.textAlign:Sn;i?(i.font!=t.font&&(i.font=t.font,e.font=t.font),i.textAlign!=n&&(i.textAlign=n,e.textAlign=n),i.textBaseline!=t.textBaseline&&(i.textBaseline=t.textBaseline,e.textBaseline=t.textBaseline)):(e.font=t.font,e.textAlign=n,e.textBaseline=t.textBaseline,this.contextTextState_={font:t.font,textAlign:n,textBaseline:t.textBaseline})}setFillStrokeStyle(t,e){if(t){const e=t.getColor();this.fillState_={fillStyle:Lo(e||yn)}}else this.fillState_=null;if(e){const t=e.getColor(),i=e.getLineCap(),n=e.getLineDash(),s=e.getLineDashOffset(),o=e.getLineJoin(),r=e.getWidth(),a=e.getMiterLimit(),l=n||xn;this.strokeState_={lineCap:void 0!==i?i:vn,lineDash:1===this.pixelRatio_?l:l.map((t=>
1t*this.pixelRatio_)),lineDashOffset:(s||0)*this.pixelRatio_,lineJoin:void 0!==o?o:wn,lineWidth:(void 0!==r?r:1)*this.pixelRatio_,miterLimit:void 0!==a?a:10,strokeStyle:Lo(t||Cn)}}else this.strokeState_=null}setImageStyle(t){let e;if(!t||!(e=t.getSize()))return void(this.image_=null);const i=t.getPixelRatio(this.pixelRatio_),n=t.getAnchor(),s=t.getOrigin();this.image_=t.getImage(this.pixelRatio_),this.imageAnchorX_=n[0]*i,this.imageAnchorY_=n[1]*i,this.imageHeight_=e[1]*i,this.imageOpacity_=t.getOpacity(),this.imageOriginX_=s[0],this.imageOriginY_=s[1],this.imageRotateWithView_=t.getRotateWithView(),this.imageRotation_=t.getRotation();const o=t.getScaleArray();this.imageScale_=[o[0]*this.pixelRatio_/i,o[1]*this.pixelRatio_/i],this.imageWidth_=e[0]*i}setTextStyle(t){if(t){const e=t.getFill();if(e){const t=e.getColor();this.textFillState_={fillStyle:Lo(t||yn)}}else this.textFillState_=null;const i=t.getStroke();if(i){const t=i.getColor(),e=i.getLineCap(),n=i.getLineDash(),s=i.getLineDashOffset(),o=i.getLineJoin(),r=i.getWidth(),a=i.getMiterLimit();this.textStrokeState_={lineCap:void 0!==e?e:vn,lineDash:n||xn,lineDashOffset:s||0,lineJoin:void 0!==o?o:wn,lineWidth:void 0!==r?r:1,miterLimit:void 0!==a?a:10,strokeStyle:Lo(t||Cn)}}else this.textStrokeState_=null;const n=t.getFont(),s=t.getOffsetX(),o=t.getOffsetY(),r=t.getRotateWithView(),a=t.getRotation(),l=t.getScaleArray(),h=t.getText(),d=t.getTextAlign(),c=t.getTextBaseline();this.textState_={font:void 0!==n?n:_n,textAlign:void 0!==d?d:Sn,textBaseline:void 0!==c?c:Tn},this.text_=void 0!==h?Array.isArray(h)?h.reduce(((t,e,i)=>t+(i%2?" ":e)),""):h:"",this.textOffsetX_=void 0!==s?this.pixelRatio_*s:0,this.textOffsetY_=void 0!==o?this.pixelRatio_*o:0,this.textRotateWithView_=void 0!==r&&r,this.textRotation_=void 0!==a?a:0,this.textScale_=[this.pixelRatio_*l[0],this.pixelRatio_*l[1]]}else this.text_=""}},Zr=.5,Nr={Point:function(t,e,i,n,s){const o=i.getImage(),r=i.getText();let a;if(o){if(2!=o.getImageState())return;let l=t;if(s){const h=o.getDeclutterMode();if("none"!==h)if(l=s,"obstacle"===h){const s=t.getBuilder(i.getZIndex(),"Image");s.setImageStyle(o,a),s.drawPoint(e,n)}else r&&r.getText()&&(a={})}const h=l.getBuilder(i.getZIndex(),"Image");h.setImageStyle(o,a),h.drawPoint(e,n)}if(r&&r.getText()){let o=t;s&&(o=s);const l=o.getBuilder(i.getZIndex(),"Text");l.setTextStyle(r,a),l.drawText(e,n)}},LineString:function(t,e,i,n,s){const o=i.getStroke();if(o){const s=t.getBuilder(i.getZIndex(),"LineString");s.setFillStrokeStyle(null,o),s.drawLineString(e,n)}const r=i.getText();if(r&&r.getText()){const o=(s||t).getBuilder(i.getZIndex(),"Text");o.setTextStyle(r),o.drawText(e,n)}},Polygon:function(t,e,i,n,s){const o=i.getFill(),r=i.getStroke();if(o||r){const s=t.getBuilder(i.getZIndex(),"Polygon");s.setFillStrokeStyle(o,r),s.drawPolygon(e,n)}const a=i.getText();if(a&&a.getText()){const o=(s||t).getBuilder(i.getZIndex(),"Text");o.setTextStyle(a),o.drawText(e,n)}},MultiPoint:function(t,e,i,n,s){const o=i.getImage(),r=i.getText();let a;if(o){if(2!=o.getImageState())return;let l=t;if(s){const h=o.getDeclutterMode();if("none"!==h)if(l=s,"obstacle"===h){const s=t.getBuilder(i.getZIndex(),"Image");s.setImageStyle(o,a),s.drawMultiPoint(e,n)}else r&&r.getText()&&(a={})}const h=l.getBuilder(i.getZIndex(),"Image");h.setImageStyle(o,a),h.drawMultiPoint(e,n)}if(r&&r.getText()){let o=t;s&&(o=s);const l=o.getBuilder(i.getZIndex(),"Text");l.setTextStyle(r,a),l.drawText(e,n)}},MultiLineString:function(t,e,i,n,s){const o=i.getStroke();if(o){const s=t.getBuilder(i.getZIndex(),"LineString");s.setFillStrokeStyle(null,o),s.drawMultiLineString(e,n)}const r=i.getText();if(r&&r.getText()){const o=(s||t).getBuilder(i.getZIndex(),"Text");o.setTextStyle(r),o.drawText(e,n)}},MultiPolygon:function(t,e,i,n,s){const o=i.getFill(),r=i.getStroke();if(r||o){const s=t.getBuilder(i.getZIndex(),"Polygon");s.setFillStrokeStyle(o,r),s.drawMultiPolygon(e,n)}const a=i.getText();if(a&&a.getText()){const o=(s||t).getBuilder(i.getZIndex(),"Text");o.setTextStyle(a),o.drawText(e,n)}},GeometryCollection:function(t,e,i,n,s){const o=e.getGeometriesArray();let r,a;for(r=0,a=o.length;r<a;++r)(0,Nr[o[r].getType()])(t,o[r],i,n,s)}
1,Circle:function(t,e,i,n,s){const o=i.getFill(),r=i.getStroke();if(o||r){const s=t.getBuilder(i.getZIndex(),"Circle");s.setFillStrokeStyle(o,r),s.drawCircle(e,n)}const a=i.getText();if(a&&a.getText()){const o=(s||t).getBuilder(i.getZIndex(),"Text");o.setTextStyle(a),o.drawText(e,n)}}};function zr(t,e){return parseInt(L(t),10)-parseInt(L(e),10)}function jr(t,e){return.5*t/e}function $r(t,e,i,n,s,o,r){let a=!1;const l=i.getImage();if(l){const t=l.getImageState();2==t||3==t?l.unlistenImageChange(s):(0==t&&l.load(),l.listenImageChange(s),a=!0)}return function(t,e,i,n,s,o){const r=i.getGeometryFunction()(e);if(!r)return;const a=r.simplifyTransformed(n,s);i.getRenderer()?Wr(t,a,i,e):(0,Nr[a.getType()])(t,a,i,e,o)}(t,e,i,n,o,r),a}function Wr(t,e,i,n){if("GeometryCollection"!=e.getType())t.getBuilder(i.getZIndex(),"Default").drawCustom(e,n,i.getRenderer(),i.getHitDetectionRenderer());else{const s=e.getGeometries();for(let e=0,o=s.length;e<o;++e)Wr(t,s[e],i,n)}}const Gr=class extends Xs{constructor(t){super(t),this.boundHandleStyleImageChange_=this.handleStyleImageChange_.bind(this),this.animatingOrInteracting_,this.hitDetectionImageData_=null,this.renderedFeatures_=null,this.renderedRevision_=-1,this.renderedResolution_=NaN,this.renderedExtent_=[1/0,1/0,-1/0,-1/0],this.wrappedRenderedExtent_=[1/0,1/0,-1/0,-1/0],this.renderedRotation_,this.renderedCenter_=null,this.renderedProjection_=null,this.renderedRenderOrder_=null,this.replayGroup_=null,this.replayGroupChanged=!0,this.declutterExecutorGroup=null,this.clipping=!0,this.compositionContext_=null,this.opacity_=1}renderWorlds(t,e,i){const n=e.extent,s=e.viewState,o=s.center,r=s.resolution,a=s.projection,l=s.rotation,h=a.getExtent(),d=this.getLayer().getSource(),c=e.pixelRatio,u=e.viewHints,p=!(u[0]||u[1]),g=this.compositionContext_,f=Math.round(e.size[0]*c),m=Math.round(e.size[1]*c),_=d.getWrapX()&&a.canWrapX(),y=_?Mt(h):null,v=_?Math.ceil((n[2]-h[2])/y)+1:1;let x=_?Math.floor((n[0]-h[0])/y):0;do{const e=this.getRenderTransform(o,r,l,c,f,m,x*y);t.execute(g,1,e,l,p,void 0,i)}while(++x<v)}setupCompositionContext_(){if(1!==this.opacity_){const t=pn(this.context.canvas.width,this.context.canvas.height,Vs);this.compositionContext_=t}else this.compositionContext_=this.context}releaseCompositionContext_(){if(1!==this.opacity_){const t=this.context.globalAlpha;this.context.globalAlpha=this.opacity_,this.context.drawImage(this.compositionContext_.canvas,0,0),this.context.globalAlpha=t,gn(this.compositionContext_),Vs.push(this.compositionContext_.canvas),this.compositionContext_=null}}renderDeclutter(t){this.declutterExecutorGroup&&(this.setupCompositionContext_(),this.renderWorlds(this.declutterExecutorGroup,t,t.declutterTree),this.releaseCompositionContext_())}renderFrame(t,e){const i=t.pixelRatio,n=t.layerStatesArray[t.layerIndex];!function(t,e,i){!function(t,e,i,n,s,o,r){t[0]=e,t[1]=i,t[2]=n,t[3]=s,t[4]=o,t[5]=r}(t,e,0,0,i,0,0)}(this.pixelTransform,1/i,1/i),et(this.inversePixelTransform,this.pixelTransform);const s=nt(this.pixelTransform);this.useContainer(e,s,this.getBackground(t));const o=this.context,r=o.canvas,a=this.replayGroup_,l=this.declutterExecutorGroup;let h=a&&!a.isEmpty()||l&&!l.isEmpty();if(!h&&!this.getLayer().hasListener(he)&&!this.getLayer().hasListener(de))return null;const d=Math.round(t.size[0]*i),c=Math.round(t.size[1]*i);r.width!=d||r.height!=c?(r.width=d,r.height=c,r.style.transform!==s&&(r.style.transform=s)):this.containerReused||o.clearRect(0,0,d,c),this.preRender(o,t);const u=t.viewState;u.projection;this.opacity_=n.opacity,this.setupCompositionContext_();let p=!1;if(h&&n.extent&&this.clipping){const e=ni(n.extent);h=At(e,t.extent),p=h&&!dt(e,t.extent),p&&this.clipUnrotated(this.compositionContext_,t,e)}return h&&this.renderWorlds(a,t),p&&this.compositionContext_.restore(),this.releaseCompositionContext_(),this.postRender(o,t),this.renderedRotation_!==u.rotation&&(this.renderedRotation_=u.rotation,this.hitDetectionImageData_=null),this.container}getFeatures(t){return new Promise((e=>{if(!this.hitDetectionImageData_&&!this.animatingOrInteracting_){const t=[this.context.canvas.width,this.context.canvas.height];Q(this.pixelTransform,t);const e=this.renderedCenter_,i=this.renderedResolution_,n=this.renderedRotation_,s=this.renderedProjection_,o=this.wrappedRenderedExtent_,r=this.getLayer(),a=[],h=t[0]*Zr,d=t[1]*Zr;a.push(this.getRenderTransform(e,i,n,Zr,h,d,0).slice());const c=r.getSource(),u=s.getExtent();
1if(c.getWrapX()&&s.canWrapX()&&!dt(u,o)){let t=o[0];const s=Mt(u);let r,l=0;for(;t<u[0];)--l,r=s*l,a.push(this.getRenderTransform(e,i,n,Zr,h,d,r).slice()),t+=s;for(l=0,t=o[2];t>u[2];)++l,r=s*l,a.push(this.getRenderTransform(e,i,n,Zr,h,d,r).slice()),t-=s}this.hitDetectionImageData_=function(t,e,i,n,s,o,r){const a=pn(t[0]*Zr,t[1]*Zr);a.imageSmoothingEnabled=!1;const h=a.canvas,d=new Dr(a,Zr,s,null,r),c=i.length,u=Math.floor(16777215/c),p={};for(let t=1;t<=c;++t){const e=i[t-1],r=e.getStyleFunction()||n;if(!r)continue;let a=r(e,o);if(!a)continue;Array.isArray(a)||(a=[a]);const l=(t*u).toString(16).padStart(7,"#00000");for(let t=0,i=a.length;t<i;++t){const i=a[t],n=i.getGeometryFunction()(e);if(!n||!At(s,n.getExtent()))continue;const o=i.clone(),r=o.getFill();r&&r.setColor(l);const h=o.getStroke();h&&(h.setColor(l),h.setLineDash(null)),o.setText(void 0);const d=i.getImage();if(d){const t=d.getImageSize();if(!t)continue;const e=pn(t[0],t[1],void 0,{alpha:!1}),i=e.canvas;e.fillStyle=l,e.fillRect(0,0,i.width,i.height),o.setImage(new qo({img:i,imgSize:t,anchor:d.getAnchor(),anchorXUnits:"pixels",anchorYUnits:"pixels",offset:d.getOrigin(),opacity:1,size:d.getSize(),scale:d.getScale(),rotation:d.getRotation(),rotateWithView:d.getRotateWithView()}))}const c=o.getZIndex()||0;let u=p[c];u||(u={},p[c]=u,u.Polygon=[],u.Circle=[],u.LineString=[],u.Point=[]);const g=n.getType();if("GeometryCollection"===g){const t=n.getGeometriesArrayRecursive();for(let e=0,i=t.length;e<i;++e){const i=t[e];u[i.getType().replace("Multi","")].push(i,o)}}else u[g.replace("Multi","")].push(n,o)}}const g=Object.keys(p).map(Number).sort(l);for(let t=0,i=g.length;t<i;++t){const i=p[g[t]];for(const t in i){const n=i[t];for(let t=0,i=n.length;t<i;t+=2){d.setStyle(n[t+1]);for(let i=0,s=e.length;i<s;++i)d.setTransform(e[i]),d.drawGeometry(n[t])}}}return a.getImageData(0,0,h.width,h.height)}(t,a,this.renderedFeatures_,r.getStyleFunction(),o,i,n)}e(function(t,e,i){const n=[];if(i){const s=Math.floor(Math.round(t[0])*Zr),o=Math.floor(Math.round(t[1])*Zr),r=4*(Ft(s,0,i.width-1)+Ft(o,0,i.height-1)*i.width),a=i.data[r],l=i.data[r+1],h=i.data[r+2]+256*(l+256*a),d=Math.floor(16777215/e.length);h&&h%d==0&&n.push(e[h/d-1])}return n}(t,this.renderedFeatures_,this.hitDetectionImageData_))}))}forEachFeatureAtCoordinate(t,e,i,n,s){if(!this.replayGroup_)return;const o=e.viewState.resolution,r=e.viewState.rotation,a=this.getLayer(),l={},h=function(t,e,i){const o=L(t),r=l[o];if(r){if(!0!==r&&i<r.distanceSq){if(0===i)return l[o]=!0,s.splice(s.lastIndexOf(r),1),n(t,a,e);r.geometry=e,r.distanceSq=i}}else{if(0===i)return l[o]=!0,n(t,a,e);s.push(l[o]={feature:t,layer:a,geometry:e,distanceSq:i,callback:n})}};let d;const c=[this.replayGroup_];return this.declutterExecutorGroup&&c.push(this.declutterExecutorGroup),c.some((n=>d=n.forEachFeatureAtCoordinate(t,o,r,i,h,n===this.declutterExecutorGroup&&e.declutterTree?e.declutterTree.all().map((t=>t.value)):null))),d}handleFontsChanged(){const t=this.getLayer();t.getVisible()&&this.replayGroup_&&t.changed()}handleStyleImageChange_(t){this.renderIfReadyAndVisible()}prepareFrame(t){const e=this.getLayer(),i=e.getSource();if(!i)return!1;const n=t.viewHints[0],s=t.viewHints[1],o=e.getUpdateWhileAnimating(),r=e.getUpdateWhileInteracting();if(this.ready&&!o&&n||!r&&s)return this.animatingOrInteracting_=!0,!0;this.animatingOrInteracting_=!1;const a=t.extent,l=t.viewState,h=l.projection,d=l.resolution,c=t.pixelRatio,p=e.getRevision(),g=e.getRenderBuffer();let f=e.getRenderOrder();void 0===f&&(f=zr);const m=l.center.slice(),_=rt(a,g*d),y=_.slice(),v=[_.slice()],x=h.getExtent();if(i.getWrapX()&&h.canWrapX()&&!dt(x,t.extent)){const t=Mt(x),e=Math.max(Mt(_)/2,t);_[0]=x[0]-e,_[2]=x[2]+e,Oe(m,h);const i=Ot(v[0],h);i[0]<x[0]&&i[2]<x[2]?v.push([i[0]+t,i[1],i[2]+t,i[3]]):i[0]>x[0]&&i[2]>x[2]&&v.push([i[0]-t,i[1],i[2]-t,i[3]])}if(this.ready&&this.renderedResolution_==d&&this.renderedRevision_==p&&this.renderedRenderOrder_==f&&dt(this.wrappedRenderedExtent_,_))return u(this.renderedExtent_,y)||(this.hitDetectionImageData_=null,this.renderedExtent_=y),this.renderedCenter_=m,this.replayGroupChanged=!1,!0;this.replayGroup_=null;const w=new xr(jr(d,c),_,d,c);let C;this.getLayer().getDeclutter()&&(C=new xr(jr(d,c),_,d,c));const S=Qe();let T;if(S){for(let t=0,e=v.length;t<e;++t){const e=ii(v[t]);i.loadFeatures(e,si(d),S)}T=Ye(S,h)}else for(let t=0,e=v.length;t<e;++t)i.loadFeatures(v[t],d,h);const b=function(t,e){const i=jr(t,e);return i*i}(d,c);let k=!0;const I=t=>{let i;const n=t.getStyleFunction()||e.getStyleFunction();if(n&&(i=n(t,d)),i){const e=this.renderFeature(t,b,i,w,T,C);k=k&&!e}},E=ii(_),R=i.getFeaturesInExtent(E);f&&R.sort(f);for(let t=0,e=R.length;t<e;++t)I(R[t]);this.renderedFeatures_=R,this.ready=k;const P=w.finish(),M=new Fr(_,d,c,i.getOverlaps(),P,e.getRenderBuffer());return C&&(this.declutterExecutorGroup=new Fr(_,d,c,i.getOverlaps(),C.finish(),e.getRenderBuffer())),this.renderedResolution_=d,this.renderedRevision_=p,this.renderedRenderOrder_=f,this.renderedExtent_=y,this.wrappedRenderedExtent_=_,this.renderedCenter_=m,this.renderedProjection_=h,this.replayGroup_=M,this.hitDetectionImageData_=null,this.replayGroupChanged=!0,!0}renderFeature(t,e,i,n,s,o){if(!i)return!1;let r=!1;if(Array.isArray(i))for(let a=0,l=i.length;a<l;++a)r=$r(n,t,i[a],e,this.boundHandleStyleImageChange_,s,o)||r;else r=$r(n,t,i,e,this.boundHandleStyleImageChange_,s,o);return r}},Br=class extends rr{constructor(t){super(t)}createRenderer(){return new Gr(this)}},Vr=class{constructor(t){this.rbush_=new Po(t),this.items_={}}insert(t,e){const i={minX:t[0],minY:t[1],maxX:t[2],maxY:t[3],value:e};this.rbush_.insert(i),this.items_[L(e)]=i}load(t,e){const i=new Array(e.length);for(let n=0,s=e.length;n<s;n++){const s=t[n],o=e[n],r={minX:s[0],minY:s[1],maxX:s[2],maxY:s[3],value:o};i[n]=r,this.items_[L(o)]=r}this.rbush_.load(i)}remove(t){const e=L(t),i=this.items_[e];return delete this.items_[e],null!==this.rbush_.remove(i)}update(t,e){const i=this.items_[L(e)];ft([i.minX,i.minY,i.maxX,i.maxY],t)||(this.remove(e),this.insert(t,e))}getAll(){return this.rbush_.all().map((function(t){return t.value}))}getInExtent(t){const e={minX:t[0],minY:t[1],maxX:t[2],maxY:t[3]};return this.rbush_.search(e).map((function(t){return t.value}))}forEach(t){return this.forEach_(this.getAll(),t)}forEachInExtent(t,e){return this.forEach_(this.getInExtent(t),e)}forEach_(t,e){let i;for(let n=0,s=t.length;n<s;n++)if(i=e(t[n]),i)return i;return i}isEmpty(){return _(this.items_)}clear(){this.rbush_.clear(),this.items_={}}getExtent(t){const e=this.rbush_.toJSON();return pt(e.minX,e.minY,e.maxX,e.maxY,t)}concat(t){this.rbush_.load(t.rbush_.all());for(const e in t.items_)this.items_[e]=t.items_[e]}},Ur="addfeature",Xr="removefeature";function Kr(t,e){return[[-1/0,-1/0,1/0,1/0]]}function Yr(t,e){return function(i,n,s,o,r){const a=this;
1!function(t,e,i,n,s,o,r){const a=new XMLHttpRequest;a.open("GET","function"==typeof t?t(i,n,s):t,!0),"arraybuffer"==e.getType()&&(a.responseType="arraybuffer"),a.withCredentials=false,a.onload=function(t){if(!a.status||a.status>=200&&a.status<300){const t=e.getType();let n;"json"==t||"text"==t?n=a.responseText:"xml"==t?(n=a.responseXML,n||(n=(new DOMParser).parseFromString(a.responseText,"application/xml"))):"arraybuffer"==t&&(n=a.response),n?o(e.readFeatures(n,{extent:i,featureProjection:s}),e.readProjection(n)):r()}else r()},a.onerror=r,a.send()}(t,e,i,n,s,(function(t,e){a.addFeatures(t),void 0!==o&&o(t)}),r||f)}}class Hr extends o{constructor(t,e,i){super(t),this.feature=e,this.features=i}}const qr=class extends fo{constructor(t){super({attributions:(t=t||{}).attributions,interpolate:!0,projection:void 0,state:"ready",wrapX:void 0===t.wrapX||t.wrapX}),this.on,this.once,this.un,this.loader_=f,this.format_=t.format,this.overlaps_=void 0===t.overlaps||t.overlaps,this.url_=t.url,void 0!==t.loader?this.loader_=t.loader:void 0!==this.url_&&(J(this.format_,7),this.loader_=Yr(this.url_,this.format_)),this.strategy_=void 0!==t.strategy?t.strategy:Kr;const e=void 0===t.useSpatialIndex||t.useSpatialIndex;let i,n;this.featuresRtree_=e?new Vr:null,this.loadedExtentsRtree_=new Vr,this.loadingExtentsCount_=0,this.nullGeometryFeatures_={},this.idIndex_={},this.uidIndex_={},this.featureChangeKeys_={},this.featuresCollection_=null,Array.isArray(t.features)?n=t.features:t.features&&(i=t.features,n=i.getArray()),e||void 0!==i||(i=new G(n)),void 0!==n&&this.addFeaturesInternal(n),void 0!==i&&this.bindFeaturesCollection_(i)}addFeature(t){this.addFeatureInternal(t),this.changed()}addFeatureInternal(t){const e=L(t);if(!this.addToIndex_(e,t))return void(this.featuresCollection_&&this.featuresCollection_.remove(t));this.setupChangeEvents_(e,t);const i=t.getGeometry();if(i){const e=i.getExtent();this.featuresRtree_&&this.featuresRtree_.insert(e,t)}else this.nullGeometryFeatures_[e]=t;this.dispatchEvent(new Hr(Ur,t))}setupChangeEvents_(t,e){this.featureChangeKeys_[t]=[k(e,v,this.handleFeatureChange_,this),k(e,r,this.handleFeatureChange_,this)]}addToIndex_(t,e){let i=!0;const n=e.getId();return void 0!==n&&(n.toString()in this.idIndex_?i=!1:this.idIndex_[n.toString()]=e),i&&(J(!(t in this.uidIndex_),30),this.uidIndex_[t]=e),i}addFeatures(t){this.addFeaturesInternal(t),this.changed()}addFeaturesInternal(t){const e=[],i=[],n=[];for(let e=0,n=t.length;e<n;e++){const n=t[e],s=L(n);this.addToIndex_(s,n)&&i.push(n)}for(let t=0,s=i.length;t<s;t++){const s=i[t],o=L(s);this.setupChangeEvents_(o,s);const r=s.getGeometry();if(r){const t=r.getExtent();e.push(t),n.push(s)}else this.nullGeometryFeatures_[o]=s}if(this.featuresRtree_&&this.featuresRtree_.load(e,n),this.hasListener(Ur))for(let t=0,e=i.length;t<e;t++)this.dispatchEvent(new Hr(Ur,i[t]))}bindFeaturesCollection_(t){let e=!1;this.addEventListener(Ur,(function(i){e||(e=!0,t.push(i.feature),e=!1)})),this.addEventListener(Xr,(function(i){e||(e=!0,t.remove(i.feature),e=!1)})),t.addEventListener(z,(t=>{e||(e=!0,this.addFeature(t.element),e=!1)})),t.addEventListener(j,(t=>{e||(e=!0,this.removeFeature(t.element),e=!1)})),this.featuresCollection_=t}clear(t){if(t){for(const t in this.featureChangeKeys_)this.featureChangeKeys_[t].forEach(E);this.featuresCollection_||(this.featureChangeKeys_={},this.idIndex_={},this.uidIndex_={})}else if(this.featuresRtree_){const t=t=>{this.removeFeatureInternal(t)};this.featuresRtree_.forEach(t);for(const t in this.nullGeometryFeatures_)this.removeFeatureInternal(this.nullGeometryFeatures_[t])}this.featuresCollection_&&this.featuresCollection_.clear(),this.featuresRtree_&&this.featuresRtree_.clear(),this.nullGeometryFeatures_={};const e=new Hr("clear");this.dispatchEvent(e),this.changed()}forEachFeature(t){if(this.featuresRtree_)return this.featuresRtree_.forEach(t);this.featuresCollection_&&this.featuresCollection_.forEach(t)}forEachFeatureAtCoordinateDirect(t,e){const i=[t[0],t[1],t[0],t[1]];return this.forEachFeatureInExtent(i,(function(i){if(i.getGeometry().intersectsCoordinate(t))return e(i)}))}forEachFeatureInExtent(t,e){if(this.featuresRtree_)return this.featuresRtree_.forEachInExtent(t,e);this.featuresCollection_&&this.featuresCollection_.forEach(e)}forEachFeatureIntersectingExtent(t,e){return this.forEachFeatureInExtent(t,(function(i){if(i.getGeometry().intersectsExtent(t)){const t=e(i);if(t)return t}}))}getFeaturesCollection(){return this.featuresCollection_}getFeatures(){let t;return this.featuresCollection_?t=this.featuresCollection_.getArray().slice(0):this.featuresRtree_&&(t=this.featuresRtree_.getAll(),_(this.nullGeometryFeatures_)||c(t,Object.values(this.nullGeometryFeatures_))),t}getFeaturesAtCoordinate(t){const e=[];return this.forEachFeatureAtCoordinateDirect(t,(function(t){e.push(t)})),e}getFeaturesInExtent(t,e){if(this.featuresRtree_){if(!(e&&e.canWrapX()&&this.getWrapX()))return this.featuresRtree_.getInExtent(t);const i=function(t,e){if(e.canWrapX()){const i=e.getExtent();if(!isFinite(t[0])||!isFinite(t[2]))return[[i[0],t[1],i[2],t[3]]];Ot(t,e);const n=Mt(i);if(Mt(t)>n)return[[i[0],t[1],i[2],t[3]]];if(t[0]<i[0])return[[t[0]+n,t[1],i[2],t[3]],[i[0],t[1],t[2],t[3]]];if(t[2]>i[2])return[[t[0],t[1],i[2],t[3]],[i[0],t[1],t[2]-n,t[3]]]}return[t]}(t,e);return[].concat(...i.map((t=>this.featuresRtree_.getInExtent(t))))}return this.featuresCollection_?this.featuresCollection_.getArray().slice(0):[]}getClosestFeatureToCoordinate(t,e){const i=t[0],n=t[1];let s=null;const o=[NaN,NaN];let r=1/0;const a=[-1/0,-1/0,1/0,1/0];return e=e||p,this.featuresRtree_.forEachInExtent(a,(function(t){if(e(t)){const e=t.getGeometry(),l=r;if(r=e.closestPointXY(i,n,o,r),r<l){s=t;const e=Math.sqrt(r);a[0]=i-e,a[1]=n-e,a[2]=i+e,a[3]=n+e}}})),s}getExtent(t){return this.featuresRtree_.getExtent(t)}getFeatureById(t){const e=this.idIndex_[t.toString()];return void 0!==e?e:null}getFeatureByUid(t){const e=this.uidIndex_[t];return void 0!==e?e:null}getFormat(){return this.format_}getOverlaps(){return this.overlaps_}getUrl(){return this.url_}handleFeatureChange_(t){const e=t.target,i=L(e),n=e.getGeometry();if(n){const t=n.getExtent();i in this.nullGeometryFeatures_?(delete this.nullGeometryFeatures_[i],this.featuresRtree_&&this.featuresRtree_.insert(t,e)):this.featuresRtree_&&this.featuresRtree_.update(t,e)}else i in this.nullGeometryFeatures_||(this.featuresRtree_&&this.featuresRtree_.remove(e),this.nullGeometryFeatures_[i]=e);const s=e.getId();if(void 0!==s){const t=s.toString();this.idIndex_[t]!==e&&(this.removeFromIdIndex_(e),this.idIndex_[t]=e)}
1else this.removeFromIdIndex_(e),this.uidIndex_[i]=e;this.changed(),this.dispatchEvent(new Hr("changefeature",e))}hasFeature(t){const e=t.getId();return void 0!==e?e in this.idIndex_:L(t)in this.uidIndex_}isEmpty(){return this.featuresRtree_?this.featuresRtree_.isEmpty()&&_(this.nullGeometryFeatures_):!this.featuresCollection_||0===this.featuresCollection_.getLength()}loadFeatures(t,e,i){const n=this.loadedExtentsRtree_,s=this.strategy_(t,e,i);for(let t=0,o=s.length;t<o;++t){const o=s[t];n.forEachInExtent(o,(function(t){return dt(t.extent,o)}))||(++this.loadingExtentsCount_,this.dispatchEvent(new Hr("featuresloadstart")),this.loader_.call(this,o,e,i,(t=>{--this.loadingExtentsCount_,this.dispatchEvent(new Hr("featuresloadend",void 0,t))}),(()=>{--this.loadingExtentsCount_,this.dispatchEvent(new Hr("featuresloaderror"))})),n.insert(o,{extent:o.slice()}))}this.loading=!(this.loader_.length<4)&&this.loadingExtentsCount_>0}refresh(){this.clear(!0),this.loadedExtentsRtree_.clear(),super.refresh()}removeLoadedExtent(t){const e=this.loadedExtentsRtree_;let i;e.forEachInExtent(t,(function(e){if(ft(e.extent,t))return i=e,!0})),i&&e.remove(i)}removeFeature(t){if(!t)return;const e=L(t);e in this.nullGeometryFeatures_?delete this.nullGeometryFeatures_[e]:this.featuresRtree_&&this.featuresRtree_.remove(t),this.removeFeatureInternal(t)&&this.changed()}removeFeatureInternal(t){const e=L(t),i=this.featureChangeKeys_[e];if(!i)return;i.forEach(E),delete this.featureChangeKeys_[e];const n=t.getId();return void 0!==n&&delete this.idIndex_[n.toString()],delete this.uidIndex_[e],this.dispatchEvent(new Hr(Xr,t)),t}removeFromIdIndex_(t){let e=!1;for(const i in this.idIndex_)if(this.idIndex_[i]===t){delete this.idIndex_[i],e=!0;break}return e}setLoader(t){this.loader_=t}setUrl(t){J(this.format_,7),this.url_=t,this.setLoader(Yr(t,this.format_))}};class Jr extends F{constructor(t){if(super(),this.on,this.once,this.un,this.id_=void 0,this.geometryName_="geometry",this.style_=null,this.styleFunction_=void 0,this.geometryChangeKey_=null,this.addChangeListener(this.geometryName_,this.handleGeometryChanged_),t)if("function"==typeof t.getSimplifiedGeometry){const e=t;this.setGeometry(e)}else{const e=t;this.setProperties(e)}}clone(){const t=new Jr(this.hasProperties()?this.getProperties():null);t.setGeometryName(this.getGeometryName());const e=this.getGeometry();e&&t.setGeometry(e.clone());const i=this.getStyle();return i&&t.setStyle(i),t}getGeometry(){return this.get(this.geometryName_)}getId(){return this.id_}getGeometryName(){return this.geometryName_}getStyle(){return this.style_}getStyleFunction(){return this.styleFunction_}handleGeometryChange_(){this.changed()}handleGeometryChanged_(){this.geometryChangeKey_&&(E(this.geometryChangeKey_),this.geometryChangeKey_=null);const t=this.getGeometry();t&&(this.geometryChangeKey_=k(t,v,this.handleGeometryChange_,this)),this.changed()}setGeometry(t){this.set(this.geometryName_,t)}setStyle(t){this.style_=t,this.styleFunction_=t?function(t){if("function"==typeof t)return t;let e;return Array.isArray(t)?e=t:(J("function"==typeof t.getZIndex,41),e=[t]),function(){return e}}(t):void 0,this.changed()}setId(t){this.id_=t,this.changed()}setGeometryName(t){this.removeChangeListener(this.geometryName_,this.handleGeometryChanged_),this.geometryName_=t,this.addChangeListener(this.geometryName_,this.handleGeometryChanged_),this.handleGeometryChanged_()}}const Qr=Jr;!function(t,e){(window.app=window.app||{}).openStreetMap=function(e){var i,n=t(e),s=n.data("config"),o=n.data("markers"),r=n.data("marker-img"),a=new qr;function l(){n.data("is-initialized",!0),a.clear(),o.forEach((function(t,e){var i,n,s,o,l;a.addFeatures((i=t.lng,n=t.lat,o=[],(l=new Qr({type:"point",projectId:s="location"+e,geometry:new Ni([i,n])})).setId(s),l.getGeometry().transform("EPSG:4326","EPSG:3857"),l.setStyle(new Uo({image:new qo({anchor:[.5,1],scale:.5,src:r})})),o.push(l),o))})),a.getFeatures().length&&i.getView().fit(a.getExtent(),{size:i.getSize(),padding:[90,90,90,90],maxZoom:15})}function h(){var n=new Br({source:a});
1i=new js({target:e,controls:[new ss({zoomInLabel:t('<i class="ol-icon ol-icon-plus" aria-hidden="true"></i>')[0],zoomOutLabel:t('<i class="ol-icon ol-icon-minus" aria-hidden="true"></i>')[0]})],interactions:Fs({onFocusOnly:!1,mouseWheelScroll:!1,dragPan:!0,shiftDragZoom:!0,doubleClickZoom:!1,dragAndDrop:!1,keyboardPan:!0,keyboardZoom:!0,mouseWheelZoom:!1,pointer:!1,select:!1}),layers:[new ao({source:new Ro({url:"https://{a-d}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}.png"})}),n],view:new Qi({minZoom:5,maxZoom:30,zoom:15})})}s.delayInitialization?t(s.trigger).on("click",(function(){n.data("is-initialized")||(h(),l())})):(h(),l())}}(i(5311)),i(3557),i(4557);var ta=i(5311);!function(t,e){t.instantiate=function(i){var n=e(i),s=n.attr("data-module");if(void 0===s)throw'Module not defined (use data-module="")';if(!(s in t))throw"Module '"+s+"' not found";new t[s](i),n.attr("data-initialized",!0)},e("[data-module]").each((function(){t.instantiate(this)})),document.defaultView.addEventListener("keydown",(function t(i){9===i.keyCode&&(e("body").addClass("user-is-tabbing"),document.defaultView.removeEventListener("keydown",t))})),console.log("%c  Powered by level-level.com 💪🏻  ","background: #222; color: #fff; font-size: 14px; font-weight: normal; border-radius: 5px; line-height: 30px;")}(window.app=window.app||{},ta),i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p,i.p}()}();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.