/* Request ID: 9cdd266673605c7334883e9d4b88a958 (05/09/2024 7:47am) (rdbBboMwDIDhV9mth07ktteZ3OCC1ZBkTgLa25eQAebsXar+VvXJaSmtGcOEZkLvglmWpdueJTuG4LrAg3E04zKCQ2MDry8MfXGYWiTLFHMykWmGjB2mr88P8w/gA+wLfa8CwWaaKf8e6D5QqXWzEtNl07V1pguDEGspvcIPCdbUicU5zOQFuk9Ubs/wzCfaUiXijF6ILVXiE7E/wa10HtXHw6ul8wJPwqul8gZYP1kmseMx0bkuPMAJtbXO5CC/jC1VIk0wiKO31Il+YOzpclmKmc5Oqchtt1SJDvxQLm/BMVG507obBXED2Qcq1eNyijVUWrycO6rPHB1YCW6pEzlcbx/7QKX+FLIvsOtyJyxmKrte5oxWXPvHROUmBLbjgbZUiRnEj3ANlVZiv/4jOsG/1pkJWYi1mne755FSR54ygfsu7O63Nw==) */ /* Resource ID: 88d8aeb7c465d4fe3e4b7bd82a6 (private.es6, compiled by babel, minified by uglifyjs) (04/28/2024 6:01am) (A:72474, C:84654, D:84654, F:84654, G:43366, K:43366) */ "use strict";function _createSuper(s){var a=_isNativeReflectConstruct();return function e(){var t=babelHelpers.getPrototypeOf(s),i;if(a){var r=babelHelpers.getPrototypeOf(this).constructor;i=Reflect.construct(t,arguments,r)}else{i=t.apply(this,arguments)}return babelHelpers.possibleConstructorReturn(this,i)}}function _isNativeReflectConstruct(){if(typeof Reflect==="undefined"||!Reflect.construct)return false;if(Reflect.construct.sham)return false;if(typeof Proxy==="function")return true;try{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));return true}catch(e){return false}}(function(h,f){h.lib=h.lib||{};h.lib.pubSub=function(){var t=f({});return{bind:function e(){t.on.apply(t,arguments)},unbind:function e(){t.off.apply(t,arguments)},trigger:function e(){t.trigger.apply(t,arguments)}}};h.eventHub=h.lib.pubSub();var e=function(){function e(){babelHelpers.classCallCheck(this,e);this.pubsub=f({})}babelHelpers.createClass(e,[{key:"bind",value:function e(){this.pubsub.on.apply(this.pubsub,arguments)}},{key:"unbind",value:function e(){this.pubsub.off.apply(this.pubsub,arguments)}},{key:"trigger",value:function e(){this.pubsub.trigger.apply(this.pubsub,arguments)}}]);return e}();h.lib.PubSub=e;h.lib.getAjaxUrl=function(e,t,i){var r=i?i:"/livewhale/backend.php";var s=r+"?livewhale=ajax&function="+e;if(f.isPlainObject(t)&&!f.isEmptyObject(t)){s+="&"+f.param(t)}return s};h.lib.openAltTextOverlay=function(e,t){if(!e){return}t=t?f("
").html(t).text():"This image has no description (ALT text) saved.";f('
').html("

"+t+"

").overlay({destroyOnClose:true,autoOpen:true,closeOnBodyClick:true,size:"medium",zIndex:1160,closeSelector:".lw_cancel",title:"Image Description (ALT text)"})};var t=function(e){babelHelpers.inherits(r,e);var i=_createSuper(r);function r(e){var t;babelHelpers.classCallCheck(this,r);t=i.call(this);t.options=_.extend({title:"Crop image",aspect_ratio:null,custom_aspect_ratio:null,hide_aspect_ratio_menu:false,size:"medium"},e);t.jcrop_api=null;t.coords=null;t.aspect_ratio=t.options.aspect_ratio;t.init();return t}babelHelpers.createClass(r,[{key:"init",value:function e(){var t=this;var i=this;var r,s,a,l;r='
'+'
'+'
'+"
Lock aspect ratio:"+'';f.each(h.image_crop_aspect_ratios,function(e,t){r+='"});r+="
"+"
"+'
'+''+"";a="
"+''+'or cancel and close'+"
";l=f(a);s=this.$overlay=f(r).overlay({autoOpen:false,destroyOnClose:false,size:this.options.size,closeSelector:".lw_cancel a",title:this.options.title,footer:l,customClass:"lw_crop_overlay",zIndex:1305,close:f.proxy(this._close,this)});if(this.options.hide_aspect_ratio_menu){this.$overlay.find("#lw_image_crop_ar").hide()}else{this.$overlay.find("#lw_image_crop_ar").show()}this.$preview=s.find("#lw_image_crop_preview_image");this.$ar_checkboxes=s.find("#lw_image_crop_ar input[type=checkbox]");l.on("click",".btn-primary",function(e){e.preventDefault();i.saveCrop();return true});s.on("click","#lw_image_crop_ar input[type=checkbox]",function(){var e=f(this);var t=e.closest("label");if(e.prop("checked")){t.siblings().removeClass("selected").find("input[type=checkbox]").prop("checked",false);t.addClass("selected");i.setAspectRatio(e.val())}else{t.removeClass("selected");i.setAspectRatio("")}return true});s.on("keydown","#lw_image_crop_ar label",function(e){switch(e.which){case 13:f(this).find("input").click();break;case 37:f(this).prev().focus();break;case 39:f(this).next().focus();break}});if(this.options.custom_aspect_ratio){this.bind("ready",function(){if(t.jcrop_api){t.setAspectRatio(t.options.custom_aspect_ratio)}})}}},{key:"setAspectRatio",value:function e(t){var i=0;this.aspect_ratio=t;if(t==="orig"){i=this.width/this.height}else if(t.match(/^\d+:\d+$/)){i=parseInt(t.split(":")[0],10)/parseInt(t.split(":")[1],10)}this.jcrop_api.setOptions({aspectRatio:i})}},{key:"setCropSelect",value:function e(t){this.jcrop_api.setSelect(t)}},{key:"setCropCoords",value:function e(t){this.coords=t;this.trigger("set",[{coords:t}])}},{key:"setPreviewImage",value:function e(t){var i,r,s;if(this.height>=this.width){s=this.options.size==="large"?578:500;r=Math.round(s*(this.width/this.height))}else{r=this.options.size==="large"?868:500;s=Math.round(r*(this.height/this.width))}i=t.replace(/\/(?=[^/]*$)/,"/width/"+r+"/height/"+s+"/");this.$preview.attr("src",i).width(r).height(s)}},{key:"initCropper",value:function e(t){var a=this,i=this.$preview.width(),r=this.$preview.height(),s=i/this.width,l=r/this.height,o;if(!_.isArray(t)||t.length!==4){if(i>r){o=[(i-r)/2,0,(i-r)/2+r,r]}else{o=[0,(r-i)/2,i,(r-i)/2+i]}}else{o=[Math.round(t[0]*s),Math.round(t[1]*l),Math.round(t[2]*s),Math.round(t[3]*l)]}this.$preview.Jcrop({aspectRatio:0,keySupport:true,trueSize:[this.width,this.height],setSelect:o,onSelect:f.proxy(this.setCropCoords,this),onChange:f.proxy(this.setCropCoords,this),onRelease:function e(t){}},function(){var l=a.jcrop_api=this;if(a.aspect_ratio){a.$ar_checkboxes.each(function(){if(f(this).val()===a.aspect_ratio){f(this).trigger("click")}})}var o=null;var e=f(".jcrop-handle");var t=f(".jcrop-handle").parent();var i=["nw-resize","n-resize","ne-resize","w-resize","e-resize","sw-resize","s-resize","se-resize"];var r=["top left corner","top side","top right corner","left side","right side","bottom left corner","bottom side","bottom right corner"];function s(e,t){var i=l.tellSelect();var r=o?25:2;var s=null,a=null;if(e.charAt(0)=="n"){a="y"}else if(e.charAt(0)=="s"){a="y2"}if(e.includes("w-")){s="x"}else if(e.includes("e-")){s="x2"}switch(t){case"left":if(s){i[s]=i[s]-r}break;case"right":if(s){i[s]=i[s]+r}break;case"up":if(a){i[a]=i[a]-r}break;case"down":if(a){i[a]=i[a]+r}break}if(o){l.animateTo([i["x"],i["y"],i["x2"],i["y2"]])}else{l.setSelect([i["x"],i["y"],i["x2"],i["y2"]])}}e.attr("tabindex","0").each(function(){var t=f(this).css("cursor");f(this).attr("aria-label","Move "+r[i.indexOf(t)]+" of crop area").attr("data-handle-type",t).attr("data-handle-order",i.indexOf(t)).addClass(t).on("keydown",function(e){switch(e.which){case 37:e.preventDefault();s(t,"left");break;case 39:e.preventDefault();s(t,"right");break;case 38:e.preventDefault();s(t,"up");break;case 40:e.preventDefault();s(t,"down");break}}).on("keyup keydown",function(e){o=e.shiftKey})});t.find(".jcrop-handle").sort(function(e,t){return+e.getAttribute("data-handle-order")-+t.getAttribute("data-handle-order")}).appendTo(t);a.trigger("ready")})}},{key:"open",value:function e(t,i,r,s){var a=this;this.width=i;this.height=r;this.$overlay.overlay("open");this.setPreviewImage(t);this.$preview.parent().imagesLoaded(function(){a.initCropper(s)})}},{key:"saveCrop",value:function e(){var t=this.coords,i;if(_.isPlainObject(t)&&_.keys(t).length===6){i=[t.x,t.y,t.x2,t.y2]}this.trigger("save",[{coords:i,aspect_ratio:this.aspect_ratio}]);this.$overlay.overlay("close")}},{key:"_close",value:function e(){this.coords=null;this.$ar_checkboxes.prop("checked",false);if(this.jcrop_api){this.jcrop_api.destroy();this.jcrop_api=null}this.$preview.removeAttr("src")}}]);return r}(e);h.lib.CropDialog=t;function i(e){var t=arguments.length>1&&arguments[1]!==undefined?arguments[1]:null;var i=arguments.length>2&&arguments[2]!==undefined?arguments[2]:null;var r=arguments.length>3&&arguments[3]!==undefined?arguments[3]:null;var s=arguments.length>4&&arguments[4]!==undefined?arguments[4]:null;this.preview_width=e;this.preview_height=t;this.src=i;this.width=r;this.height=s;this.coords=null}_.extend(i.prototype,h.lib.pubSub(),{open:function e(){var i=this;if(!this.crop_dialog){this.crop_dialog=new h.lib.CropDialog({hide_aspect_ratio_menu:false,title:"Crop image"});this.crop_dialog.bind("save",function(e,t){i.setCrop(t.coords)})}this.crop_dialog.open(this.src,this.width,this.height,this.coords)},setImage:function e(t,i,r){this.src=t;this.width=i;this.height=r;this.resetCoords()},resetCoords:function e(){this.coords=null},getPreviewHeight:function e(t){var i=t[2]-t[0];var r=t[3]-t[1];return this.preview_width*(r/i)},getPreviewWidth:function e(t){var i=t[2]-t[0];var r=t[3]-t[1];return this.preview_height*(i/r)},setCrop:function e(t){if(!_.isArray(t)||t.length!==4){return}this.coords=t;var i,r;if(this.preview_width&&!this.preview_height){i=this.preview_width;r=this.getPreviewHeight(t)}if(this.preview_height&&!this.preview_width){r=this.preview_height;i=this.getPreviewWidth(t)}this.trigger("crop",[{src:this.src,preview_width:i,preview_height:r,width:this.width,height:this.height,coords:t}])}});h.lib.Cropper=i;var r={init:function e(){var t=this.$toolbar=f("#lw-toolbar");if(!t.length){return}this.initGroupSwitcher();this.addDropdownHandlers();this.adjustToolboxColumns();this.initSearch();this.initMobile();if(t.hasClass("lw-toolbar-backend")){t.find(".lw-frontend-only").remove()}else{t.find(".lw-backend-only").remove()}h.eventHub.bind("toolbarOpen",function(e,t){if(t.find(".lw-dropdown-menu .lw-group-switcher, .lw-dropdown-menu a, .lw-dropdown-menu input, .lw-dropdown-menu textarea").first().is("input,textarea")){t.find(".lw-dropdown-menu input, .lw-dropdown-menu textarea").first().trigger("focus")}return true});t.show()},initGroupSwitcher:function e(){if(h.group_fullname&&h.group_title_native!==h.group_fullname){f(".current-page-group").addClass("visible").html('Current Page Owner: '+h.group_fullname+"").show()}else{f(".current-page-group").hide()}var t=f("#lw-group-filter").attr("role","application");f(".lw-group-switcher .no-results").hide();f(".lw-group-switcher li").attr("data-show-filtered","true");f('
').appendTo(f(".lw-group-switcher"));if(!_.isEmpty(h.top_groups)){f('
    ').insertBefore(".lw-group-switcher div ul");_.each(h.top_groups,function(e){f(".lw-group-switcher div.all-groups").find('a[href$="group='+e+'"]').parent().appendTo(f(".lw-group-switcher div.all-groups ul.top-groups"));f(".lw-group-switcher div.recent-groups").find('a[href$="group='+e+'"]').parent().appendTo(f(".lw-group-switcher div.recent-groups ul.top-groups"))})}function l(e){var t=f(".lw-group-switcher div.lw-dropdown-menu-inner"),i=t.outerHeight(),r=t.scrollTop(),s=e.position().top,a=e.offset().top;e.addClass("active");if(s+r<160&&r>0){t.scrollTop(0)}else if(a<40||a>i+30){e[0].scrollIntoView()}f(".lw-group-switcher div.system-groups a").prepend('System group: ');f("#sr-group-switcher").text("Press Enter to switch to group: "+e.text())}t.on("focusin input",function(){var e=f(this).val().toLowerCase(),t=f(".lw-group-switcher div.lw-dropdown-menu");if(!t.attr("data-width")){t.attr("data-width",t.outerWidth()).css("width",t.outerWidth())}if(e.length<1){f(".lw-group-switcher li").removeClass("active").show().attr("data-show-filtered","true");f(".lw-group-switcher div.recent-groups").show();f(".lw-group-switcher .no-results").hide();t.attr("data-width","").css("width","");f("#sr-group-switcher").text("Switch to a group by starting to type it's name, or use the tab or arrow keys to choose from all your groups.");f(".current-page-group.visible").show()}else{f(".lw-group-switcher div.recent-groups").hide();f(".lw-group-switcher div.recent-groups li").attr("data-show-filtered","false");f(".lw-group-switcher li").removeClass("active");f(".current-page-group.visible").hide();f(".lw-group-switcher div.all-groups li, .lw-group-switcher div.system-groups li").each(function(){if(f(this).text().toLowerCase().search(e)>-1){f(this).show().attr("data-show-filtered","true")}else{f(this).hide().attr("data-show-filtered","false")}});if(f(".lw-group-switcher li:visible").length){f(".lw-group-switcher .no-results").hide();l(f(".lw-group-switcher li:visible:first"))}else{f(".lw-group-switcher .no-results").show();f("#sr-group-switcher").text('No groups found matching text: "'+e+'"')}}});t.on("keydown",function(e){var t=f(this).val().toLowerCase(),i=f("[data-show-filtered=true]").index(f(".active")),r=f("[data-show-filtered=true]").length,s;switch(e.which){case 13:e.preventDefault();var a=f(".lw-group-switcher li.active a").attr("href");if(a){document.location.href=a}break;case 38:case 40:e.preventDefault();if(t.length<1&&f(".lw-group-switcher li.active").length<1){s=e.which==40?0:r-1;l(f("[data-show-filtered=true]").eq(s))}else if(r>1){if(e.which==40){s=i+1==r?0:i+1}else{s=i-1==-1?r-1:i-1}l(f("[data-show-filtered=true]").eq(s));f("[data-show-filtered=true]").eq(i).removeClass("active")}break}});f(".lw-group-switcher li a").on("focusin",function(e){f(".lw-group-switcher li").removeClass("active");l(f(this).parent())});var i=f("body");if(!i.hasClass("has_core_admin")&&!i.hasClass("has_core_switch")&&!i.hasClass("has_core_submissions")&&!i.hasClass("has_custom_core_switch")){f(".lw-group-switcher").removeClass("lw-dropdown-menu").addClass("lw-not-switchable");f(".lw-group-switcher > a").contents().unwrap();f(".lw-group-switcher .lw-dropdown-menu").remove()}},initSearch:function e(){f("form#content-search").on("submit",function(e){e.preventDefault();var t=f(this);var i=t.find("#search_query").val();var r=f("body.admin-user").length||h.pages_editor&&h.pages_editor.is_admin?"&results[]=1&results[]=2&results[]=4":"&results[]=1";document.location.href="/livewhale/?search="+i+r+(f("body.calendar").length?"&types[]=events":"");return true})},initMobile:function e(){var t=this.$toolbar;var i=t.find("#lw-toolbar-collapse");t.on("click",".lw-navbar-toggle",function(e){if(!i.is(":visible")){e.stopPropagation();i.addClass("open");f(this).attr("aria-expanded","true");f("body").one("click",function(){i.removeClass("open");f(".lw-navbar-toggle").attr("aria-expanded","false")})}})},addDropdownHandlers:function e(){var t=this.$toolbar;var r=function e(){f(document).off("click",e);t.find(".lw-dropdown").off("keydown");t.find(".lw-dropdown-backdrop").remove();t.find(".lw-dropdown-toggle").each(function(){var e=f(this);var t=e.closest(".lw-dropdown");if(!t.hasClass("open")){return}e.attr("aria-expanded","false");t.removeClass("open")})};t.on("click",".lw-dropdown-menu",function(e){e.stopPropagation()});t.on("click",".lw-dropdown-toggle",function(e){e.preventDefault();e.stopPropagation();var t=f(this);var i=t.closest(".lw-dropdown");if(!i.hasClass("open")){r();if("ontouchstart"in document.documentElement&&!i.closest(".navbar-nav").length){f(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(f(this)).on("click",r)}f(document).on("click",r);i.on("keydown",function(e){if(e.keyCode===27){r();i.find(".lw-dropdown-toggle").trigger("focus")}});t.trigger("focus").attr("aria-expanded","true");i.toggleClass("open");h.eventHub.trigger("toolbarOpen",[i])}else{r()}})},adjustToolboxColumns:function e(){var t=this.$toolbar.find(".lw-toolbox .lw-dropdown-menu");var i=t.find("> .row > div");i.each(function(){var e=f(this);if(e.find("> ul").is(":empty")){e.remove()}});var r=i.length;var s=600;t.css("min-width",s*(r/3)+"px");var a;switch(r){case 4:a="col-sm-3";break;case 3:a="col-sm-4";break;case 2:a="col-sm-6";break;default:a="col-sm-12";break}i.removeClass(function(e,t){return(t.match(/(^|\s)col-sm-\S+/g)||[]).join(" ")}).addClass(a)}};f(function(){h.whiteout=f('