Skip to content

TagSpaces is an offline, open source, document manager with tagging support

optimizing rendering in vertical navi

Ilian Sapundshiev07163cd208fe
diff --git a/app/components/VerticalNavigation.js b/app/components/VerticalNavigation.js
index 8f7ee5f69..7549e2a33 100644
--- a/app/components/VerticalNavigation.js
+++ b/app/components/VerticalNavigation.js
@@ -548,31 +548,10 @@ class VerticalNavigation extends React.Component<Props, State> {
</div>
{this.state.isManagementPanelVisible && (
<div style={this.styles.panel}>
- <LocationManager
- style={{
- display: this.state.isLocationManagerVisible
- ? 'block'
- : 'none'
- }}
- />
- <TagLibrary
- togglePanel={this.togglePanel}
- style={{
- display: this.state.isTagLibraryVisible ? 'block' : 'none'
- }}
- />
- <Search
- style={{
- display: this.state.isSearchVisible ? 'block' : 'none'
- }}
- />
- <PerspectiveManager
- style={{
- display: this.state.isPerspectiveManagerVisible
- ? 'block'
- : 'none'
- }}
- />
+ { this.state.isLocationManagerVisible && <LocationManager /> }
+ { this.state.isTagLibraryVisible && <TagLibrary togglePanel={this.togglePanel} /> }
+ { this.state.isSearchVisible && <Search /> }
+ { this.state.isPerspectiveManagerVisible && <PerspectiveManager /> }
</div>
)}
</SplitPane>