added js option for content height fixed

pull/2120/head
REJack 2019-06-06 14:28:59 +02:00
parent 96dc774be3
commit cc8a2d7e51
No known key found for this signature in database
GPG Key ID: 9F3976CC630CC888
5 changed files with 16 additions and 8 deletions

View File

@ -33,11 +33,12 @@ const Layout = (($) => {
}
const ClassName = {
HOLD : 'hold-transition',
SIDEBAR : 'main-sidebar',
LAYOUT_FIXED: 'layout-fixed',
NAVBAR_FIXED: 'layout-navbar-fixed',
FOOTER_FIXED: 'layout-footer-fixed',
HOLD : 'hold-transition',
SIDEBAR : 'main-sidebar',
CONTENT_FIXED: 'content-fixed',
LAYOUT_FIXED : 'layout-fixed',
NAVBAR_FIXED : 'layout-navbar-fixed',
FOOTER_FIXED : 'layout-footer-fixed',
}
const Default = {
@ -109,6 +110,9 @@ const Layout = (($) => {
if ($('body').hasClass(ClassName.FOOTER_FIXED)) {
$(Selector.CONTENT).css('margin-bottom', heights.footer)
}
if ($('body').hasClass(ClassName.CONTENT_FIXED)) {
$(Selector.CONTENT).css('height', $(Selector.CONTENT).css('min-height'))
}
}
// Private

4
dist/js/adminlte.js vendored
View File

@ -202,6 +202,7 @@ var Layout = function ($) {
var ClassName = {
HOLD: 'hold-transition',
SIDEBAR: 'main-sidebar',
CONTENT_FIXED: 'content-fixed',
LAYOUT_FIXED: 'layout-fixed',
NAVBAR_FIXED: 'layout-navbar-fixed',
FOOTER_FIXED: 'layout-footer-fixed'
@ -277,6 +278,9 @@ var Layout = function ($) {
if ($('body').hasClass(ClassName.FOOTER_FIXED)) {
$(Selector.CONTENT).css('margin-bottom', heights.footer);
}
if ($('body').hasClass(ClassName.CONTENT_FIXED)) {
$(Selector.CONTENT).css('height', $(Selector.CONTENT).css('min-height'));
}
};
// Private

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long