(props)
| 78 | ) |
| 79 | |
| 80 | function NavBarBottom (props): JSX.Element { |
| 81 | const { |
| 82 | sessionQueueSize, |
| 83 | sessionCount, |
| 84 | maxSession, |
| 85 | nodeCount |
| 86 | } = props |
| 87 | const location = useLocation() |
| 88 | // Not showing the overall status when the user is on the Overview |
| 89 | // page and there is only one node, because polling is not happening |
| 90 | // at the same time, and it could be confusing for the user. So, |
| 91 | // displaying it when there is more than one node, or when the user is |
| 92 | // on a different page and there is at least one node registered. |
| 93 | const showOverallConcurrency = |
| 94 | nodeCount > 1 || (location.pathname !== '/' && nodeCount > 0) |
| 95 | |
| 96 | return ( |
| 97 | <div> |
| 98 | <Box p={3} m={1}> |
| 99 | <Typography |
| 100 | align='center' |
| 101 | gutterBottom |
| 102 | variant='h4' |
| 103 | > |
| 104 | Queue size: {sessionQueueSize} |
| 105 | </Typography> |
| 106 | </Box> |
| 107 | {showOverallConcurrency && ( |
| 108 | <OverallConcurrency |
| 109 | sessionCount={sessionCount} |
| 110 | maxSession={maxSession} |
| 111 | /> |
| 112 | )} |
| 113 | </div> |
| 114 | ) |
| 115 | } |
| 116 | |
| 117 | function NavBar (props) { |
| 118 | const { |
nothing calls this directly
no outgoing calls
no test coverage detected