/**
 * Minified by jsDelivr using Terser v5.37.0.
 * Original file: /npm/pretty-dropdowns@4.17.0/dist/js/jquery.prettydropdowns.js
 *
 * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
 */
/*!
 * jQuery Pretty Dropdowns Plugin v4.17.0 by T. H. Doan (https://thdoan.github.io/pretty-dropdowns/)
 *
 * jQuery Pretty Dropdowns by T. H. Doan is licensed under the MIT License.
 * Read a copy of the license in the LICENSE file or at https://choosealicense.com/licenses/mit/
 */
!function(e){e.fn.prettyDropdown=function(t){(t=e.extend({classic:!1,customClass:"arrow",width:null,height:50,hoverIntent:200,multiDelimiter:"; ",multiVerbosity:99,selectedMarker:"&#10003;",afterLoad:function(){}},t)).selectedMarker='<span aria-hidden="true" class="checked"> '+t.selectedMarker+"</span>",isNaN(t.width)&&!/^\d+%$/.test(t.width)&&(t.width=null),isNaN(t.height)?t.height=50:t.height<8&&(t.height=8),isNaN(t.hoverIntent)&&(t.hoverIntent=200),isNaN(t.multiVerbosity)&&(t.multiVerbosity=99);var a,i,s,r,l,d,n=["0","1","2","3","4","5","6","7","8","9",,,,,,,,"a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"],c=function(a){var s,r=e(a),l=a.size,n=a.name||a.id||"";if(!r.data("loaded")){if(r.data("size",l).removeAttr("size"),r.css("visibility","hidden").outerHeight(t.height),d=1e14*performance.now(),a.id){var c=e("label[for="+a.id+"]");c.length&&(c.attr("id")&&!/^menu\d{13,}$/.test(c.attr("id"))?s=c.attr("id"):c.attr("id",s="menu"+d))}i=0;var v=e("optgroup, option",r),m=v.filter(":selected"),b=a.multiple,w="<ul"+(a.disabled?"":' tabindex="0"')+' role="listbox"'+(a.title?' title="'+a.title+'" aria-label="'+a.title+'"':"")+(s?' aria-labelledby="'+s+'"':"")+' aria-activedescendant="item'+d+'-1" aria-expanded="false" style="max-height:'+(t.height-2)+"px;margin:"+r.css("margin-top")+" "+r.css("margin-right")+" "+r.css("margin-bottom")+" "+r.css("margin-left")+';">';b?(w+=p(null,"selected"),v.each((function(){this.selected?w+=p(this,"",!0):w+=p(this)}))):t.classic?v.each((function(){w+=p(this)})):(w+=p(m[0],"selected"),v.filter(":not(:selected)").each((function(){w+=p(this)}))),w+="</ul>",r.wrap("<div "+(n?'id="prettydropdown-'+n+'" ':"")+'class="prettydropdown '+(t.classic?"classic ":"")+(a.disabled?"disabled ":"")+(b?"multiple ":"")+t.customClass+' loading"'+(b||l>1?' style="height:'+t.height+'px;"':"")+"></div>").before(w).data("loaded",!0);var k,y=r.parent().children("ul"),x=y.outerWidth(!0);if(v=y.children(),b?g(y):t.classic&&e('[data-value="'+m.val()+'"]',y).addClass("selected").append(t.selectedMarker),y.width()<=0){var C=y.parent().clone().css({position:"absolute",top:"-100%"});e("body").append(C),x=C.children("ul").outerWidth(!0),e("li",C).width(x),k=C.children("ul").outerWidth(!0),C.remove()}v.width(x).css("width",v.css("width")),t.width&&(y.parent().css("min-width",v.css("width")),y.css("width","100%"),v.css("width","100%")),v.click((function(){var a=e(this),i=y.children(".selected");if(!y.parent().hasClass("disabled"))if(!y.hasClass("active")||a.hasClass("disabled")||a.hasClass("label")||a.data("value")===i.data("value")||(b?(a.children("span.checked").length?a.children("span.checked").remove():a.append(t.selectedMarker),y.children(":not(.selected)").each((function(t){e("optgroup, option",r).eq(t).prop("selected",e(this).children("span.checked").length>0)})),g(y)):(i.removeClass("selected").children("span.checked").remove(),a.addClass("selected").append(t.selectedMarker),t.classic||y.prepend(a),y.removeClass("reverse").attr("aria-activedescendant",a.attr("id")),i.data("group")&&!t.classic&&y.children(".label").filter((function(){return e(this).text()===i.data("group")})).after(i),e("optgroup, option",r).filter((function(){return this.value+"|"+this.text==(a.data("value")||"")+"|"+a.contents().filter((function(){return 3===this.nodeType})).text()})).prop("selected",!0)),r.trigger("change")),!a.hasClass("selected")&&b||(y.toggleClass("active"),y.attr("aria-expanded",y.hasClass("active"))),y.hasClass("active")){e(".prettydropdown > ul.active").length>1&&f(e(".prettydropdown > ul.active").not(y)[0]);var s,d=window.innerHeight,n=y.offset().top,c=e(document).scrollTop(),o=y.outerHeight();l&&(s=l*(t.height-2))<o-2&&(o=s+2);var h=n-c+o;h>d&&(n-c>d-(n-c+t.height)?(y.addClass("reverse"),t.classic||y.append(i),n-c+t.height<o&&(y.outerHeight(n-c+t.height),y.scrollTop(o))):y.height(y.height()-(h-d))),s&&s<y.height()&&y.css("height",s+"px"),t.classic&&y.scrollTop(i.index()*(t.height-2))}else y.data("clicked",!0),f(y[0])})),y.on({focusin:function(){e(window).off("keydown",h).on("keydown",h)},focusout:function(){e(window).off("keydown",h)},mouseenter:function(){y.data("hover",!0)},mouseleave:f,mousemove:u}),t.hoverIntent<0&&e(document).click((function(e){y.data("hover")&&!y[0].contains(e.target)&&f(y[0])})),s&&e("#"+s).off("click",o).click(o),y.parent().width(t.width||k||y.outerWidth(!0)).removeClass("loading"),t.afterLoad()}},o=function(t){e("ul[aria-labelledby="+t.target.id+"]").focus()},h=function(i){var d=e(".prettydropdown > ul.active, .prettydropdown > ul:focus");if(d.length)if(9!==i.which){i.preventDefault(),i.stopPropagation();var c,o=d.children(),h=d.hasClass("active"),u=d.height()/(t.height-2),p=u%1<.5?Math.floor(u):Math.ceil(u);switch(s=Math.max(0,d.children(".hover").index()),r=o.length-1,a=o.eq(s),d.data("lastKeypress",+new Date),i.which){case 13:h||(a=o.filter(".selected"),v(a,1)),a.click();break;case 27:h&&f(d[0]);break;case 32:h?c=" ":(a=o.filter(".selected"),v(a,1),a.click());break;case 33:h&&(v(a,0),v(o.eq(Math.max(s-p-1,0)),1));break;case 34:h&&(v(a,0),v(o.eq(Math.min(s+p-1,r)),1));break;case 35:h&&(v(a,0),v(o.eq(r),1));break;case 36:h&&(v(a,0),v(o.eq(0),1));break;case 38:h&&(v(a,0),v(s?o.eq(s-1):o.eq(r),1));break;case 40:h&&(v(a,0),v(s===r?o.eq(0):o.eq(s+1),1));break;default:h&&(c=n[i.which-48])}if(c){clearTimeout(l),d.data("keysPressed",void 0===d.data("keysPressed")?c:d.data("keysPressed")+c),l=setTimeout((function(){d.removeData("keysPressed")}),300);var g=[],m=a.index();if(o.each((function(t){0===e(this).text().toLowerCase().indexOf(d.data("keysPressed"))&&g.push(t)})),g.length)for(var b=0;b<g.length;++b){if(g[b]>m){v(o,0),v(o.eq(g[b]),1);break}b===g.length-1&&(v(o,0),v(o.eq(g[0]),1))}}}else f(d[0])},u=function(t){var a=e(t.currentTarget);"LI"!==t.target.nodeName||!a.hasClass("active")||new Date-a.data("lastKeypress")<200||(v(a.children(),0,1),v(e(t.target),1,1))},p=function(a,s,r){var l,n="",c="";if(s=s||"",a){switch(a.nodeName){case"OPTION":"OPTGROUP"===a.parentNode.nodeName&&(n=a.parentNode.getAttribute("label")),c=(a.getAttribute("data-prefix")||"")+a.text+(a.getAttribute("data-suffix")||"");break;case"OPTGROUP":s+=" label",c=(a.getAttribute("data-prefix")||"")+a.getAttribute("label")+(a.getAttribute("data-suffix")||"")}(a.disabled||n&&a.parentNode.disabled)&&(s+=" disabled"),l=a.title,n&&!l&&(l=a.parentNode.title)}return++i,'<li id="item'+d+"-"+i+'"'+(n?' data-group="'+n+'"':"")+(a&&(a.value||t.classic)?' data-value="'+a.value+'"':"")+(a&&"OPTION"===a.nodeName?' role="option"':"")+(l?' title="'+l+'" aria-label="'+l+'"':"")+(s?' class="'+e.trim(s)+'"':"")+(50!==t.height?' style="height:'+(t.height-2)+"px;line-height:"+(t.height-4)+'px;"':"")+">"+c+(r||"selected"===s?t.selectedMarker:"")+"</li>"},f=function(a){if(!(t.hoverIntent<0&&"mouseleave"===a.type)){var i=e(a.currentTarget||a);i.data("hover",!1),clearTimeout(l),l=setTimeout((function(){i.data("hover")||(i.hasClass("reverse")&&!t.classic&&i.prepend(i.children(":last-child")),i.removeClass("active reverse").removeData("clicked").attr("aria-expanded","false").css("height",""),i.children().removeClass("hover nohover"),i.attr("aria-activedescendant",i.children(".selected").attr("id")))}),"mouseleave"!==a.type||i.data("clicked")?0:t.hoverIntent)}},v=function(e,i,s){if(i){var l=e.parent();if(e.removeClass("nohover").addClass("hover"),l.attr("aria-activedescendant",e.attr("id")),1===e.length&&a&&!s){var d=l.outerHeight(),n=e.offset().top-l.offset().top-1;0===e.index()?l.scrollTop(0):e.index()===r?l.scrollTop(l.children().length*t.height):n+t.height>d?l.scrollTop(l.scrollTop()+t.height+n-d):n<0&&l.scrollTop(l.scrollTop()+n)}}else e.removeClass("hover").addClass("nohover")},g=function(a){var i,s=a.parent().children("select"),r=e("option",s).map((function(){if(this.selected)return this.text})).get();if(i=t.multiVerbosity>=r.length?r.join(t.multiDelimiter)||"None selected":r.length+"/"+e("option",s).length+" selected"){var l=(s.attr("title")?s.attr("title"):"")+(r.length?"\nSelected: "+r.join(t.multiDelimiter):"");a.children(".selected").text(i),a.attr({title:l,"aria-label":l})}else a.children(".selected").empty(),a.attr({title:s.attr("title"),"aria-label":s.attr("title")})};return this.refresh=function(t){return this.each((function(){var t=e(this);t.prevAll("ul").remove(),t.unwrap().data("loaded",!1),this.size=t.data("size"),c(this)}))},this.each((function(){c(this)}))}}(jQuery);
//# sourceMappingURL=/sm/4f76409c596e6d1017faf1a85a190b8a0851f2dfef15c376a675dd6f48dd2dc7.map