File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -31,6 +31,7 @@ const CLASS_NAME_SIDEBAR_FOCUSED = 'sidebar-focused'
31
31
const CLASS_NAME_LAYOUT_FIXED = 'layout-fixed'
32
32
const CLASS_NAME_CONTROL_SIDEBAR_SLIDE_OPEN = 'control-sidebar-slide-open'
33
33
const CLASS_NAME_CONTROL_SIDEBAR_OPEN = 'control-sidebar-open'
34
+ const CLASS_NAME_LAYOUT_TOP_NAV = 'layout-top-nav'
34
35
35
36
const Default = {
36
37
scrollbarTheme : 'os-theme-light' ,
@@ -82,7 +83,11 @@ class Layout {
82
83
83
84
if ( offset !== false ) {
84
85
if ( max === heights . controlSidebar ) {
85
- $contentSelector . css ( this . _config . panelAutoHeightMode , ( max + offset ) )
86
+ if ( $body . hasClass ( CLASS_NAME_LAYOUT_TOP_NAV ) ) {
87
+ $contentSelector . css ( this . _config . panelAutoHeightMode , ( max + offset ) + heights . header + heights . footer )
88
+ } else {
89
+ $contentSelector . css ( this . _config . panelAutoHeightMode , ( max + offset ) )
90
+ }
86
91
} else if ( max === heights . window ) {
87
92
$contentSelector . css ( this . _config . panelAutoHeightMode , ( max + offset ) - heights . header - heights . footer )
88
93
} else {
@@ -164,6 +169,10 @@ class Layout {
164
169
this . fixLayoutHeight ( )
165
170
} )
166
171
172
+ $ ( document ) . ready ( ( ) => {
173
+ this . fixLayoutHeight ( )
174
+ } )
175
+
167
176
setTimeout ( ( ) => {
168
177
$ ( 'body.hold-transition' ) . removeClass ( 'hold-transition' )
169
178
} , 50 )
You can’t perform that action at this time.
0 commit comments