Skip to content

Commit

Permalink
OpenConceptLab/ocl_issues#648 | Retired Control | added tooltip and m…
Browse files Browse the repository at this point in the history
…ade it outlined
  • Loading branch information
snyaggarwal committed Mar 16, 2021
1 parent 562fbf9 commit 729c0bc
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions src/components/common/IncludeRetiredFilterChip.jsx
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
import React from 'react';
import { Chip } from '@material-ui/core';
import { Chip, Tooltip } from '@material-ui/core';

const IncludeRetiredFilterChip = ({ size, applied, onClick }) => {
const label = applied ? 'Exclude Retired' : 'Include Retired';
const color = applied ? 'primary' : 'secondary';
return (
<Chip
label={ label }
variant={applied ? 'default' : 'outlined'}
clickable
color={ color }
size={ size || 'medium' }
onClick={ onClick }
/>
<Tooltip title={applied ? 'Exclude retired results' : 'Include retried results'}>
<Chip
label={ label }
variant='outlined'
clickable
color={ color }
size={ size || 'medium' }
onClick={ onClick }
/>
</Tooltip>
);
}

Expand Down

0 comments on commit 729c0bc

Please sign in to comment.