@@ -213,31 +213,45 @@ export default function IconBar(): JSX.Element {
213213 aria-label = 'Aggregation window'
214214 sx = { { width : '100%' , gap : 3 } }
215215 >
216- < ToggleButton
217- value = { AggregationWindow . Total }
218- selected = { aggregationWindow === AggregationWindow . Total }
219- onClick = { ( ) => dispatch ( setAggregationWindow ( AggregationWindow . Total ) ) }
220- sx = { { width : '100%' } }
221- >
222- { t ( 'icon-bar.display-settings.total' ) }
223- </ ToggleButton >
216+ < Tooltip title = { t ( 'icon-bar.display-settings.time-period-total-tooltip' ) } arrow placement = 'bottom-start' >
217+ < ToggleButton
218+ value = { AggregationWindow . Total }
219+ selected = { aggregationWindow === AggregationWindow . Total }
220+ onClick = { ( ) => dispatch ( setAggregationWindow ( AggregationWindow . Total ) ) }
221+ sx = { { width : '100%' } }
222+ >
223+ { t ( 'icon-bar.display-settings.total' ) }
224+ </ ToggleButton >
225+ </ Tooltip >
224226 < Divider orientation = 'vertical' flexItem />
225- < ToggleButton
226- value = { AggregationWindow . OneDay }
227- selected = { aggregationWindow === AggregationWindow . OneDay }
228- onClick = { ( ) => dispatch ( setAggregationWindow ( AggregationWindow . OneDay ) ) }
229- sx = { { width : '100%' } }
227+ < Tooltip
228+ title = { t ( 'icon-bar.display-settings.time-period-one-day-tooltip' ) }
229+ arrow
230+ placement = 'bottom-start'
230231 >
231- { t ( 'icon-bar.display-settings.one-day' ) }
232- </ ToggleButton >
233- < ToggleButton
234- value = { AggregationWindow . SevenDays }
235- selected = { aggregationWindow === AggregationWindow . SevenDays }
236- onClick = { ( ) => dispatch ( setAggregationWindow ( AggregationWindow . SevenDays ) ) }
237- sx = { { width : '100%' } }
232+ < ToggleButton
233+ value = { AggregationWindow . OneDay }
234+ selected = { aggregationWindow === AggregationWindow . OneDay }
235+ onClick = { ( ) => dispatch ( setAggregationWindow ( AggregationWindow . OneDay ) ) }
236+ sx = { { width : '100%' } }
237+ >
238+ { t ( 'icon-bar.display-settings.one-day' ) }
239+ </ ToggleButton >
240+ </ Tooltip >
241+ < Tooltip
242+ title = { t ( 'icon-bar.display-settings.time-period-seven-days-tooltip' ) }
243+ arrow
244+ placement = 'bottom-start'
238245 >
239- { t ( 'icon-bar.display-settings.seven-days' ) }
240- </ ToggleButton >
246+ < ToggleButton
247+ value = { AggregationWindow . SevenDays }
248+ selected = { aggregationWindow === AggregationWindow . SevenDays }
249+ onClick = { ( ) => dispatch ( setAggregationWindow ( AggregationWindow . SevenDays ) ) }
250+ sx = { { width : '100%' } }
251+ >
252+ { t ( 'icon-bar.display-settings.seven-days' ) }
253+ </ ToggleButton >
254+ </ Tooltip >
241255 </ StyledToggleButtonGroup >
242256 </ Box >
243257
@@ -261,22 +275,26 @@ export default function IconBar(): JSX.Element {
261275 aria-label = 'Aggregation window'
262276 sx = { { width : '100%' , gap : 3 } }
263277 >
264- < ToggleButton
265- value = 'relative-numbers'
266- selected = { relativeNumbers }
267- onClick = { ( ) => dispatch ( toggleRelativeNumbers ( ) ) }
268- sx = { { width : '100%' } }
269- >
270- { t ( 'icon-bar.display-settings.relative' ) }
271- </ ToggleButton >
272- < ToggleButton
273- value = 'absolute-numbers'
274- selected = { ! relativeNumbers }
275- onClick = { ( ) => dispatch ( toggleRelativeNumbers ( ) ) }
276- sx = { { width : '100%' } }
277- >
278- { t ( 'icon-bar.display-settings.absolute' ) }
279- </ ToggleButton >
278+ < Tooltip title = { t ( 'icon-bar.display-settings.relative-tooltip' ) } arrow placement = 'bottom-start' >
279+ < ToggleButton
280+ value = 'relative-numbers'
281+ selected = { relativeNumbers }
282+ onClick = { ( ) => dispatch ( toggleRelativeNumbers ( ) ) }
283+ sx = { { width : '100%' } }
284+ >
285+ { t ( 'icon-bar.display-settings.relative' ) }
286+ </ ToggleButton >
287+ </ Tooltip >
288+ < Tooltip title = { t ( 'icon-bar.display-settings.absolute-tooltip' ) } arrow placement = 'bottom-start' >
289+ < ToggleButton
290+ value = 'absolute-numbers'
291+ selected = { ! relativeNumbers }
292+ onClick = { ( ) => dispatch ( toggleRelativeNumbers ( ) ) }
293+ sx = { { width : '100%' } }
294+ >
295+ { t ( 'icon-bar.display-settings.absolute' ) }
296+ </ ToggleButton >
297+ </ Tooltip >
280298 </ StyledToggleButtonGroup >
281299 </ Box >
282300 </ Box >
0 commit comments