From d0f8cab0c2f29351d4e1195978bb07de226f9ba1 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Sat, 30 Apr 2016 13:05:28 +0200 Subject: [PATCH] Added ACP-'To Top' link, increase ACP menu width --- wcfsetup/install/files/acp/style/layout.scss | 6 ++++-- wcfsetup/install/files/acp/templates/header.tpl | 1 + wcfsetup/install/files/js/WoltLab/WCF/Bootstrap.js | 6 ++++-- .../install/files/js/WoltLab/WCF/BootstrapFrontend.js | 10 ++++------ 4 files changed, 13 insertions(+), 10 deletions(-) diff --git a/wcfsetup/install/files/acp/style/layout.scss b/wcfsetup/install/files/acp/style/layout.scss index ba1902a0e0..0a298b174f 100644 --- a/wcfsetup/install/files/acp/style/layout.scss +++ b/wcfsetup/install/files/acp/style/layout.scss @@ -1,3 +1,5 @@ +$wcfAcpMenuWidth: 150px; + .layoutBoundary { margin: 0; max-width: none; @@ -29,7 +31,7 @@ align-items: center; background-color: rgb(52, 73, 94); display: flex; - flex: 0 0 120px; + flex: 0 0 $wcfAcpMenuWidth; height: 50px; justify-content: center; margin: 0; @@ -100,7 +102,7 @@ .acpPageMenu { background-color: rgb(44, 62, 80); - flex: 0 0 120px; + flex: 0 0 $wcfAcpMenuWidth; text-align: center; overflow: hidden; diff --git a/wcfsetup/install/files/acp/templates/header.tpl b/wcfsetup/install/files/acp/templates/header.tpl index 4e6bd3e478..dac2e7efe6 100644 --- a/wcfsetup/install/files/acp/templates/header.tpl +++ b/wcfsetup/install/files/acp/templates/header.tpl @@ -89,6 +89,7 @@ 'wcf.global.page.previous': '{capture assign=pagePrevious}{lang}wcf.global.page.previous{/lang}{/capture}{@$pagePrevious|encodeJS}', 'wcf.global.pageDirection': '{lang}wcf.global.pageDirection{/lang}', 'wcf.global.reason': '{lang}wcf.global.reason{/lang}', + 'wcf.global.scrollUp': '{lang}wcf.global.scrollUp{/lang}', 'wcf.global.success': '{lang}wcf.global.success{/lang}', 'wcf.global.success.add': '{lang}wcf.global.success.add{/lang}', 'wcf.global.success.edit': '{lang}wcf.global.success.edit{/lang}', diff --git a/wcfsetup/install/files/js/WoltLab/WCF/Bootstrap.js b/wcfsetup/install/files/js/WoltLab/WCF/Bootstrap.js index 43a7925128..32dfb3a3f6 100644 --- a/wcfsetup/install/files/js/WoltLab/WCF/Bootstrap.js +++ b/wcfsetup/install/files/js/WoltLab/WCF/Bootstrap.js @@ -13,13 +13,13 @@ define( 'favico', 'enquire', 'perfect-scrollbar', 'WoltLab/WCF/Date/Time/Relative', 'Ui/SimpleDropdown', 'WoltLab/WCF/Ui/Mobile', 'WoltLab/WCF/Ui/TabMenu', 'WoltLab/WCF/Ui/FlexibleMenu', 'Ui/Dialog', 'WoltLab/WCF/Ui/Tooltip', 'WoltLab/WCF/Language', 'WoltLab/WCF/Environment', - 'WoltLab/WCF/Date/Picker', 'EventHandler', 'Core' + 'WoltLab/WCF/Date/Picker', 'EventHandler', 'Core', 'WoltLab/WCF/Ui/Page/JumpToTop' ], function( favico, enquire, perfectScrollbar, DateTimeRelative, UiSimpleDropdown, UiMobile, UiTabMenu, UiFlexibleMenu, UiDialog, UiTooltip, Language, Environment, - DatePicker, EventHandler, Core + DatePicker, EventHandler, Core, UiPageJumpToTop ) { "use strict"; @@ -65,6 +65,8 @@ define( UiDialog.setup(); UiTooltip.setup(); + new UiPageJumpToTop(); + // convert method=get into method=post var forms = elBySelAll('form[method=get]'); for (var i = 0, length = forms.length; i < length; i++) { diff --git a/wcfsetup/install/files/js/WoltLab/WCF/BootstrapFrontend.js b/wcfsetup/install/files/js/WoltLab/WCF/BootstrapFrontend.js index a0ce412ce5..6ff3dd0a95 100644 --- a/wcfsetup/install/files/js/WoltLab/WCF/BootstrapFrontend.js +++ b/wcfsetup/install/files/js/WoltLab/WCF/BootstrapFrontend.js @@ -8,12 +8,12 @@ */ define( [ - 'Ajax', 'WoltLab/WCF/Bootstrap', 'WoltLab/WCF/Controller/Sitemap', 'WoltLab/WCF/Controller/Style/Changer', - 'WoltLab/WCF/Controller/Popover', 'WoltLab/WCF/Ui/Page/JumpToTop', 'WoltLab/WCF/Ui/User/Ignore' + 'Ajax', 'WoltLab/WCF/Bootstrap', 'WoltLab/WCF/Controller/Sitemap', 'WoltLab/WCF/Controller/Style/Changer', + 'WoltLab/WCF/Controller/Popover', 'WoltLab/WCF/Ui/User/Ignore' ], function( - Ajax, Bootstrap, ControllerSitemap, ControllerStyleChanger, - ControllerPopover, UiPageJumpToTop, UiUserIgnore + Ajax, Bootstrap, ControllerSitemap, ControllerStyleChanger, + ControllerPopover, UiUserIgnore ) { "use strict"; @@ -41,8 +41,6 @@ define( this._initUserPopover(); this._invokeBackgroundQueue(options.backgroundQueue.url, options.backgroundQueue.force); - new UiPageJumpToTop(); - UiUserIgnore.init(); }, -- 2.20.1