Skip to content

Commit

Permalink
Merge pull request #395 from layer5io/394-filter
Browse files Browse the repository at this point in the history
fix(components): update filter component
  • Loading branch information
nebula-aac authored Dec 4, 2023
2 parents 0e51e25 + e087dbf commit 5bc9d9e
Showing 1 changed file with 7 additions and 22 deletions.
29 changes: 7 additions & 22 deletions packages/components/src/custom/UniversalFilter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,12 @@ import { SelectChangeEvent } from '@mui/material/Select';
import React from 'react';
import { Button } from '../base/Button';
import { ClickAwayListener } from '../base/ClickAwayListener';
import { IconButton } from '../base/IconButton';
import { InputLabel } from '../base/InputLabel';
import { MenuItem } from '../base/MenuItem';
import { Paper } from '../base/Paper';
import { Popper } from '../base/Popper';
import { Select } from '../base/Select';
import { Tooltip } from '../base/Tooltip';
import PopperListener from './PopperListener';
import TooltipIcon from './TooltipIcon';

export interface FilterColumn {
name: string;
Expand Down Expand Up @@ -62,23 +61,9 @@ function UniversalFilter({
};

return (
<div>
<Tooltip title="Filter" arrow>
<IconButton
onClick={handleClick}
sx={{
'&:hover': {
'& svg': {
fill: '#00d3a9'
}
}
}}
disableRipple
>
<FilterIcon fill="#3c494f" />
</IconButton>
</Tooltip>
<Popper
<React.Fragment>
<TooltipIcon title="Close" onClick={handleClick} icon={<FilterIcon fill="#3c494f" />} arrow />
<PopperListener
id={id}
open={open}
anchorEl={anchorEl}
Expand Down Expand Up @@ -154,8 +139,8 @@ function UniversalFilter({
</Paper>
</ClickAwayListener>
</div>
</Popper>
</div>
</PopperListener>
</React.Fragment>
);
}
export default UniversalFilter;

0 comments on commit 5bc9d9e

Please sign in to comment.