@@ -175,9 +175,9 @@ class MainSideBar extends React.Component<{}, {}> {
175175
176176 getSessions ( ) {
177177 if ( ! GlobalModel . sessionListLoaded . get ( ) ) return < div className = "item" > loading ...</ div > ;
178- let sessionList : Session [ ] = [ ] ;
179- let activeSessionId = GlobalModel . activeSessionId . get ( ) ;
180- for ( let session of GlobalModel . sessionList ) {
178+ const sessionList : Session [ ] = [ ] ;
179+ const activeSessionId = GlobalModel . activeSessionId . get ( ) ;
180+ for ( const session of GlobalModel . sessionList ) {
181181 if ( ! session . archived . get ( ) || session . sessionId == activeSessionId ) {
182182 sessionList . push ( session ) ;
183183 }
@@ -208,8 +208,8 @@ class MainSideBar extends React.Component<{}, {}> {
208208 }
209209
210210 render ( ) {
211- let isCollapsed = this . collapsed . get ( ) ;
212- let clientData = GlobalModel . clientData . get ( ) ;
211+ const isCollapsed = this . collapsed . get ( ) ;
212+ const clientData = GlobalModel . clientData . get ( ) ;
213213 let needsUpdate = false ;
214214 if ( ! clientData ?. clientopts . noreleasecheck && ! isBlank ( clientData ?. releaseinfo ?. latestversion ) ) {
215215 needsUpdate = compareLoose ( VERSION , clientData . releaseinfo . latestversion ) < 0 ;
@@ -237,20 +237,23 @@ class MainSideBar extends React.Component<{}, {}> {
237237 < div className = "separator" />
238238 < div className = "top" >
239239 < SideBarItem
240+ key = "history"
240241 frontIcon = { < i className = "fa-sharp fa-regular fa-clock-rotate-left icon" /> }
241242 contents = "History"
242243 endIcons = { [ < HotKeyIcon key = "hotkey" hotkey = "H" /> ] }
243244 onClick = { this . handleHistoryClick }
244245 />
245246 { /* <SideBarItem className="hoverEffect unselectable" frontIcon={<FavoritesIcon className="icon" />} contents="Favorites" endIcon={<span className="hotkey">⌘B</span>} onClick={this.handleBookmarksClick}/> */ }
246247 < SideBarItem
248+ key = "connections"
247249 frontIcon = { < i className = "fa-sharp fa-regular fa-globe icon " /> }
248250 contents = "Connections"
249251 onClick = { this . handleConnectionsClick }
250252 />
251253 </ div >
252254 < div className = "separator" />
253255 < SideBarItem
256+ key = "workspaces"
254257 className = "workspaces"
255258 frontIcon = { < WorkspacesIcon className = "icon" /> }
256259 contents = "Workspaces"
@@ -268,6 +271,7 @@ class MainSideBar extends React.Component<{}, {}> {
268271 < div className = "bottom" >
269272 < If condition = { needsUpdate } >
270273 < SideBarItem
274+ key = "update-available"
271275 className = "updateBanner"
272276 frontIcon = { < i className = "fa-sharp fa-regular fa-circle-up icon" /> }
273277 contents = "Update Available"
@@ -276,23 +280,27 @@ class MainSideBar extends React.Component<{}, {}> {
276280 </ If >
277281 < If condition = { GlobalModel . isDev } >
278282 < SideBarItem
283+ key = "apps"
279284 frontIcon = { < AppsIcon className = "icon" /> }
280285 contents = "Apps"
281286 onClick = { this . handlePluginsClick }
282287 endIcons = { [ < HotKeyIcon key = "hotkey" hotkey = "A" /> ] }
283288 />
284289 </ If >
285290 < SideBarItem
291+ key = "settings"
286292 frontIcon = { < SettingsIcon className = "icon" /> }
287293 contents = "Settings"
288294 onClick = { this . handleSettingsClick }
289295 />
290296 < SideBarItem
297+ key = "documentation"
291298 frontIcon = { < i className = "fa-sharp fa-regular fa-circle-question icon" /> }
292299 contents = "Documentation"
293300 onClick = { ( ) => openLink ( "https://docs.waveterm.dev" ) }
294301 />
295302 < SideBarItem
303+ key = "discord"
296304 frontIcon = { < i className = "fa-brands fa-discord icon" /> }
297305 contents = "Discord"
298306 onClick = { ( ) => openLink ( "https://discord.gg/XfvZ334gwU" ) }
0 commit comments