You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
3 lines
3.7 KiB
3 lines
3.7 KiB
5 years ago
|
!function(e){"use strict";function t(){}t.prototype.initTooltipPlugin=function(){e.fn.tooltip&&e('[data-toggle="tooltip"]').tooltip()},t.prototype.initPopoverPlugin=function(){e.fn.popover&&e('[data-toggle="popover"]').popover()},t.prototype.initSlimScrollPlugin=function(){e.fn.slimScroll&&e(".slimscroll").slimScroll({height:"auto",position:"right",size:"4px",touchScrollStep:20,color:"#9ea5ab"})},t.prototype.initFormValidation=function(){e(".needs-validation").on("submit",function(t){return e(this).addClass("was-validated"),!1!==e(this)[0].checkValidity()||(t.preventDefault(),t.stopPropagation(),!1)})},t.prototype.init=function(){this.initTooltipPlugin(),this.initPopoverPlugin(),this.initSlimScrollPlugin(),this.initFormValidation()},e.Components=new t,e.Components.Constructor=t}(window.jQuery),function(n){"use strict";function t(){this.$body=n("body"),this.$window=n(window)}t.prototype._resetSidebarScroll=function(){n(".slimscroll-menu").slimscroll({height:"auto",position:"right",size:"4px",color:"#9ea5ab",wheelStep:5,touchScrollStep:20})},t.prototype.initMenu=function(){var e=this;n(".button-menu-mobile").on("click",function(t){t.preventDefault(),"topnav"===e.$body.data("layout")?(n(this).toggleClass("open"),n("#topnav-menu-content").slideToggle(400)):(e.$body.toggleClass("sidebar-enable"),768<=e.$window.width()?e.$body.toggleClass("left-side-menu-condensed"):e.$body.removeClass("left-side-menu-condensed"),e._resetSidebarScroll())});var t=e.$body.data("layout");if(n("#menu-bar").length)if("topnav"!==t)new MetisMenu("#menu-bar"),e._resetSidebarScroll(),n("#menu-bar a").each(function(){var t=window.location.href.split(/[?#]/)[0];this.href==t&&(n(this).addClass("active"),n(this).parent().addClass("mm-active"),n(this).parent().parent().addClass("mm-show"),n(this).parent().parent().prev().addClass("active"),n(this).parent().parent().parent().addClass("mm-active"),n(this).parent().parent().parent().parent().addClass("mm-show"),n(this).parent().parent().parent().parent().parent().addClass("mm-active"))});else{var i=new MetisMenu("#menu-bar").on("shown.metisMenu",function(n){window.addEventListener("click",function t(e){n.target.contains(e.target)||(i.hide(n.detail.shownElement),window.removeEventListener("click",t))})});n("#menu-bar a").each(function(){var t=window.location.href.split(/[?#]/)[0];this.href==t&&(n(this).addClass("active"),n(this).parent().addClass("active"),n(this).parent().parent().prev().addClass("active"),n(this).parent().parent().parent().addClass("active"),n(this).parent().parent().parent().parent().parent().addClass("active"))})}n(".right-bar-toggle").on("click",function(t){n("body").toggleClass("right-bar-enabled")}),n(document).on("click","body",function(t){0<n(t.target).closest(".right-bar-toggle, .right-bar").length||0<n(t.target).closest(".left-side-menu, .side-nav").length||n(t.target).hasClass("button-menu-mobile")||0<n(t.target).closest(".button-menu-mobile").length||(n("body").removeClass("right-bar-enabled"),n("body").removeClass("sidebar-enable"))}),n(window).on("load",function(){n("#status").fadeOut(),n("#preloader").delay(350).fadeOut("slow")})},t.prototype.initLayout=function(){768<=this.$window.width()&&this.$window.width()<=1024?this.$body.addClass("left-side-menu-condensed"):1!=this.$body.data("left-keep-condensed")&&this.$body.removeClass("left-side-menu-condensed"),this.$body.hasClass("scrollable-layout")&&n("#sidebar-menu").removeClass("slimscroll-menu")},t.prototype.init=function(){var e=this;this.initLayout(),this.initMenu(),n.Components.init(),e.$window.on("resize",function(t){t.preventDefault(),e.initLayout(),e._resetSidebarScroll()}),feather.replace()},n.App=new t,n.App.Constructor=t}(window.jQuery),function(){"use strict";window.jQuery.App.init()}();
|
||
|
//# sourceMappingURL=app.min.js.map
|