Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions packages/fiori/src/NavigationLayout.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,6 @@ const SCREEN_WIDTH_BREAKPOINT = 600;
template: NavigationLayoutTemplate,
})
class NavigationLayout extends UI5Element {
_defaultSideCollapsed = window.innerWidth < SCREEN_WIDTH_BREAKPOINT;

/**
* Specifies the navigation layout mode.
* @default "Auto"
Expand All @@ -65,7 +63,7 @@ class NavigationLayout extends UI5Element {
* @private
*/
@property({ type: Boolean })
sideCollapsed : boolean = this._defaultSideCollapsed;
sideCollapsed : boolean = window.innerWidth < SCREEN_WIDTH_BREAKPOINT;

/**
* @private
Expand Down Expand Up @@ -116,7 +114,7 @@ class NavigationLayout extends UI5Element {

calcSideCollapsed() {
if (this.mode === NavigationLayoutMode.Auto) {
this.sideCollapsed = this._defaultSideCollapsed;
this.sideCollapsed = window.innerWidth < SCREEN_WIDTH_BREAKPOINT;
} else {
this.sideCollapsed = this.mode === NavigationLayoutMode.Collapsed;
}
Expand Down
Loading