@@ -32,6 +32,7 @@ import {
32
32
Box ,
33
33
createStyles ,
34
34
Theme ,
35
+ Typography ,
35
36
withStyles
36
37
} from '@material-ui/core'
37
38
import { withRouter } from 'react-router'
@@ -75,7 +76,11 @@ const useStyles = (theme: Theme): StyleRules => createStyles(
75
76
[ theme . breakpoints . up ( 'sm' ) ] : {
76
77
width : theme . spacing ( 9 )
77
78
}
79
+ } ,
80
+ queueBackground : {
81
+ backgroundColor : theme . palette . secondary . main
78
82
}
83
+
79
84
} )
80
85
81
86
function ListItemLink ( props ) : JSX . Element {
@@ -87,6 +92,7 @@ interface NavBarProps extends RouteComponentProps {
87
92
maxSession : number
88
93
sessionCount : number
89
94
nodeCount : number
95
+ sessionQueueSize : number
90
96
classes : any
91
97
}
92
98
@@ -101,6 +107,7 @@ class NavBar extends React.Component<NavBarProps, {}> {
101
107
maxSession,
102
108
sessionCount,
103
109
nodeCount,
110
+ sessionQueueSize,
104
111
classes,
105
112
location
106
113
} = this . props
@@ -134,24 +141,36 @@ class NavBar extends React.Component<NavBarProps, {}> {
134
141
</ ListItemLink >
135
142
< ListItemLink href = '#sessions' >
136
143
< ListItemIcon >
137
- < AssessmentIcon />
144
+ < AssessmentIcon />
138
145
</ ListItemIcon >
139
- < ListItemText primary = 'Sessions' />
146
+ < ListItemText primary = 'Sessions' />
140
147
</ ListItemLink >
141
148
< ListItemLink href = '#help' >
142
149
< ListItemIcon >
143
- < HelpIcon />
150
+ < HelpIcon />
144
151
</ ListItemIcon >
145
- < ListItemText primary = 'Help' />
152
+ < ListItemText primary = 'Help' />
146
153
</ ListItemLink >
147
154
</ div >
148
155
</ List >
149
- < Box flexGrow = { 1 } />
156
+ < Box flexGrow = { 1 } />
157
+ { open && (
158
+ < Box p = { 3 } m = { 1 } className = { classes . queueBackground } >
159
+ < Typography
160
+ align = 'center'
161
+ gutterBottom
162
+ variant = 'h4'
163
+ >
164
+ Queue size: { sessionQueueSize }
165
+ </ Typography >
166
+ </ Box >
167
+ ) }
150
168
{ showOverallConcurrency && open && (
151
169
< OverallConcurrency
152
170
sessionCount = { sessionCount }
153
171
maxSession = { maxSession }
154
- /> ) }
172
+ />
173
+ ) }
155
174
</ Drawer >
156
175
)
157
176
}
0 commit comments