|
@@ -63,7 +63,7 @@ export class LayoutTreeCrawler {
|
63
|
63
|
this._normalizeButtons(passedOptions.topBar.leftButtons, (buttons, style) => {
|
64
|
64
|
passedOptions.topBar.leftButtons = buttons;
|
65
|
65
|
|
66
|
|
- if (staticOptions.topBar) {
|
|
66
|
+ if (staticOptions.topBar && buttons) {
|
67
|
67
|
this._applyButtonsStyle(staticOptions.topBar.leftButtons, style);
|
68
|
68
|
}
|
69
|
69
|
});
|
|
@@ -71,7 +71,7 @@ export class LayoutTreeCrawler {
|
71
|
71
|
this._normalizeButtons(passedOptions.topBar.rightButtons, (buttons, style) => {
|
72
|
72
|
passedOptions.topBar.rightButtons = buttons;
|
73
|
73
|
|
74
|
|
- if (staticOptions.topBar) {
|
|
74
|
+ if (staticOptions.topBar && buttons) {
|
75
|
75
|
this._applyButtonsStyle(staticOptions.topBar.rightButtons, style);
|
76
|
76
|
}
|
77
|
77
|
});
|
|
@@ -87,11 +87,9 @@ export class LayoutTreeCrawler {
|
87
|
87
|
}
|
88
|
88
|
|
89
|
89
|
_applyButtonsStyle(buttons, style) {
|
90
|
|
- if (buttons) {
|
91
|
|
- buttons.forEach((button) => {
|
92
|
|
- _.merge(button, style);
|
93
|
|
- });
|
94
|
|
- }
|
|
90
|
+ buttons.forEach((button) => {
|
|
91
|
+ _.merge(button, style);
|
|
92
|
+ });
|
95
|
93
|
}
|
96
|
94
|
|
97
|
95
|
_assertKnownLayoutType(type) {
|