/**
* Bootstraps WCF's JavaScript with additions for the ACP usage.
*
- * @author Alexander Ebert
- * @copyright 2001-2019 WoltLab GmbH
- * @license GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
- * @module WoltLabSuite/Core/Acp/Bootstrap
+ * @author Alexander Ebert
+ * @copyright 2001-2019 WoltLab GmbH
+ * @license GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
+ * @module WoltLabSuite/Core/Acp/Bootstrap
*/
-define(['Core', 'WoltLabSuite/Core/Bootstrap', './Ui/Page/Menu'], function (Core, Bootstrap, UiPageMenu) {
+define(["require", "exports", "tslib", "../Core", "../Bootstrap", "./Ui/Page/Menu"], function (require, exports, tslib_1, Core, Bootstrap_1, UiPageMenu) {
"use strict";
+ Object.defineProperty(exports, "__esModule", { value: true });
+ exports.setup = void 0;
+ Core = tslib_1.__importStar(Core);
+ UiPageMenu = tslib_1.__importStar(UiPageMenu);
/**
- * @exports WoltLabSuite/Core/Acp/Bootstrap
+ * Bootstraps general modules and frontend exclusive ones.
+ *
+ * @param {Object=} options bootstrap options
*/
- return {
- /**
- * Bootstraps general modules and frontend exclusive ones.
- *
- * @param {Object=} options bootstrap options
- */
- setup: function (options) {
- options = Core.extend({
- bootstrap: {
- enableMobileMenu: true
- }
- }, options);
- Bootstrap.setup(options.bootstrap);
- UiPageMenu.init();
- }
- };
+ function setup(options) {
+ options = Core.extend({
+ bootstrap: {
+ enableMobileMenu: true,
+ },
+ }, options);
+ Bootstrap_1.setup(options.bootstrap);
+ UiPageMenu.init();
+ }
+ exports.setup = setup;
});
+++ /dev/null
-/**
- * Bootstraps WCF's JavaScript with additions for the ACP usage.
- *
- * @author Alexander Ebert
- * @copyright 2001-2019 WoltLab GmbH
- * @license GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
- * @module WoltLabSuite/Core/Acp/Bootstrap
- */
-define(['Core', 'WoltLabSuite/Core/Bootstrap', './Ui/Page/Menu'], function(Core, Bootstrap, UiPageMenu) {
- "use strict";
-
- /**
- * @exports WoltLabSuite/Core/Acp/Bootstrap
- */
- return {
- /**
- * Bootstraps general modules and frontend exclusive ones.
- *
- * @param {Object=} options bootstrap options
- */
- setup: function(options) {
- options = Core.extend({
- bootstrap: {
- enableMobileMenu: true
- }
- }, options);
-
- Bootstrap.setup(options.bootstrap);
- UiPageMenu.init();
- }
- };
-});
--- /dev/null
+/**
+ * Bootstraps WCF's JavaScript with additions for the ACP usage.
+ *
+ * @author Alexander Ebert
+ * @copyright 2001-2019 WoltLab GmbH
+ * @license GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
+ * @module WoltLabSuite/Core/Acp/Bootstrap
+ */
+
+import * as Core from "../Core";
+import { BoostrapOptions, setup as bootstrapSetup } from "../Bootstrap";
+import * as UiPageMenu from "./Ui/Page/Menu";
+
+interface AcpBootstrapOptions {
+ bootstrap: BoostrapOptions;
+}
+
+/**
+ * Bootstraps general modules and frontend exclusive ones.
+ *
+ * @param {Object=} options bootstrap options
+ */
+export function setup(options: AcpBootstrapOptions): void {
+ options = Core.extend(
+ {
+ bootstrap: {
+ enableMobileMenu: true,
+ },
+ },
+ options,
+ ) as AcpBootstrapOptions;
+
+ bootstrapSetup(options.bootstrap);
+ UiPageMenu.init();
+}