Current File : /home/pacjaorg/.trash/media.1/vendor/debugbar/debugbar.min.js
if(typeof PhpDebugBar>"u"){var PhpDebugBar={};PhpDebugBar.$=jQuery}(function(n){typeof localStorage>"u"&&(localStorage={setItem:function(t,e){},getItem:function(t){return null}}),typeof PhpDebugBar.utils>"u"&&(PhpDebugBar.utils={});var g=PhpDebugBar.utils.getDictValue=function(t,e,i){for(var s=t,r=e.split("."),o=0;o<r.length;o++){if(!s[r[o]])return i;s=s[r[o]]}return s},u=PhpDebugBar.utils.getObjectSize=function(t){if(Object.keys)return Object.keys(t).length;var e=0;for(var i in t)t.hasOwnProperty(i)&&e++;return e};PhpDebugBar.utils.csscls=function(t,e){if(t.indexOf(" ")>-1){for(var i=t.split(" "),s=[],r=0,o=i.length;r<o;r++)s.push(PhpDebugBar.utils.csscls(i[r],e));return s.join(" ")}return t.indexOf(".")===0?"."+e+t.substr(1):e+t},PhpDebugBar.utils.makecsscls=function(t){var e=function(i){return PhpDebugBar.utils.csscls(i,t)};return e};var a=PhpDebugBar.utils.makecsscls("phpdebugbar-"),l=PhpDebugBar.Widget=function(t){this._attributes=n.extend({},this.defaults),this._boundAttributes={},this.$el=n("<"+this.tagName+" />"),this.className&&this.$el.addClass(this.className),this.initialize.apply(this,[t||{}]),this.render.apply(this)};n.extend(l.prototype,{tagName:"div",className:null,defaults:{},initialize:function(t){this.set(t)},render:function(){},set:function(t,e){if(typeof t!="string"){for(var i in t)this.set(i,t[i]);return}if(this._attributes[t]=e,typeof this._boundAttributes[t]<"u")for(var s=0,r=this._boundAttributes[t].length;s<r;s++)this._boundAttributes[t][s].apply(this,[e])},has:function(t){return typeof this._attributes[t]<"u"&&this._attributes[t]!==null},get:function(t){return this._attributes[t]},bindAttr:function(t,e){if(Array.isArray(t)){for(var i=0,s=t.length;i<s;i++)this.bindAttr(t[i],e);return}if(typeof this._boundAttributes[t]>"u"&&(this._boundAttributes[t]=[]),typeof e=="object"){var r=e;e=function(o){r.text(o||"")}}this._boundAttributes[t].push(e),this.has(t)&&e.apply(this,[this._attributes[t]])}}),l.extend=function(t){var e=this,i=function(){return e.apply(this,arguments)};n.extend(i,e);var s=function(){this.constructor=i};return s.prototype=e.prototype,i.prototype=new s,n.extend(i.prototype,t),i.__super__=e.prototype,i};var f=l.extend({className:a("panel"),render:function(){this.$tab=n("<a />").addClass(a("tab")),this.$icon=n("<i />").appendTo(this.$tab),this.bindAttr("icon",function(t){t?this.$icon.attr("class","phpdebugbar-fa phpdebugbar-fa-"+t):this.$icon.attr("class","")}),this.bindAttr("title",n("<span />").addClass(a("text")).appendTo(this.$tab)),this.$badge=n("<span />").addClass(a("badge")).appendTo(this.$tab),this.bindAttr("badge",function(t){t!==null?(this.$badge.text(t),this.$badge.addClass(a("visible"))):this.$badge.removeClass(a("visible"))}),this.bindAttr("widget",function(t){this.$el.empty().append(t.$el)}),this.bindAttr("data",function(t){this.has("widget")&&(this.get("widget").set("data",t),n.isEmptyObject(t)||this.$tab.show())})}}),c=l.extend({tagName:"span",className:a("indicator"),render:function(){this.$icon=n("<i />").appendTo(this.$el),this.bindAttr("icon",function(t){t?this.$icon.attr("class","phpdebugbar-fa phpdebugbar-fa-"+t):this.$icon.attr("class","")}),this.bindAttr(["title","data"],n("<span />").addClass(a("text")).appendTo(this.$el)),this.$tooltip=n("<span />").addClass(a("tooltip disabled")).appendTo(this.$el),this.bindAttr("tooltip",function(t){t?this.$tooltip.text(t).removeClass(a("disabled")):this.$tooltip.addClass(a("disabled"))})}}),b=PhpDebugBar.DatasetTitleFormater=function(t){this.debugbar=t};n.extend(b.prototype,{format:function(t,e,i,r){i?i=" "+i:i="";var r=r||u(this.debugbar.datasets);if(typeof e.__meta>"u")return"#"+r+i;var o=e.__meta.uri.split("/"),h=o.pop();h||(h=(o.pop()||"")+"/"),o.length&&!isNaN(h)&&(h=o.pop()+"/"+h);var d=150;h.length>d&&(h=h.substr(0,d)+"...");var p="#"+r+" "+h+i+" ("+e.__meta.datetime.split(" ")[1]+")";return p}});var m=PhpDebugBar.DebugBar=l.extend({className:"phpdebugbar "+a("minimized"),options:{bodyMarginBottom:!0,bodyMarginBottomHeight:0},initialize:function(){this.controls={},this.dataMap={},this.datasets={},this.firstTabName=null,this.activePanelName=null,this.activeDatasetId=null,this.hideEmptyTabs=!1,this.datesetTitleFormater=new b(this),this.options.bodyMarginBottomHeight=parseInt(n("body").css("margin-bottom"));try{this.isIframe=window.self!==window.top&&window.top.phpdebugbar}catch{this.isIframe=!1}this.registerResizeHandler()},registerResizeHandler:function(){if(!(typeof this.resize.bind>"u"||this.isIframe)){var t=this.resize.bind(this);this.respCSSSize=0,n(window).resize(t),setTimeout(t,20)}},resize:function(){var t=this.respCSSSize;this.respCSSSize==0&&this.$header.find("> *:visible").each(function(){t+=n(this).outerWidth(!0)});var e=this.$header.width(),i=a("mini-design"),s=this.$header.hasClass(i);e<=t&&!s?(this.respCSSSize=t,this.$header.addClass(i)):t<e&&s&&(this.respCSSSize=0,this.$header.removeClass(i)),this.setHeight(this.$body.height())},render:function(){this.isIframe&&this.$el.hide();var t=this;this.$el.appendTo("body"),this.$dragCapture=n("<div />").addClass(a("drag-capture")).appendTo(this.$el),this.$resizehdle=n("<div />").addClass(a("resize-handle")).appendTo(this.$el),this.$header=n("<div />").addClass(a("header")).appendTo(this.$el),this.$headerBtn=n("<a />").addClass(a("restore-btn")).appendTo(this.$header),this.$headerBtn.click(function(){t.close()}),this.$headerLeft=n("<div />").addClass(a("header-left")).appendTo(this.$header),this.$headerRight=n("<div />").addClass(a("header-right")).appendTo(this.$header);var e=this.$body=n("<div />").addClass(a("body")).appendTo(this.$el);this.recomputeBottomOffset();var i,s;this.$resizehdle.on("mousedown",function(h){s=e.height(),i=h.pageY,e.parents().on("mousemove",r).on("mouseup",o),t.$dragCapture.show(),h.preventDefault()});var r=function(h){var d=s+(i-h.pageY);t.setHeight(d)},o=function(){e.parents().off("mousemove",r).off("mouseup",o),t.$dragCapture.hide()};this.$closebtn=n("<a />").addClass(a("close-btn")).appendTo(this.$headerRight),this.$closebtn.click(function(){t.close()}),this.$minimizebtn=n("<a />").addClass(a("minimize-btn")).appendTo(this.$headerRight),this.$minimizebtn.click(function(){t.minimize()}),this.$maximizebtn=n("<a />").addClass(a("maximize-btn")).appendTo(this.$headerRight),this.$maximizebtn.click(function(){t.restore()}),this.$restorebtn=n("<a />").addClass(a("restore-btn")).hide().appendTo(this.$el),this.$restorebtn.click(function(){t.restore()}),this.$openbtn=n("<a />").addClass(a("open-btn")).appendTo(this.$headerRight).hide(),this.$openbtn.click(function(){t.openHandler.show(function(h,d){t.addDataSet(d,h,"(opened)"),t.showTab()})}),this.$datasets=n("<select />").addClass(a("datasets-switcher")).attr("name","datasets-switcher").appendTo(this.$headerRight),this.$datasets.change(function(){t.showDataSet(this.value)})},setHeight:function(t){var e=40,i=n(window).innerHeight()-this.$header.height()-10;t=Math.min(t,i),t=Math.max(t,e),this.$body.css("height",t),localStorage.setItem("phpdebugbar-height",t),this.recomputeBottomOffset()},restoreState:function(){if(!this.isIframe){var t=localStorage.getItem("phpdebugbar-height");this.setHeight(t||this.$body.height());var e=localStorage.getItem("phpdebugbar-open");if(e&&e=="0")this.close();else{var i=localStorage.getItem("phpdebugbar-visible");if(i&&i=="1"){var s=localStorage.getItem("phpdebugbar-tab");this.isTab(s)?this.showTab(s):this.showTab()}}}},createTab:function(t,e,i){var s=new f({title:i||t.replace(/[_\-]/g," ").charAt(0).toUpperCase()+t.slice(1),widget:e});return this.addTab(t,s)},addTab:function(t,e){if(this.isControl(t))throw new Error(t+" already exists");var i=this;return e.$tab.appendTo(this.$headerLeft).click(function(){!i.isMinimized()&&i.activePanelName==t?i.minimize():i.showTab(t)}),this.hideEmptyTabs&&e.$tab.hide(),e.$tab.attr("data-collector",t),e.$el.attr("data-collector",t),e.$el.appendTo(this.$body),this.controls[t]=e,this.firstTabName==null&&(this.firstTabName=t),e},createIndicator:function(t,e,i,s){var r=new c({icon:e,tooltip:i});return this.addIndicator(t,r,s)},addIndicator:function(t,e,i){if(this.isControl(t))throw new Error(t+" already exists");return i=="left"?e.$el.insertBefore(this.$headerLeft.children().first()):e.$el.appendTo(this.$headerRight),this.controls[t]=e,e},getControl:function(t){if(this.isControl(t))return this.controls[t]},isControl:function(t){return typeof this.controls[t]<"u"},isTab:function(t){return this.isControl(t)&&this.controls[t]instanceof f},isIndicator:function(t){return this.isControl(t)&&this.controls[t]instanceof c},reset:function(){this.minimize();var t=this;n.each(this.controls,function(e,i){t.isTab(e)&&i.$tab.remove(),i.$el.remove()}),this.controls={}},showTab:function(t){if(t||(this.activePanelName?t=this.activePanelName:t=this.firstTabName),!this.isTab(t))throw new Error("Unknown tab '"+t+"'");this.$resizehdle.show(),this.$body.show(),this.recomputeBottomOffset(),n(this.$header).find("> div > ."+a("active")).removeClass(a("active")),n(this.$body).find("> ."+a("active")).removeClass(a("active")),this.controls[t].$tab.addClass(a("active")),this.controls[t].$el.addClass(a("active")),this.activePanelName=t,this.$el.removeClass(a("minimized")),localStorage.setItem("phpdebugbar-visible","1"),localStorage.setItem("phpdebugbar-tab",t),this.resize()},minimize:function(){this.$header.find("> div > ."+a("active")).removeClass(a("active")),this.$body.hide(),this.$resizehdle.hide(),this.recomputeBottomOffset(),localStorage.setItem("phpdebugbar-visible","0"),this.$el.addClass(a("minimized")),this.resize()},isMinimized:function(){return this.$el.hasClass(a("minimized"))},close:function(){this.$resizehdle.hide(),this.$header.hide(),this.$body.hide(),this.$restorebtn.show(),localStorage.setItem("phpdebugbar-open","0"),this.$el.addClass(a("closed")),this.recomputeBottomOffset()},isClosed:function(){return this.$el.hasClass(a("closed"))},restore:function(){this.$resizehdle.show(),this.$header.show(),this.$restorebtn.hide(),localStorage.setItem("phpdebugbar-open","1");var t=localStorage.getItem("phpdebugbar-tab");this.isTab(t)?this.showTab(t):this.showTab(),this.$el.removeClass(a("closed")),this.resize()},recomputeBottomOffset:function(){if(this.options.bodyMarginBottom){if(this.isClosed())return n("body").css("margin-bottom",this.options.bodyMarginBottomHeight||"");var t=parseInt(this.$el.height())+(this.options.bodyMarginBottomHeight||0);n("body").css("margin-bottom",t)}},setDataMap:function(t){this.dataMap=t},addDataMap:function(t){n.extend(this.dataMap,t)},setData:function(t){return this.datasets={},this.addDataSet(t)},addDataSet:function(t,e,i,s){if(!(!t||!t.__meta)){if(this.isIframe){window.top.phpdebugbar.addDataSet(t,e,"(iframe)"+(i||""),s);return}var r=u(this.datasets)+1;e=e||r,t.__meta.nb=r,t.__meta.suffix=i,this.datasets[e]=t;var o=this.datesetTitleFormater.format(e,this.datasets[e],i,r);if(this.datasetTab){this.datasetTab.set("data",this.datasets);var h=u(this.datasets);this.datasetTab.set("badge",h>1?h:null),this.datasetTab.$tab.show()}return this.$datasets.append(n('<option value="'+e+'">'+o+"</option>")),this.$datasets.children().length>1&&this.$datasets.show(),(typeof s>"u"||s)&&this.showDataSet(e),this.resize(),e}},loadDataSet:function(t,e,i,s){if(!this.openHandler)throw new Error("loadDataSet() needs an open handler");var r=this;this.openHandler.load(t,function(o){r.addDataSet(o,t,e,s),r.resize(),i&&i(o)})},getDataSet:function(t){return this.datasets[t]},showDataSet:function(t){this.activeDatasetId=t,this.dataChangeHandler(this.datasets[t]),this.$datasets.val()!==t&&this.$datasets.val(t),this.datasetTab&&this.datasetTab.get("widget").set("id",t)},dataChangeHandler:function(t){var e=this;n.each(this.dataMap,function(i,s){var r=g(t,s[0],s[1]);i.indexOf(":")!=-1?(i=i.split(":"),e.getControl(i[0]).set(i[1],r)):e.getControl(i).set("data",r)}),e.resize()},setOpenHandler:function(t){this.openHandler=t,t!==null?this.$openbtn.show():this.$openbtn.hide()},setHideEmptyTabs:function(t){this.hideEmptyTabs=t},getOpenHandler:function(){return this.openHandler},enableAjaxHandlerTab:function(){this.datasetTab=new PhpDebugBar.DebugBar.Tab({icon:"history",title:"Request history",widget:new PhpDebugBar.Widgets.DatasetWidget({debugbar:this})}),this.datasetTab.$tab.addClass(a("tab-history")),this.datasetTab.$tab.attr("data-collector","__datasets"),this.datasetTab.$el.attr("data-collector","__datasets"),this.datasetTab.$tab.insertAfter(this.$openbtn).hide(),this.datasetTab.$tab.click(()=>{!this.isMinimized()&&self.activePanelName=="__datasets"?this.minimize():this.showTab("__datasets")}),this.datasetTab.$el.appendTo(this.$body),this.controls.__datasets=this.datasetTab}});m.Tab=f,m.Indicator=c;var v=PhpDebugBar.AjaxHandler=function(t,e,i){this.debugbar=t,this.headerName=e||"phpdebugbar",this.autoShow=typeof i>"u"?!0:i,localStorage.getItem("phpdebugbar-ajaxhandler-autoshow")!==null&&(this.autoShow=localStorage.getItem("phpdebugbar-ajaxhandler-autoshow")=="1")};n.extend(v.prototype,{handle:function(t){return this.isFetch(t)&&!t.headers.has(this.headerName+"-id")||this.isXHR(t)&&t.getAllResponseHeaders().indexOf(this.headerName)===-1||this.loadFromId(t)?!0:this.loadFromData(t)},getHeader:function(t,e){return this.isFetch(t)?t.headers.get(e):t.getResponseHeader(e)},isFetch:function(t){return Object.prototype.toString.call(t)=="[object Response]"},isXHR:function(t){return Object.prototype.toString.call(t)=="[object XMLHttpRequest]"},setAutoShow:function(t){this.autoShow=t,localStorage.setItem("phpdebugbar-ajaxhandler-autoshow",t?"1":"0")},loadFromId:function(t){var e=this.extractIdFromHeaders(t);return e&&this.debugbar.openHandler?(this.debugbar.loadDataSet(e,"(ajax)",void 0,this.autoShow),!0):!1},extractIdFromHeaders:function(t){return this.getHeader(t,this.headerName+"-id")},loadFromData:function(t){var e=this.extractDataFromHeaders(t);if(!e)return!1;var i=this.parseHeaders(e);if(i.error)throw new Error("Error loading debugbar data: "+i.error);return i.data&&this.debugbar.addDataSet(i.data,i.id,"(ajax)",this.autoShow),!0},extractDataFromHeaders:function(t){var e=this.getHeader(t,this.headerName);if(e){for(var i=1;;i++){var s=this.getHeader(t,this.headerName+"-"+i);if(!s)break;e+=s}return decodeURIComponent(e)}},parseHeaders:function(t){return JSON.parse(t)},bindToFetch:function(){var t=this,e=window.fetch;e!==void 0&&e.polyfill!==void 0||(window.fetch=function(){var i=e.apply(this,arguments);return i.then(function(s){t.handle(s)}).catch(function(s){}),i})},bindToJquery:function(t){var e=this;t(document).ajaxComplete(function(i,s,r){r.ignoreDebugBarAjaxHandler||e.handle(s)})},bindToXHR:function(){var t=this,e=XMLHttpRequest.prototype.open;XMLHttpRequest.prototype.open=function(i,s,r,o,h){var d=this;this.addEventListener("readystatechange",function(){var p=t.debugbar.openHandler?t.debugbar.openHandler.get("url"):null,$=typeof s=="string"?s:s.href;d.readyState==4&&$.indexOf(p)!==0&&t.handle(d)},!1),e.apply(this,Array.prototype.slice.call(arguments))}}})})(PhpDebugBar.$);
Site is undergoing maintenance

PACJA Events

Maintenance mode is on

Site will be available soon. Thank you for your patience!