{@$__wcf->getStyleHandler()->getStylesheet(true)}
{event name='stylesheets'}
- <script data-relocate="true">
- //<![CDATA[
+ <script>
var SID_ARG_2ND = '{@SID_ARG_2ND_NOT_ENCODED}';
var WCF_PATH = '{@$__wcf->getPath()}';
var SECURITY_TOKEN = '{@SECURITY_TOKEN}';
var LANGUAGE_ID = {@$__wcf->getLanguage()->languageID};
var TIME_NOW = {@TIME_NOW};
var URL_LEGACY_MODE = {if URL_LEGACY_MODE}true{else}false{/if};
- //]]>
</script>
<script src="{@$__wcf->getPath()}js/3rdParty/jquery.min.js?v={@LAST_UPDATE_TIME}"></script>
<script src="{@$__wcf->getPath()}js/3rdParty/jquery-ui.min.js?v={@LAST_UPDATE_TIME}"></script>
<script src="{@$__wcf->getPath()}js/require.js?v={@LAST_UPDATE_TIME}"></script>
<script src="{@$__wcf->getPath()}js/require.config.js?v={@LAST_UPDATE_TIME}"></script>
<script>
- //<![CDATA[
WCF.User.init({$__wcf->user->userID}, '{@$__wcf->user->username|encodeJS}');
- //]]>
</script>
{event name='javascriptInclude'}
baseUrl: '{@$__wcf->getPath()}js'
});
- define('jquery', [], function() { return window.jQuery; });
-
$.holdReady(true);
- require(['WoltLab/WCF/Bootstrap'], function(bootstrap) {
- bootstrap.setup();
- });
</script>
<script>
- require(['Language'], function(Language) {
+ require(['Language', 'WoltLab/WCF/ACP/Bootstrap'], function(Language, ACPBootstrap) {
Language.addObject({
'__days': [ '{lang}wcf.date.day.sunday{/lang}', '{lang}wcf.date.day.monday{/lang}', '{lang}wcf.date.day.tuesday{/lang}', '{lang}wcf.date.day.wednesday{/lang}', '{lang}wcf.date.day.thursday{/lang}', '{lang}wcf.date.day.friday{/lang}', '{lang}wcf.date.day.saturday{/lang}' ],
'__daysShort': [ '{lang}wcf.date.day.sun{/lang}', '{lang}wcf.date.day.mon{/lang}', '{lang}wcf.date.day.tue{/lang}', '{lang}wcf.date.day.wed{/lang}', '{lang}wcf.date.day.thu{/lang}', '{lang}wcf.date.day.fri{/lang}', '{lang}wcf.date.day.sat{/lang}' ],
'wcf.page.pagePosition': '{lang __literal=true}wcf.page.pagePosition{/lang}'
{event name='javascriptLanguageImport'}
});
+
+ ACPBootstrap.setup();
});
$(function() {
{/if}
if (jQuery.browser.touch) $('html').addClass('touch');
- //new WCF.Date.Time();
- new WCF.Effect.SmoothScroll();
- //WCF.Dropdown.init();
+ new WCF.Effect.SmoothScroll();
WCF.System.PageNavigation.init('.pageNavigation');
WCF.Date.Picker.init();
- //WCF.System.FlexibleMenu.init();
{if $__wcf->user->userID}
new WCF.ACP.Search();
--- /dev/null
+/**
+ * Bootstraps WCF's JavaScript with additions for the ACP usage.
+ *
+ * @author Alexander Ebert
+ * @copyright 2001-2015 WoltLab GmbH
+ * @license GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
+ * @module WoltLab/WCF/ACP/Bootstrap
+ */
+define(['WoltLab/WCF/Bootstrap'], function(Bootstrap) {
+ "use strict";
+
+ /**
+ * ACP Boostrapper.
+ *
+ * @exports WoltLab/WCF/ACP/Bootstrap
+ */
+ var ACPBootstrap = {
+ /**
+ * Bootstraps general modules and frontend exclusive ones.
+ *
+ * @param {object<string, *>} options bootstrap options
+ */
+ setup: function(options) {
+ Bootstrap.setup();
+ }
+ };
+
+ return ACPBootstrap;
+});