{"version":3,"file":"adminlte.js","sources":["../../build/js/ControlSidebar.js","../../build/js/Layout.js","../../build/js/PushMenu.js","../../build/js/Treeview.js","../../build/js/DirectChat.js","../../build/js/TodoList.js","../../build/js/CardWidget.js","../../build/js/CardRefresh.js","../../build/js/Dropdown.js","../../build/js/Toasts.js"],"sourcesContent":["/**\n * --------------------------------------------\n * AdminLTE ControlSidebar.js\n * License MIT\n * --------------------------------------------\n */\n\nconst ControlSidebar = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'ControlSidebar'\n const DATA_KEY = 'lte.controlsidebar'\n const EVENT_KEY = `.${DATA_KEY}`\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n const DATA_API_KEY = '.data-api'\n\n const Event = {\n COLLAPSED: `collapsed${EVENT_KEY}`,\n EXPANDED: `expanded${EVENT_KEY}`,\n }\n\n const Selector = {\n CONTROL_SIDEBAR: '.control-sidebar',\n CONTROL_SIDEBAR_CONTENT: '.control-sidebar-content',\n DATA_TOGGLE: '[data-widget=\"control-sidebar\"]',\n CONTENT: '.content-wrapper',\n HEADER: '.main-header',\n FOOTER: '.main-footer',\n }\n\n const ClassName = {\n CONTROL_SIDEBAR_ANIMATE: 'control-sidebar-animate',\n CONTROL_SIDEBAR_OPEN: 'control-sidebar-open',\n CONTROL_SIDEBAR_SLIDE: 'control-sidebar-slide-open',\n LAYOUT_FIXED: 'layout-fixed',\n NAVBAR_FIXED: 'layout-navbar-fixed',\n NAVBAR_SM_FIXED: 'layout-sm-navbar-fixed',\n NAVBAR_MD_FIXED: 'layout-md-navbar-fixed',\n NAVBAR_LG_FIXED: 'layout-lg-navbar-fixed',\n NAVBAR_XL_FIXED: 'layout-xl-navbar-fixed',\n FOOTER_FIXED: 'layout-footer-fixed',\n FOOTER_SM_FIXED: 'layout-sm-footer-fixed',\n FOOTER_MD_FIXED: 'layout-md-footer-fixed',\n FOOTER_LG_FIXED: 'layout-lg-footer-fixed',\n FOOTER_XL_FIXED: 'layout-xl-footer-fixed',\n }\n\n const Default = {\n controlsidebarSlide: true,\n scrollbarTheme : 'os-theme-light',\n scrollbarAutoHide: 'l',\n }\n\n /**\n * Class Definition\n * ====================================================\n */\n\n class ControlSidebar {\n constructor(element, config) {\n this._element = element\n this._config = config\n\n this._init()\n }\n\n // Public\n\n show() {\n // Show the control sidebar\n if (this._config.controlsidebarSlide) {\n $('html').addClass(ClassName.CONTROL_SIDEBAR_ANIMATE)\n $('body').removeClass(ClassName.CONTROL_SIDEBAR_SLIDE).delay(300).queue(function(){\n $(Selector.CONTROL_SIDEBAR).hide()\n $('html').removeClass(ClassName.CONTROL_SIDEBAR_ANIMATE)\n $(this).dequeue()\n })\n } else {\n $('body').removeClass(ClassName.CONTROL_SIDEBAR_OPEN)\n }\n\n const expandedEvent = $.Event(Event.EXPANDED)\n $(this._element).trigger(expandedEvent)\n }\n\n collapse() {\n // Collapse the control sidebar\n if (this._config.controlsidebarSlide) {\n $('html').addClass(ClassName.CONTROL_SIDEBAR_ANIMATE)\n $(Selector.CONTROL_SIDEBAR).show().delay(10).queue(function(){\n $('body').addClass(ClassName.CONTROL_SIDEBAR_SLIDE).delay(300).queue(function(){\n $('html').removeClass(ClassName.CONTROL_SIDEBAR_ANIMATE)\n $(this).dequeue()\n })\n $(this).dequeue()\n })\n } else {\n $('body').addClass(ClassName.CONTROL_SIDEBAR_OPEN)\n }\n\n const collapsedEvent = $.Event(Event.COLLAPSED)\n $(this._element).trigger(collapsedEvent)\n }\n\n toggle() {\n const shouldOpen = $('body').hasClass(ClassName.CONTROL_SIDEBAR_OPEN) || $('body')\n .hasClass(ClassName.CONTROL_SIDEBAR_SLIDE)\n if (shouldOpen) {\n // Open the control sidebar\n this.show()\n } else {\n // Close the control sidebar\n this.collapse()\n }\n }\n\n // Private\n\n _init() {\n this._fixHeight()\n this._fixScrollHeight()\n\n $(window).resize(() => {\n this._fixHeight()\n this._fixScrollHeight()\n })\n\n $(window).scroll(() => {\n if ($('body').hasClass(ClassName.CONTROL_SIDEBAR_OPEN) || $('body').hasClass(ClassName.CONTROL_SIDEBAR_SLIDE)) {\n this._fixScrollHeight()\n }\n })\n }\n\n _fixScrollHeight() {\n const heights = {\n scroll: $(document).height(),\n window: $(window).height(),\n header: $(Selector.HEADER).outerHeight(),\n footer: $(Selector.FOOTER).outerHeight(),\n }\n const positions = {\n bottom: Math.abs((heights.window + $(window).scrollTop()) - heights.scroll),\n top: $(window).scrollTop(),\n }\n\n let navbarFixed = false;\n let footerFixed = false;\n\n if ($('body').hasClass(ClassName.LAYOUT_FIXED)) {\n if (\n $('body').hasClass(ClassName.NAVBAR_FIXED)\n || $('body').hasClass(ClassName.NAVBAR_SM_FIXED)\n || $('body').hasClass(ClassName.NAVBAR_MD_FIXED)\n || $('body').hasClass(ClassName.NAVBAR_LG_FIXED)\n || $('body').hasClass(ClassName.NAVBAR_XL_FIXED)\n ) {\n if ($(Selector.HEADER).css(\"position\") === \"fixed\") {\n navbarFixed = true;\n }\n }\n if (\n $('body').hasClass(ClassName.FOOTER_FIXED)\n || $('body').hasClass(ClassName.FOOTER_SM_FIXED)\n || $('body').hasClass(ClassName.FOOTER_MD_FIXED)\n || $('body').hasClass(ClassName.FOOTER_LG_FIXED)\n || $('body').hasClass(ClassName.FOOTER_XL_FIXED)\n ) {\n if ($(Selector.FOOTER).css(\"position\") === \"fixed\") {\n footerFixed = true;\n }\n }\n\n if (positions.top === 0 && positions.bottom === 0) {\n $(Selector.CONTROL_SIDEBAR).css('bottom', heights.footer);\n $(Selector.CONTROL_SIDEBAR).css('top', heights.header);\n $(Selector.CONTROL_SIDEBAR + ', ' + Selector.CONTROL_SIDEBAR + ' ' + Selector.CONTROL_SIDEBAR_CONTENT).css('height', heights.window - (heights.header + heights.footer))\n } else if (positions.bottom <= heights.footer) {\n if (footerFixed === false) { \n $(Selector.CONTROL_SIDEBAR).css('bottom', heights.footer - positions.bottom);\n $(Selector.CONTROL_SIDEBAR + ', ' + Selector.CONTROL_SIDEBAR + ' ' + Selector.CONTROL_SIDEBAR_CONTENT).css('height', heights.window - (heights.footer - positions.bottom))\n } else {\n $(Selector.CONTROL_SIDEBAR).css('bottom', heights.footer);\n }\n } else if (positions.top <= heights.header) {\n if (navbarFixed === false) {\n $(Selector.CONTROL_SIDEBAR).css('top', heights.header - positions.top);\n $(Selector.CONTROL_SIDEBAR + ', ' + Selector.CONTROL_SIDEBAR + ' ' + Selector.CONTROL_SIDEBAR_CONTENT).css('height', heights.window - (heights.header - positions.top))\n } else {\n $(Selector.CONTROL_SIDEBAR).css('top', heights.header);\n }\n } else {\n if (navbarFixed === false) {\n $(Selector.CONTROL_SIDEBAR).css('top', 0);\n $(Selector.CONTROL_SIDEBAR + ', ' + Selector.CONTROL_SIDEBAR + ' ' + Selector.CONTROL_SIDEBAR_CONTENT).css('height', heights.window)\n } else {\n $(Selector.CONTROL_SIDEBAR).css('top', heights.header);\n }\n }\n }\n }\n\n _fixHeight() {\n const heights = {\n window: $(window).height(),\n header: $(Selector.HEADER).outerHeight(),\n footer: $(Selector.FOOTER).outerHeight(),\n }\n\n if ($('body').hasClass(ClassName.LAYOUT_FIXED)) {\n let sidebarHeight = heights.window - heights.header;\n\n if (\n $('body').hasClass(ClassName.FOOTER_FIXED)\n || $('body').hasClass(ClassName.FOOTER_SM_FIXED)\n || $('body').hasClass(ClassName.FOOTER_MD_FIXED)\n || $('body').hasClass(ClassName.FOOTER_LG_FIXED)\n || $('body').hasClass(ClassName.FOOTER_XL_FIXED)\n ) {\n if ($(Selector.FOOTER).css(\"position\") === \"fixed\") {\n sidebarHeight = heights.window - heights.header - heights.footer;\n }\n }\n\n $(Selector.CONTROL_SIDEBAR + ' ' + Selector.CONTROL_SIDEBAR_CONTENT).css('height', sidebarHeight)\n \n if (typeof $.fn.overlayScrollbars !== 'undefined') {\n $(Selector.CONTROL_SIDEBAR + ' ' + Selector.CONTROL_SIDEBAR_CONTENT).overlayScrollbars({\n className : this._config.scrollbarTheme,\n sizeAutoCapable : true,\n scrollbars : {\n autoHide: this._config.scrollbarAutoHide, \n clickScrolling : true\n }\n })\n }\n }\n }\n\n\n // Static\n\n static _jQueryInterface(operation) {\n return this.each(function () {\n let data = $(this).data(DATA_KEY)\n\n if (!data) {\n data = new ControlSidebar(this, $(this).data())\n $(this).data(DATA_KEY, data)\n }\n\n if (data[operation] === 'undefined') {\n throw new Error(`${operation} is not a function`)\n }\n\n data[operation]()\n })\n }\n }\n\n /**\n *\n * Data Api implementation\n * ====================================================\n */\n $(document).on('click', Selector.DATA_TOGGLE, function (event) {\n event.preventDefault()\n\n ControlSidebar._jQueryInterface.call($(this), 'toggle')\n })\n\n /**\n * jQuery API\n * ====================================================\n */\n\n $.fn[NAME] = ControlSidebar._jQueryInterface\n $.fn[NAME].Constructor = ControlSidebar\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return ControlSidebar._jQueryInterface\n }\n\n return ControlSidebar\n})(jQuery)\n\nexport default ControlSidebar\n","/**\n * --------------------------------------------\n * AdminLTE Layout.js\n * License MIT\n * --------------------------------------------\n */\n\nconst Layout = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'Layout'\n const DATA_KEY = 'lte.layout'\n const EVENT_KEY = `.${DATA_KEY}`\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n\n const Event = {\n SIDEBAR: 'sidebar'\n }\n\n const Selector = {\n HEADER : '.main-header',\n MAIN_SIDEBAR : '.main-sidebar',\n SIDEBAR : '.main-sidebar .sidebar',\n CONTENT : '.content-wrapper',\n BRAND : '.brand-link',\n CONTENT_HEADER : '.content-header',\n WRAPPER : '.wrapper',\n CONTROL_SIDEBAR: '.control-sidebar',\n LAYOUT_FIXED : '.layout-fixed',\n FOOTER : '.main-footer',\n PUSHMENU_BTN : '[data-widget=\"pushmenu\"]',\n LOGIN_BOX : '.login-box',\n REGISTER_BOX : '.register-box'\n }\n\n const ClassName = {\n HOLD : 'hold-transition',\n SIDEBAR : 'main-sidebar',\n CONTENT_FIXED : 'content-fixed',\n SIDEBAR_FOCUSED: 'sidebar-focused',\n LAYOUT_FIXED : 'layout-fixed',\n NAVBAR_FIXED : 'layout-navbar-fixed',\n FOOTER_FIXED : 'layout-footer-fixed',\n LOGIN_PAGE : 'login-page',\n REGISTER_PAGE : 'register-page',\n }\n\n const Default = {\n scrollbarTheme : 'os-theme-light',\n scrollbarAutoHide: 'l'\n }\n\n /**\n * Class Definition\n * ====================================================\n */\n\n class Layout {\n constructor(element, config) {\n this._config = config\n this._element = element\n\n this._init()\n }\n\n // Public\n\n fixLayoutHeight() {\n const heights = {\n window: $(window).height(),\n header: $(Selector.HEADER).length !== 0 ? $(Selector.HEADER).outerHeight() : 0,\n footer: $(Selector.FOOTER).length !== 0 ? $(Selector.FOOTER).outerHeight() : 0,\n sidebar: $(Selector.SIDEBAR).length !== 0 ? $(Selector.SIDEBAR).height() : 0,\n }\n\n const max = this._max(heights)\n\n if (max == heights.window) {\n $(Selector.CONTENT).css('min-height', max - heights.header - heights.footer)\n } else {\n $(Selector.CONTENT).css('min-height', max - heights.header)\n }\n\n if ($('body').hasClass(ClassName.LAYOUT_FIXED)) {\n $(Selector.CONTENT).css('min-height', max - heights.header - heights.footer)\n\n if (typeof $.fn.overlayScrollbars !== 'undefined') {\n $(Selector.SIDEBAR).overlayScrollbars({\n className : this._config.scrollbarTheme,\n sizeAutoCapable : true,\n scrollbars : {\n autoHide: this._config.scrollbarAutoHide, \n clickScrolling : true\n }\n })\n }\n }\n }\n\n // Private\n\n _init() {\n // Activate layout height watcher\n this.fixLayoutHeight()\n $(Selector.SIDEBAR)\n .on('collapsed.lte.treeview expanded.lte.treeview', () => {\n this.fixLayoutHeight()\n })\n\n $(Selector.PUSHMENU_BTN)\n .on('collapsed.lte.pushmenu shown.lte.pushmenu', () => {\n this.fixLayoutHeight()\n })\n\n $(window).resize(() => {\n this.fixLayoutHeight()\n })\n\n if (!$('body').hasClass(ClassName.LOGIN_PAGE) && !$('body').hasClass(ClassName.REGISTER_PAGE)) {\n $('body, html').css('height', 'auto')\n } else if ($('body').hasClass(ClassName.LOGIN_PAGE) || $('body').hasClass(ClassName.REGISTER_PAGE)) {\n let box_height = $(Selector.LOGIN_BOX + ', ' + Selector.REGISTER_BOX).height()\n\n $('body').css('min-height', box_height);\n }\n\n $('body.hold-transition').removeClass('hold-transition')\n }\n\n _max(numbers) {\n // Calculate the maximum number in a list\n let max = 0\n\n Object.keys(numbers).forEach((key) => {\n if (numbers[key] > max) {\n max = numbers[key]\n }\n })\n\n return max\n }\n\n // Static\n\n static _jQueryInterface(config) {\n return this.each(function () {\n let data = $(this).data(DATA_KEY)\n const _config = $.extend({}, Default, $(this).data())\n\n if (!data) {\n data = new Layout($(this), _config)\n $(this).data(DATA_KEY, data)\n }\n\n if (config === 'init') {\n data[config]()\n }\n })\n }\n }\n\n /**\n * Data API\n * ====================================================\n */\n\n $(window).on('load', () => {\n Layout._jQueryInterface.call($('body'))\n })\n\n $(Selector.SIDEBAR + ' a').on('focusin', () => {\n $(Selector.MAIN_SIDEBAR).addClass(ClassName.SIDEBAR_FOCUSED);\n })\n\n $(Selector.SIDEBAR + ' a').on('focusout', () => {\n $(Selector.MAIN_SIDEBAR).removeClass(ClassName.SIDEBAR_FOCUSED);\n })\n\n /**\n * jQuery API\n * ====================================================\n */\n\n $.fn[NAME] = Layout._jQueryInterface\n $.fn[NAME].Constructor = Layout\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return Layout._jQueryInterface\n }\n\n return Layout\n})(jQuery)\n\nexport default Layout\n","/**\n * --------------------------------------------\n * AdminLTE PushMenu.js\n * License MIT\n * --------------------------------------------\n */\n\nconst PushMenu = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'PushMenu'\n const DATA_KEY = 'lte.pushmenu'\n const EVENT_KEY = `.${DATA_KEY}`\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n\n const Event = {\n COLLAPSED: `collapsed${EVENT_KEY}`,\n SHOWN: `shown${EVENT_KEY}`\n }\n\n const Default = {\n autoCollapseSize: 992,\n enableRemember: false,\n noTransitionAfterReload: true\n }\n\n const Selector = {\n TOGGLE_BUTTON: '[data-widget=\"pushmenu\"]',\n SIDEBAR_MINI: '.sidebar-mini',\n SIDEBAR_COLLAPSED: '.sidebar-collapse',\n BODY: 'body',\n OVERLAY: '#sidebar-overlay',\n WRAPPER: '.wrapper'\n }\n\n const ClassName = {\n SIDEBAR_OPEN: 'sidebar-open',\n COLLAPSED: 'sidebar-collapse',\n OPEN: 'sidebar-open'\n }\n\n /**\n * Class Definition\n * ====================================================\n */\n\n class PushMenu {\n constructor(element, options) {\n this._element = element\n this._options = $.extend({}, Default, options)\n\n if (!$(Selector.OVERLAY).length) {\n this._addOverlay()\n }\n\n this._init()\n }\n\n // Public\n\n show() {\n if (this._options.autoCollapseSize) {\n if ($(window).width() <= this._options.autoCollapseSize) {\n $(Selector.BODY).addClass(ClassName.OPEN)\n }\n }\n\n $(Selector.BODY).removeClass(ClassName.COLLAPSED)\n\n if(this._options.enableRemember) {\n localStorage.setItem(`remember${EVENT_KEY}`, ClassName.OPEN)\n }\n\n const shownEvent = $.Event(Event.SHOWN)\n $(this._element).trigger(shownEvent)\n }\n\n collapse() {\n if (this._options.autoCollapseSize) {\n if ($(window).width() <= this._options.autoCollapseSize) {\n $(Selector.BODY).removeClass(ClassName.OPEN)\n }\n }\n\n $(Selector.BODY).addClass(ClassName.COLLAPSED)\n\n if(this._options.enableRemember) {\n localStorage.setItem(`remember${EVENT_KEY}`, ClassName.COLLAPSED)\n }\n\n const collapsedEvent = $.Event(Event.COLLAPSED)\n $(this._element).trigger(collapsedEvent)\n }\n\n toggle() {\n if (!$(Selector.BODY).hasClass(ClassName.COLLAPSED )) {\n this.collapse()\n } else {\n this.show()\n }\n }\n\n autoCollapse(resize = false) {\n if (this._options.autoCollapseSize) {\n if ($(window).width() <= this._options.autoCollapseSize) {\n if (!$(Selector.BODY).hasClass(ClassName.OPEN)) {\n this.collapse()\n }\n } else if (resize == true) {\n if ($(Selector.BODY).hasClass(ClassName.OPEN)) {\n $(Selector.BODY).removeClass(ClassName.OPEN)\n }\n }\n }\n }\n\n remember() {\n if(this._options.enableRemember) {\n let toggleState = localStorage.getItem(`remember${EVENT_KEY}`)\n if (toggleState == ClassName.COLLAPSED){\n if (this._options.noTransitionAfterReload) {\n $(\"body\").addClass('hold-transition').addClass(ClassName.COLLAPSED).delay(50).queue(function() {\n $(this).removeClass('hold-transition')\n $(this).dequeue()\n })\n } else {\n $(\"body\").addClass(ClassName.COLLAPSED)\n }\n } else {\n if (this._options.noTransitionAfterReload) {\n $(\"body\").addClass('hold-transition').removeClass(ClassName.COLLAPSED).delay(50).queue(function() {\n $(this).removeClass('hold-transition')\n $(this).dequeue()\n })\n } else {\n $(\"body\").removeClass(ClassName.COLLAPSED)\n }\n }\n }\n }\n\n // Private\n\n _init() {\n this.remember()\n this.autoCollapse()\n\n $(window).resize(() => {\n this.autoCollapse(true)\n })\n }\n\n _addOverlay() {\n const overlay = $('
', {\n id: 'sidebar-overlay'\n })\n\n overlay.on('click', () => {\n this.collapse()\n })\n\n $(Selector.WRAPPER).append(overlay)\n }\n\n // Static\n\n static _jQueryInterface(operation) {\n return this.each(function () {\n let data = $(this).data(DATA_KEY)\n const _options = $.extend({}, Default, $(this).data())\n\n if (!data) {\n data = new PushMenu(this, _options)\n $(this).data(DATA_KEY, data)\n }\n\n if (operation === 'toggle') {\n data[operation]()\n }\n })\n }\n }\n\n /**\n * Data API\n * ====================================================\n */\n\n $(document).on('click', Selector.TOGGLE_BUTTON, (event) => {\n event.preventDefault()\n\n let button = event.currentTarget\n\n if ($(button).data('widget') !== 'pushmenu') {\n button = $(button).closest(Selector.TOGGLE_BUTTON)\n }\n\n PushMenu._jQueryInterface.call($(button), 'toggle')\n })\n\n $(window).on('load', () => {\n PushMenu._jQueryInterface.call($(Selector.TOGGLE_BUTTON))\n })\n\n /**\n * jQuery API\n * ====================================================\n */\n\n $.fn[NAME] = PushMenu._jQueryInterface\n $.fn[NAME].Constructor = PushMenu\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return PushMenu._jQueryInterface\n }\n\n return PushMenu\n})(jQuery)\n\nexport default PushMenu\n","/**\n * --------------------------------------------\n * AdminLTE Treeview.js\n * License MIT\n * --------------------------------------------\n */\n\nconst Treeview = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'Treeview'\n const DATA_KEY = 'lte.treeview'\n const EVENT_KEY = `.${DATA_KEY}`\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n\n const Event = {\n SELECTED : `selected${EVENT_KEY}`,\n EXPANDED : `expanded${EVENT_KEY}`,\n COLLAPSED : `collapsed${EVENT_KEY}`,\n LOAD_DATA_API: `load${EVENT_KEY}`\n }\n\n const Selector = {\n LI : '.nav-item',\n LINK : '.nav-link',\n TREEVIEW_MENU: '.nav-treeview',\n OPEN : '.menu-open',\n DATA_WIDGET : '[data-widget=\"treeview\"]'\n }\n\n const ClassName = {\n LI : 'nav-item',\n LINK : 'nav-link',\n TREEVIEW_MENU: 'nav-treeview',\n OPEN : 'menu-open'\n }\n\n const Default = {\n trigger : `${Selector.DATA_WIDGET} ${Selector.LINK}`,\n animationSpeed: 300,\n accordion : true\n }\n\n /**\n * Class Definition\n * ====================================================\n */\n class Treeview {\n constructor(element, config) {\n this._config = config\n this._element = element\n }\n\n // Public\n\n init() {\n this._setupListeners()\n }\n\n expand(treeviewMenu, parentLi) {\n const expandedEvent = $.Event(Event.EXPANDED)\n\n if (this._config.accordion) {\n const openMenuLi = parentLi.siblings(Selector.OPEN).first()\n const openTreeview = openMenuLi.find(Selector.TREEVIEW_MENU).first()\n this.collapse(openTreeview, openMenuLi)\n }\n\n treeviewMenu.stop().slideDown(this._config.animationSpeed, () => {\n parentLi.addClass(ClassName.OPEN)\n $(this._element).trigger(expandedEvent)\n })\n }\n\n collapse(treeviewMenu, parentLi) {\n const collapsedEvent = $.Event(Event.COLLAPSED)\n\n treeviewMenu.stop().slideUp(this._config.animationSpeed, () => {\n parentLi.removeClass(ClassName.OPEN)\n $(this._element).trigger(collapsedEvent)\n treeviewMenu.find(`${Selector.OPEN} > ${Selector.TREEVIEW_MENU}`).slideUp()\n treeviewMenu.find(Selector.OPEN).removeClass(ClassName.OPEN)\n })\n }\n\n toggle(event) {\n\n const $relativeTarget = $(event.currentTarget)\n const $parent = $relativeTarget.parent()\n\n let treeviewMenu = $parent.find('> ' + Selector.TREEVIEW_MENU)\n\n if (!treeviewMenu.is(Selector.TREEVIEW_MENU)) {\n\n if (!$parent.is(Selector.LI)) {\n treeviewMenu = $parent.parent().find('> ' + Selector.TREEVIEW_MENU)\n }\n\n if (!treeviewMenu.is(Selector.TREEVIEW_MENU)) {\n return\n }\n }\n \n event.preventDefault()\n\n const parentLi = $relativeTarget.parents(Selector.LI).first()\n const isOpen = parentLi.hasClass(ClassName.OPEN)\n\n if (isOpen) {\n this.collapse($(treeviewMenu), parentLi)\n } else {\n this.expand($(treeviewMenu), parentLi)\n }\n }\n\n // Private\n\n _setupListeners() {\n $(document).on('click', this._config.trigger, (event) => {\n this.toggle(event)\n })\n }\n\n // Static\n\n static _jQueryInterface(config) {\n return this.each(function () {\n let data = $(this).data(DATA_KEY)\n const _config = $.extend({}, Default, $(this).data())\n\n if (!data) {\n data = new Treeview($(this), _config)\n $(this).data(DATA_KEY, data)\n }\n\n if (config === 'init') {\n data[config]()\n }\n })\n }\n }\n\n /**\n * Data API\n * ====================================================\n */\n\n $(window).on(Event.LOAD_DATA_API, () => {\n $(Selector.DATA_WIDGET).each(function () {\n Treeview._jQueryInterface.call($(this), 'init')\n })\n })\n\n /**\n * jQuery API\n * ====================================================\n */\n\n $.fn[NAME] = Treeview._jQueryInterface\n $.fn[NAME].Constructor = Treeview\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return Treeview._jQueryInterface\n }\n\n return Treeview\n})(jQuery)\n\nexport default Treeview\n","/**\n * --------------------------------------------\n * AdminLTE DirectChat.js\n * License MIT\n * --------------------------------------------\n */\n\nconst DirectChat = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'DirectChat'\n const DATA_KEY = 'lte.directchat'\n const EVENT_KEY = `.${DATA_KEY}`\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n const DATA_API_KEY = '.data-api'\n\n const Event = {\n TOGGLED: `toggled{EVENT_KEY}`\n }\n\n const Selector = {\n DATA_TOGGLE: '[data-widget=\"chat-pane-toggle\"]',\n DIRECT_CHAT: '.direct-chat'\n };\n\n const ClassName = {\n DIRECT_CHAT_OPEN: 'direct-chat-contacts-open'\n };\n\n /**\n * Class Definition\n * ====================================================\n */\n\n class DirectChat {\n constructor(element, config) {\n this._element = element\n }\n\n toggle() {\n $(this._element).parents(Selector.DIRECT_CHAT).first().toggleClass(ClassName.DIRECT_CHAT_OPEN);\n\n const toggledEvent = $.Event(Event.TOGGLED)\n $(this._element).trigger(toggledEvent)\n }\n\n // Static\n\n static _jQueryInterface(config) {\n return this.each(function () {\n let data = $(this).data(DATA_KEY)\n\n if (!data) {\n data = new DirectChat($(this))\n $(this).data(DATA_KEY, data)\n }\n\n data[config]()\n })\n }\n }\n\n /**\n *\n * Data Api implementation\n * ====================================================\n */\n\n $(document).on('click', Selector.DATA_TOGGLE, function (event) {\n if (event) event.preventDefault();\n DirectChat._jQueryInterface.call($(this), 'toggle');\n });\n\n /**\n * jQuery API\n * ====================================================\n */\n\n $.fn[NAME] = DirectChat._jQueryInterface\n $.fn[NAME].Constructor = DirectChat\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return DirectChat._jQueryInterface\n }\n\n return DirectChat\n})(jQuery)\n\nexport default DirectChat\n","/**\n * --------------------------------------------\n * AdminLTE TodoList.js\n * License MIT\n * --------------------------------------------\n */\n\nconst TodoList = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'TodoList'\n const DATA_KEY = 'lte.todolist'\n const EVENT_KEY = `.${DATA_KEY}`\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n\n const Selector = {\n DATA_TOGGLE: '[data-widget=\"todo-list\"]'\n }\n\n const ClassName = {\n TODO_LIST_DONE: 'done'\n }\n\n const Default = {\n onCheck: function (item) {\n return item;\n },\n onUnCheck: function (item) {\n return item;\n }\n }\n\n /**\n * Class Definition\n * ====================================================\n */\n\n class TodoList {\n constructor(element, config) {\n this._config = config\n this._element = element\n\n this._init()\n }\n\n // Public\n\n toggle(item) {\n item.parents('li').toggleClass(ClassName.TODO_LIST_DONE);\n if (! $(item).prop('checked')) {\n this.unCheck($(item));\n return;\n }\n\n this.check(item);\n }\n\n check (item) {\n this._config.onCheck.call(item);\n }\n\n unCheck (item) {\n this._config.onUnCheck.call(item);\n }\n\n // Private\n\n _init() {\n var that = this\n $(Selector.DATA_TOGGLE).find('input:checkbox:checked').parents('li').toggleClass(ClassName.TODO_LIST_DONE)\n $(Selector.DATA_TOGGLE).on('change', 'input:checkbox', (event) => {\n that.toggle($(event.target))\n })\n }\n\n // Static\n\n static _jQueryInterface(config) {\n return this.each(function () {\n let data = $(this).data(DATA_KEY)\n const _config = $.extend({}, Default, $(this).data())\n\n if (!data) {\n data = new TodoList($(this), _config)\n $(this).data(DATA_KEY, data)\n }\n\n if (config === 'init') {\n data[config]()\n }\n })\n }\n }\n\n /**\n * Data API\n * ====================================================\n */\n\n $(window).on('load', () => {\n TodoList._jQueryInterface.call($(Selector.DATA_TOGGLE))\n })\n\n /**\n * jQuery API\n * ====================================================\n */\n\n $.fn[NAME] = TodoList._jQueryInterface\n $.fn[NAME].Constructor = TodoList\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return TodoList._jQueryInterface\n }\n\n return TodoList\n})(jQuery)\n\nexport default TodoList\n","/**\n * --------------------------------------------\n * AdminLTE CardWidget.js\n * License MIT\n * --------------------------------------------\n */\n\nconst CardWidget = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'CardWidget'\n const DATA_KEY = 'lte.cardwidget'\n const EVENT_KEY = `.${DATA_KEY}`\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n\n const Event = {\n EXPANDED: `expanded${EVENT_KEY}`,\n COLLAPSED: `collapsed${EVENT_KEY}`,\n MAXIMIZED: `maximized${EVENT_KEY}`,\n MINIMIZED: `minimized${EVENT_KEY}`,\n REMOVED: `removed${EVENT_KEY}`\n }\n\n const ClassName = {\n CARD: 'card',\n COLLAPSED: 'collapsed-card',\n WAS_COLLAPSED: 'was-collapsed',\n MAXIMIZED: 'maximized-card',\n }\n\n const Selector = {\n DATA_REMOVE: '[data-card-widget=\"remove\"]',\n DATA_COLLAPSE: '[data-card-widget=\"collapse\"]',\n DATA_MAXIMIZE: '[data-card-widget=\"maximize\"]',\n CARD: `.${ClassName.CARD}`,\n CARD_HEADER: '.card-header',\n CARD_BODY: '.card-body',\n CARD_FOOTER: '.card-footer',\n COLLAPSED: `.${ClassName.COLLAPSED}`,\n }\n\n const Default = {\n animationSpeed: 'normal',\n collapseTrigger: Selector.DATA_COLLAPSE,\n removeTrigger: Selector.DATA_REMOVE,\n maximizeTrigger: Selector.DATA_MAXIMIZE,\n collapseIcon: 'fa-minus',\n expandIcon: 'fa-plus',\n maximizeIcon: 'fa-expand',\n minimizeIcon: 'fa-compress',\n }\n\n class CardWidget {\n constructor(element, settings) {\n this._element = element\n this._parent = element.parents(Selector.CARD).first()\n\n if (element.hasClass(ClassName.CARD)) {\n this._parent = element\n }\n\n this._settings = $.extend({}, Default, settings)\n }\n\n collapse() {\n this._parent.children(`${Selector.CARD_BODY}, ${Selector.CARD_FOOTER}`)\n .slideUp(this._settings.animationSpeed, () => {\n this._parent.addClass(ClassName.COLLAPSED)\n })\n this._parent.find(this._settings.collapseTrigger + ' .' + this._settings.collapseIcon)\n .addClass(this._settings.expandIcon)\n .removeClass(this._settings.collapseIcon)\n\n const collapsed = $.Event(Event.COLLAPSED)\n\n this._element.trigger(collapsed, this._parent)\n }\n\n expand() {\n this._parent.children(`${Selector.CARD_BODY}, ${Selector.CARD_FOOTER}`)\n .slideDown(this._settings.animationSpeed, () => {\n this._parent.removeClass(ClassName.COLLAPSED)\n })\n\n this._parent.find(this._settings.collapseTrigger + ' .' + this._settings.expandIcon)\n .addClass(this._settings.collapseIcon)\n .removeClass(this._settings.expandIcon)\n\n const expanded = $.Event(Event.EXPANDED)\n\n this._element.trigger(expanded, this._parent)\n }\n\n remove() {\n this._parent.slideUp()\n\n const removed = $.Event(Event.REMOVED)\n\n this._element.trigger(removed, this._parent)\n }\n\n toggle() {\n if (this._parent.hasClass(ClassName.COLLAPSED)) {\n this.expand()\n return\n }\n\n this.collapse()\n }\n \n maximize() {\n this._parent.find(this._settings.maximizeTrigger + ' .' + this._settings.maximizeIcon)\n .addClass(this._settings.minimizeIcon)\n .removeClass(this._settings.maximizeIcon)\n this._parent.css({\n 'height': this._parent.height(),\n 'width': this._parent.width(),\n 'transition': 'all .15s'\n }).delay(150).queue(function(){\n $(this).addClass(ClassName.MAXIMIZED)\n $('html').addClass(ClassName.MAXIMIZED)\n if ($(this).hasClass(ClassName.COLLAPSED)) {\n $(this).addClass(ClassName.WAS_COLLAPSED)\n }\n $(this).dequeue()\n })\n\n const maximized = $.Event(Event.MAXIMIZED)\n\n this._element.trigger(maximized, this._parent)\n }\n\n minimize() {\n this._parent.find(this._settings.maximizeTrigger + ' .' + this._settings.minimizeIcon)\n .addClass(this._settings.maximizeIcon)\n .removeClass(this._settings.minimizeIcon)\n this._parent.css('cssText', 'height:' + this._parent[0].style.height + ' !important;' +\n 'width:' + this._parent[0].style.width + ' !important; transition: all .15s;'\n ).delay(10).queue(function(){\n $(this).removeClass(ClassName.MAXIMIZED)\n $('html').removeClass(ClassName.MAXIMIZED)\n $(this).css({\n 'height': 'inherit',\n 'width': 'inherit'\n })\n if ($(this).hasClass(ClassName.WAS_COLLAPSED)) {\n $(this).removeClass(ClassName.WAS_COLLAPSED)\n }\n $(this).dequeue()\n })\n\n const MINIMIZED = $.Event(Event.MINIMIZED)\n\n this._element.trigger(MINIMIZED, this._parent)\n }\n\n toggleMaximize() {\n if (this._parent.hasClass(ClassName.MAXIMIZED)) {\n this.minimize()\n return\n }\n\n this.maximize()\n }\n\n // Private\n\n _init(card) {\n this._parent = card\n\n $(this).find(this._settings.collapseTrigger).click(() => {\n this.toggle()\n })\n\n $(this).find(this._settings.maximizeTrigger).click(() => {\n this.toggleMaximize()\n })\n\n $(this).find(this._settings.removeTrigger).click(() => {\n this.remove()\n })\n }\n\n // Static\n\n static _jQueryInterface(config) {\n let data = $(this).data(DATA_KEY)\n\n if (!data) {\n data = new CardWidget($(this), data)\n $(this).data(DATA_KEY, typeof config === 'string' ? data: config)\n }\n\n if (typeof config === 'string' && config.match(/collapse|expand|remove|toggle|maximize|minimize|toggleMaximize/)) {\n data[config]()\n } else if (typeof config === 'object') {\n data._init($(this))\n }\n }\n }\n\n /**\n * Data API\n * ====================================================\n */\n\n $(document).on('click', Selector.DATA_COLLAPSE, function (event) {\n if (event) {\n event.preventDefault()\n }\n\n CardWidget._jQueryInterface.call($(this), 'toggle')\n })\n\n $(document).on('click', Selector.DATA_REMOVE, function (event) {\n if (event) {\n event.preventDefault()\n }\n\n CardWidget._jQueryInterface.call($(this), 'remove')\n })\n\n $(document).on('click', Selector.DATA_MAXIMIZE, function (event) {\n if (event) {\n event.preventDefault()\n }\n\n CardWidget._jQueryInterface.call($(this), 'toggleMaximize')\n })\n\n /**\n * jQuery API\n * ====================================================\n */\n\n $.fn[NAME] = CardWidget._jQueryInterface\n $.fn[NAME].Constructor = CardWidget\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return CardWidget._jQueryInterface\n }\n\n return CardWidget\n})(jQuery)\n\nexport default CardWidget\n","/**\n * --------------------------------------------\n * AdminLTE CardRefresh.js\n * License MIT\n * --------------------------------------------\n */\n\nconst CardRefresh = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'CardRefresh'\n const DATA_KEY = 'lte.cardrefresh'\n const EVENT_KEY = `.${DATA_KEY}`\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n\n const Event = {\n LOADED: `loaded${EVENT_KEY}`,\n OVERLAY_ADDED: `overlay.added${EVENT_KEY}`,\n OVERLAY_REMOVED: `overlay.removed${EVENT_KEY}`,\n }\n\n const ClassName = {\n CARD: 'card',\n }\n\n const Selector = {\n CARD: `.${ClassName.CARD}`,\n DATA_REFRESH: '[data-card-widget=\"card-refresh\"]',\n }\n\n const Default = {\n source: '',\n sourceSelector: '',\n params: {},\n trigger: Selector.DATA_REFRESH,\n content: '.card-body',\n loadInContent: true,\n loadOnInit: true,\n responseType: '',\n overlayTemplate: ' ',\n onLoadStart: function () {\n },\n onLoadDone: function (response) {\n return response;\n }\n }\n\n class CardRefresh {\n constructor(element, settings) {\n this._element = element\n this._parent = element.parents(Selector.CARD).first()\n this._settings = $.extend({}, Default, settings)\n this._overlay = $(this._settings.overlayTemplate)\n\n if (element.hasClass(ClassName.CARD)) {\n this._parent = element\n }\n\n if (this._settings.source === '') {\n throw new Error('Source url was not defined. Please specify a url in your CardRefresh source option.');\n }\n\n this._init();\n\n if (this._settings.loadOnInit) {\n this.load();\n }\n }\n\n load() {\n this._addOverlay()\n this._settings.onLoadStart.call($(this))\n\n $.get(this._settings.source, this._settings.params, function (response) {\n if (this._settings.loadInContent) {\n if (this._settings.sourceSelector != '') {\n response = $(response).find(this._settings.sourceSelector).html()\n }\n\n this._parent.find(this._settings.content).html(response)\n }\n\n this._settings.onLoadDone.call($(this), response)\n this._removeOverlay();\n }.bind(this), this._settings.responseType !== '' && this._settings.responseType)\n\n const loadedEvent = $.Event(Event.LOADED)\n $(this._element).trigger(loadedEvent)\n }\n\n _addOverlay() {\n this._parent.append(this._overlay)\n\n const overlayAddedEvent = $.Event(Event.OVERLAY_ADDED)\n $(this._element).trigger(overlayAddedEvent)\n };\n\n _removeOverlay() {\n this._parent.find(this._overlay).remove()\n\n const overlayRemovedEvent = $.Event(Event.OVERLAY_REMOVED)\n $(this._element).trigger(overlayRemovedEvent)\n };\n\n\n // Private\n\n _init(card) {\n $(this).find(this._settings.trigger).on('click', () => {\n this.load()\n })\n }\n\n // Static\n\n static _jQueryInterface(config) {\n let data = $(this).data(DATA_KEY)\n let options = $(this).data()\n\n if (!data) {\n data = new CardRefresh($(this), options)\n $(this).data(DATA_KEY, typeof config === 'string' ? data: config)\n }\n\n if (typeof config === 'string' && config.match(/load/)) {\n data[config]()\n } else if (typeof config === 'object') {\n data._init($(this))\n }\n }\n }\n\n /**\n * Data API\n * ====================================================\n */\n\n $(document).on('click', Selector.DATA_REFRESH, function (event) {\n if (event) {\n event.preventDefault()\n }\n\n CardRefresh._jQueryInterface.call($(this), 'load')\n })\n\n /**\n * jQuery API\n * ====================================================\n */\n\n $.fn[NAME] = CardRefresh._jQueryInterface\n $.fn[NAME].Constructor = CardRefresh\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return CardRefresh._jQueryInterface\n }\n\n return CardRefresh\n})(jQuery)\n\nexport default CardRefresh\n","/**\n * --------------------------------------------\n * AdminLTE Dropdown.js\n * License MIT\n * --------------------------------------------\n */\n\nconst Dropdown = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'Dropdown'\n const DATA_KEY = 'lte.dropdown'\n const EVENT_KEY = `.${DATA_KEY}`\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n\n const Selector = {\n DROPDOWN_MENU: 'ul.dropdown-menu',\n DROPDOWN_TOGGLE: '[data-toggle=\"dropdown\"]',\n }\n\n const ClassName = {\n DROPDOWN_HOVER: '.dropdown-hover'\n }\n\n const Default = {\n }\n\n\n /**\n * Class Definition\n * ====================================================\n */\n\n class Dropdown {\n constructor(element, config) {\n this._config = config\n this._element = element\n }\n\n // Public\n\n toggleSubmenu() {\n this._element.siblings().show().toggleClass(\"show\");\n\n if (! this._element.next().hasClass('show')) {\n this._element.parents('.dropdown-menu').first().find('.show').removeClass(\"show\").hide();\n }\n\n this._element.parents('li.nav-item.dropdown.show').on('hidden.bs.dropdown', function(e) {\n $('.dropdown-submenu .show').removeClass(\"show\").hide();\n });\n\n }\n\n // Static\n\n static _jQueryInterface(config) {\n return this.each(function () {\n let data = $(this).data(DATA_KEY)\n const _config = $.extend({}, Default, $(this).data())\n\n if (!data) {\n data = new Dropdown($(this), _config)\n $(this).data(DATA_KEY, data)\n }\n\n if (config === 'toggleSubmenu') {\n data[config]()\n }\n })\n }\n }\n\n /**\n * Data API\n * ====================================================\n */\n\n $(Selector.DROPDOWN_MENU + ' ' + Selector.DROPDOWN_TOGGLE).on(\"click\", function(event) {\n event.preventDefault();\n event.stopPropagation();\n\n Dropdown._jQueryInterface.call($(this), 'toggleSubmenu')\n });\n\n // $(Selector.SIDEBAR + ' a').on('focusin', () => {\n // $(Selector.MAIN_SIDEBAR).addClass(ClassName.SIDEBAR_FOCUSED);\n // })\n\n // $(Selector.SIDEBAR + ' a').on('focusout', () => {\n // $(Selector.MAIN_SIDEBAR).removeClass(ClassName.SIDEBAR_FOCUSED);\n // })\n\n /**\n * jQuery API\n * ====================================================\n */\n\n $.fn[NAME] = Dropdown._jQueryInterface\n $.fn[NAME].Constructor = Dropdown\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return Dropdown._jQueryInterface\n }\n\n return Dropdown\n})(jQuery)\n\nexport default Dropdown\n","/**\n * --------------------------------------------\n * AdminLTE Toasts.js\n * License MIT\n * --------------------------------------------\n */\n\nconst Toasts = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'Toasts'\n const DATA_KEY = 'lte.toasts'\n const EVENT_KEY = `.${DATA_KEY}`\n const JQUERY_NO_CONFLICT = $.fn[NAME]\n\n const Event = {\n INIT: `init${EVENT_KEY}`,\n CREATED: `created${EVENT_KEY}`,\n REMOVED: `removed${EVENT_KEY}`,\n }\n\n const Selector = {\n BODY: 'toast-body',\n CONTAINER_TOP_RIGHT: '#toastsContainerTopRight',\n CONTAINER_TOP_LEFT: '#toastsContainerTopLeft',\n CONTAINER_BOTTOM_RIGHT: '#toastsContainerBottomRight',\n CONTAINER_BOTTOM_LEFT: '#toastsContainerBottomLeft',\n }\n\n const ClassName = {\n TOP_RIGHT: 'toasts-top-right',\n TOP_LEFT: 'toasts-top-left',\n BOTTOM_RIGHT: 'toasts-bottom-right',\n BOTTOM_LEFT: 'toasts-bottom-left',\n FADE: 'fade',\n }\n\n const Position = {\n TOP_RIGHT: 'topRight',\n TOP_LEFT: 'topLeft',\n BOTTOM_RIGHT: 'bottomRight',\n BOTTOM_LEFT: 'bottomLeft',\n }\n\n const Id = {\n CONTAINER_TOP_RIGHT: 'toastsContainerTopRight',\n CONTAINER_TOP_LEFT: 'toastsContainerTopLeft',\n CONTAINER_BOTTOM_RIGHT: 'toastsContainerBottomRight',\n CONTAINER_BOTTOM_LEFT: 'toastsContainerBottomLeft',\n }\n\n const Default = {\n position: Position.TOP_RIGHT,\n fixed: true,\n autohide: false,\n autoremove: true,\n delay: 1000,\n fade: true,\n icon: null,\n image: null,\n imageAlt: null,\n imageHeight: '25px',\n title: null,\n subtitle: null,\n close: true,\n body: null,\n class: null,\n }\n\n /**\n * Class Definition\n * ====================================================\n */\n class Toasts {\n constructor(element, config) {\n this._config = config\n\n this._prepareContainer();\n\n const initEvent = $.Event(Event.INIT)\n $('body').trigger(initEvent)\n }\n\n // Public\n\n create() {\n var toast = $('