mirror of https://github.com/ColorlibHQ/AdminLTE
1 line
30 KiB
Plaintext
1 line
30 KiB
Plaintext
{"version":3,"sources":["../../build/js/ControlSidebar.js","../../build/js/Layout.js","../../build/js/PushMenu.js","../../build/js/Treeview.js","../../build/js/Widget.js"],"names":["$","NAME","DATA_KEY","JQUERY_NO_CONFLICT","Selector","ClassName","Default","ControlSidebar","jQuery","fn","show","this","_config","slide","removeClass","collapse","addClass","toggle","_setMargin","hasClass","_getConfig","config","extend","css","innerHeight","_jQueryInterface","operation","each","data","Error","document","on","event","preventDefault","call","Constructor","noConflict","element","_element","Layout","fixLayoutHeight","heights","window","height","outerHeight","max","_max","header","footer","overlayScrollbars","scrollbarTheme","scrollbarAutoHide","sidebar","_init","resize","numbers","keys","forEach","key","EVENT_KEY","Event","PushMenu","shownEvent","SHOWN","trigger","collapsedEvent","COLLAPSED","isShown","width","_options","screenCollapseSize","autoCollapse","autoCollapseSize","_addOverlay","overlay","append","button","currentTarget","closest","options","length","Treeview","init","_setupListeners","expand","treeviewMenu","parentLi","expandedEvent","EXPANDED","accordion","openMenuLi","siblings","first","openTreeview","find","slideDown","animationSpeed","_this","slideUp","_this2","$relativeTarget","next","is","parents","LOAD_DATA_API","Widget","_parent","children","_settings","collapsed","expanded","remove","removed","REMOVED","card","collapseTrigger","click","removeTrigger","match","_typeof","settings"],"mappings":";;;;;6RAOyBA,EAMjBC,EACAC,EAEAC,EAOAC,EAAAA,EAAAA,EAMAC,EAAAA,EAKAC,EASAC,8MApCFA,GAAmBP,EAoItBQ,OA9HKP,EAAqB,iBACrBC,EAAqB,sBAErBC,EAAqBH,EAAES,GAAGR,GAO1BG,EACa,mBADbA,EAEa,kCAFbA,EAGa,eAGbC,EACmB,uBADnBA,EAEmB,6BAGnBC,EAAU,QACP,eAgBPI,KA5C2B,WA8CrBC,KAAKC,QAAQC,QACb,QAAQC,YAAYT,KAEpB,QAAQS,YAAYT,gBAI1BU,SArD2B,WAuDrBJ,KAAKC,QAAQC,QACb,QA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QkE,QAAQnG,IAAewF,aAC3CgB,UAAY5G,GAAEsB,OAAO,GAAIhB,GAASkH","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.control.sidebar'\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 CLICK_DATA_API: `click${EVENT_KEY}${DATA_API_KEY}`\n }\n\n const Selector = {\n CONTROL_SIDEBAR: '.control-sidebar',\n DATA_TOGGLE : '[data-widget=\"control-sidebar\"]',\n MAIN_HEADER : '.main-header'\n }\n\n const ClassName = {\n CONTROL_SIDEBAR_OPEN : 'control-sidebar-open',\n CONTROL_SIDEBAR_SLIDE: 'control-sidebar-slide-open'\n }\n\n const Default = {\n slide: true\n }\n\n /**\n * Class Definition\n * ====================================================\n */\n\n class ControlSidebar {\n constructor(element, config) {\n this._element = element\n this._config = this._getConfig(config)\n }\n\n // Public\n\n show() {\n // Show the control sidebar\n if (this._config.slide) {\n $('body').removeClass(ClassName.CONTROL_SIDEBAR_SLIDE)\n } else {\n $('body').removeClass(ClassName.CONTROL_SIDEBAR_OPEN)\n }\n }\n\n collapse() {\n // Collapse the control sidebar\n if (this._config.slide) {\n $('body').addClass(ClassName.CONTROL_SIDEBAR_SLIDE)\n } else {\n $('body').addClass(ClassName.CONTROL_SIDEBAR_OPEN)\n }\n }\n\n toggle() {\n this._setMargin()\n\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 _getConfig(config) {\n return $.extend({}, Default, config)\n }\n\n _setMargin() {\n $(Selector.CONTROL_SIDEBAR).css({\n top: $(Selector.MAIN_HEADER).innerHeight()\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 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 }\n\n const ClassName = {\n HOLD : 'hold-transition',\n SIDEBAR : 'main-sidebar',\n CONTENT_FIXED: 'content-fixed',\n LAYOUT_FIXED : 'layout-fixed',\n NAVBAR_FIXED : 'layout-navbar-fixed',\n FOOTER_FIXED : 'layout-footer-fixed',\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).outerHeight(),\n footer : $(Selector.FOOTER).outerHeight(),\n sidebar : $(Selector.SIDEBAR).height(),\n }\n\n const max = this._max(heights)\n\n\n if ($('body').hasClass(ClassName.LAYOUT_FIXED)) {\n $(Selector.CONTENT).css('min-height', max - heights.header - heights.footer)\n // $(Selector.SIDEBAR).css('min-height', max - heights.header)\n $(Selector.CONTROL_SIDEBAR + ' .control-sidebar-content').css('height', max - heights.header)\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 $(Selector.CONTROL_SIDEBAR + ' .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 } else {\n if (heights.window > heights.sidebar) {\n $(Selector.CONTENT).css('min-height', heights.window - heights.header - heights.footer)\n } else {\n $(Selector.CONTENT).css('min-height', heights.sidebar - heights.header)\n }\n }\n if ($('body').hasClass(ClassName.NAVBAR_FIXED)) {\n $(Selector.BRAND).css('height', heights.header)\n $(Selector.SIDEBAR).css('margin-top', heights.header)\n $(Selector.SIDEBAR).css('margin-top', heights.header)\n }\n if ($('body').hasClass(ClassName.FOOTER_FIXED)) {\n $(Selector.CONTENT).css('margin-bottom', heights.footer)\n }\n if ($('body').hasClass(ClassName.CONTENT_FIXED)) {\n $(Selector.CONTENT).css('height', $(Selector.CONTENT).css('min-height'))\n } \n }\n\n // Private\n\n _init() {\n // Enable transitions\n $('body').removeClass(ClassName.HOLD)\n\n // Activate layout height watcher\n this.fixLayoutHeight()\n $(Selector.SIDEBAR)\n .on('collapsed.lte.treeview expanded.lte.treeview collapsed.lte.pushmenu expanded.lte.pushmenu', () => {\n this.fixLayoutHeight()\n })\n\n $(window).resize(() => {\n this.fixLayoutHeight()\n })\n\n $('body, html').css('height', 'auto')\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 /**\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: false,\n screenCollapseSize: 768\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 SIDEBAR_MINI: 'sidebar-mini'\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 this._init()\n\n if (!$(Selector.OVERLAY).length) {\n this._addOverlay()\n }\n }\n\n // Public\n\n show() {\n $(Selector.BODY).addClass(ClassName.OPEN).removeClass(ClassName.COLLAPSED)\n\n const shownEvent = $.Event(Event.SHOWN)\n $(this._element).trigger(shownEvent)\n }\n\n collapse() {\n $(Selector.BODY).removeClass(ClassName.OPEN).addClass(ClassName.COLLAPSED)\n\n const collapsedEvent = $.Event(Event.COLLAPSED)\n $(this._element).trigger(collapsedEvent)\n }\n\n isShown() {\n if ($(window).width() >= this._options.screenCollapseSize) {\n return !$(Selector.BODY).hasClass(ClassName.COLLAPSED)\n } else {\n return $(Selector.BODY).hasClass(ClassName.OPEN)\n }\n\n }\n\n toggle() {\n if (this.isShown()) {\n this.collapse()\n } else {\n this.show()\n }\n }\n\n autoCollapse() {\n if (this._options.autoCollapseSize) {\n if ($(window).width() <= this._options.autoCollapseSize) {\n if (this.isShown()) {\n this.toggle()\n }\n } else {\n if (!this.isShown()) {\n this.toggle()\n }\n }\n }\n }\n\n // Private\n\n _init() {\n this.autoCollapse()\n\n $(window).resize(() => {\n this.autoCollapse()\n })\n }\n\n _addOverlay() {\n const overlay = $('<div />', {\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 === 'init') {\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.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.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 const $relativeTarget = $(event.currentTarget)\n const treeviewMenu = $relativeTarget.next()\n\n if (!treeviewMenu.is(Selector.TREEVIEW_MENU)) {\n return\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 * AdminLTE Widget.js\n * License MIT\n * --------------------------------------------\n */\n\nconst Widget = (($) => {\n /**\n * Constants\n * ====================================================\n */\n\n const NAME = 'Widget'\n const DATA_KEY = 'lte.widget'\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 REMOVED : `removed${EVENT_KEY}`\n }\n\n const Selector = {\n DATA_REMOVE : '[data-widget=\"remove\"]',\n DATA_COLLAPSE : '[data-widget=\"collapse\"]',\n CARD : '.card',\n CARD_HEADER : '.card-header',\n CARD_BODY : '.card-body',\n CARD_FOOTER : '.card-footer',\n COLLAPSED : '.collapsed-card',\n COLLAPSE_ICON : '.fa-minus',\n EXPAND_ICON : '.fa-plus'\n }\n\n const ClassName = {\n COLLAPSED : 'collapsed-card',\n COLLAPSE_ICON : 'fa-minus',\n EXPAND_ICON : 'fa-plus'\n }\n\n const Default = {\n animationSpeed : 'normal',\n collapseTrigger: Selector.DATA_COLLAPSE,\n removeTrigger : Selector.DATA_REMOVE\n }\n\n class Widget {\n constructor(element, settings) {\n this._element = element\n this._parent = element.parents(Selector.CARD).first()\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\n this._element.children(Selector.COLLAPSE_ICON)\n .addClass(ClassName.EXPAND_ICON)\n .removeClass(ClassName.COLLAPSE_ICON)\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._element.children(Selector.EXPAND_ICON)\n .addClass(ClassName.COLLAPSE_ICON)\n .removeClass(ClassName.EXPAND_ICON)\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 // 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.removeTrigger).click(() => {\n this.remove()\n })\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 Widget($(this), data)\n $(this).data(DATA_KEY, typeof config === 'string' ? data : config)\n }\n\n if (typeof config === 'string' && config.match(/remove|toggle/)) {\n data[config]()\n } else if (typeof config === 'object') {\n data._init($(this))\n }\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 Widget._jQueryInterface.call($(this), 'toggle')\n })\n\n $(document).on('click', Selector.DATA_REMOVE, function (event) {\n if (event) {\n event.preventDefault()\n }\n\n Widget._jQueryInterface.call($(this), 'remove')\n })\n\n /**\n * jQuery API\n * ====================================================\n */\n\n $.fn[NAME] = Widget._jQueryInterface\n $.fn[NAME].Constructor = Widget\n $.fn[NAME].noConflict = function () {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return Widget._jQueryInterface\n }\n\n return Widget\n})(jQuery)\n\nexport default Widget\n"]} |