AdminLTE/dist/js/adminlte.min.js

7 lines
8.4 KiB
JavaScript
Raw Normal View History

2018-03-17 17:07:55 +00:00
/*!
2018-07-15 14:56:30 +00:00
* AdminLTE v3.0.0-beta.1 (https://adminlte.io)
2019-03-24 16:58:28 +00:00
* Copyright 2014-2019 Abdullah Almsaeed <abdullah@almsaeedstudio.com>
2018-03-17 17:07:55 +00:00
* Licensed under MIT (https://github.com/almasaeed2010/AdminLTE/blob/master/LICENSE)
*/
2019-03-24 16:58:28 +00:00
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t(e.adminlte={})}(this,function(e){"use strict";var i,t,o,n,r,s,a,c,l,f,u,d,h,p,y,g,_,m,v,C,w,b,E,j,D,S,Q,x,I,L,A,O,P,T,k,H,M,N,z,U,W,X,R,V,q,B,F,G,J,K,Y,Z,$,ee,te,ne,ie,oe,re,se,ae,ce,le,fe,ue,de,he,pe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ye=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},ge=(i=jQuery,t="ControlSidebar",o="lte.control.sidebar",n=i.fn[t],r=".control-sidebar",s='[data-widget="control-sidebar"]',a=".main-header",c="control-sidebar-open",l="control-sidebar-slide-open",f={slide:!0},u=function(){function n(e,t){ye(this,n),this._element=e,this._config=this._getConfig(t)}return n.prototype.show=function(){this._config.slide?i("body").removeClass(l):i("body").removeClass(c)},n.prototype.collapse=function(){this._config.slide?i("body").addClass(l):i("body").addClass(c)},n.prototype.toggle=function(){this._setMargin(),i("body").hasClass(c)||i("body").hasClass(l)?this.show():this.collapse()},n.prototype._getConfig=function(e){return i.extend({},f,e)},n.prototype._setMargin=function(){i(r).css({top:i(a).outerHeight()})},n._jQueryInterface=function(t){return this.each(function(){var e=i(this).data(o);if(e||(e=new n(this,i(this).data()),i(this).data(o,e)),"undefined"===e[t])throw new Error(t+" is not a function");e[t]()})},n}(),i(document).on("click",s,function(e){e.preventDefault(),u._jQueryInterface.call(i(this),"toggle")}),i.fn[t]=u._jQueryInterface,i.fn[t].Constructor=u,i.fn[t].noConflict=function(){return i.fn[t]=n,u._jQueryInterface},u),_e=(d=jQuery,h="Layout",p="lte.layout",y=d.fn[h],g=".main-header",_=".main-sidebar .sidebar",m=".content-wrapper",v=".main-footer",C="hold-transition",w="layout-fixed",b=function(){function n(e){ye(this,n),this._element=e,this._init()}return n.prototype.fixLayoutHeight=function(){var e={window:d(window).height(),header:d(g).outerHeight(),footer:d(v).outerHeight(),sidebar:d(_).height()};console.log(e);var t=this._max(e);d(m).css("min-height",t-e.header-e.footer),d(_).css("min-height",t-e.header),d("body").hasClass(w)||"undefined"!=typeof d.fn.slimScroll&&d(_).slimScroll({destroy:!0}).slimScroll({height:t-e.header})},n.prototype._init=function(){var e=this;d("body").removeClass(C),this.fixLayoutHeight(),d(_).on("collapsed.lte.treeview expanded.lte.treeview collapsed.lte.pushmenu expanded.lte.pushmenu",function(){e.fixLayoutHeight()}),d(window).resize(function(){console.log("resized"),e.fixLayoutHeight()}),d("body, html").css("height","auto")},n.prototype._max=function(t){var n=0;return Object.keys(t).forEach(function(e){t[e]>n&&(n=t[e])}),n},n._jQueryInterface=function(t){return this.each(function(){var e=d(this).data(p);e||(e=new n(this),d(this).data(p,e)),t&&e[t]()})},n}(),d(window).on("load",function(){b._jQueryInterface.call(d("body"))}),d.fn[h]=b._jQueryInterface,d.fn[h].Constructor=b,d.fn[h].noConflict=function(){return d.fn[h]=y,b._jQueryInterface},b),me=(E=jQuery,j="PushMenu",S="."+(D="lte.pushmenu"),Q=E.fn[j],x={COLLAPSED:"collapsed"+S,SHOWN:"shown"+S},I={screenCollapseSize:768},L='[data-widget="pushmenu"]',A="body",O="#sidebar-overlay",P=".wrapper",T="sidebar-collapse",k="sidebar-open",H=function(){function n(e,t){ye(this,n),this._element=e,this._options=E.extend({},I,t),E(O).length||this._addOverlay()}return n.prototype.show=function(){E(A).addClass(k).removeClass(T);var e=E.Event(x.SHOWN);E(this._element).trigger(e)},n.prototype.collapse=function(){E(A).removeClass(k).addClass(T);var e=E.Event(x.COLLAPSED);E(this._element).trigger(e)},n.prototype.toggle=function(){(E(window).width()>=this._options.screenCollapseSize?!E(A).hasClass(T):E(A).hasClass(k))?this.collapse():this.show()},n.prototype._addOverlay=function(){var e=this,t=E("<div />",{id:"sidebar-overlay"});t.on("click",function(){e.collapse()}),E(P).append(t)},n._jQueryI
2018-03-17 17:07:55 +00:00
//# sourceMappingURL=adminlte.min.js.map