Skip to content

Commit e056bd9

Browse files
committed
feat: added tooltip
1 parent 905550d commit e056bd9

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

compose/neurosynth-frontend/src/components/Visualizer/NiiVueVisualizer.tsx

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import { Download, OpenInNew } from '@mui/icons-material';
1+
import { Download, HelpOutline, OpenInNew } from '@mui/icons-material';
22
import ImageIcon from '@mui/icons-material/Image';
3-
import { Box, Button, Checkbox, Link, Typography } from '@mui/material';
3+
import { Box, Button, Checkbox, Icon, Link, Tooltip, Typography } from '@mui/material';
44
import { Niivue, SHOW_RENDER } from '@niivue/niivue';
55
import { ChangeEvent, useCallback, useEffect, useRef, useState } from 'react';
66
import ThresholdSlider from './ThresholdSlider';
@@ -224,11 +224,24 @@ const NiiVueVisualizer: React.FC<{ file: string; filename: string; neurovaultLin
224224
onDebouncedThresholdChange={handleUpdateThreshold}
225225
/>
226226
</Box>
227-
<Box width="130px" display="flex" flexDirection="column">
227+
<Box width="140px" display="flex" flexDirection="column">
228228
<Box display="flex" justifyContent="space-between" alignItems="center">
229229
<Typography variant="caption" gutterBottom={false}>
230230
Soft Threshold
231231
</Typography>
232+
<Tooltip
233+
title={
234+
<Typography variant="caption">
235+
Checking this option will also highlight areas of activation below the current
236+
selected threshold
237+
</Typography>
238+
}
239+
placement="top"
240+
>
241+
<Icon fontSize="small">
242+
<HelpOutline fontSize="small" sx={{ color: 'muted.main' }} />
243+
</Icon>
244+
</Tooltip>
232245
<Checkbox sx={{ padding: 0 }} checked={softThreshold} onChange={handleToggleSoftThreshold} />
233246
</Box>
234247
<Box display="flex" justifyContent="space-between" alignItems="center">

0 commit comments

Comments
 (0)