2023-02-10 12:26:57 +01:00
|
|
|
import { ButtonGroup, Button, Flexbox } from 'react-basics';
|
2020-10-13 01:31:51 +02:00
|
|
|
|
2023-04-21 17:00:42 +02:00
|
|
|
export function FilterButtons({ items, selectedKey, onSelect }) {
|
2020-10-13 01:31:51 +02:00
|
|
|
return (
|
2023-02-10 12:26:57 +01:00
|
|
|
<Flexbox justifyContent="center">
|
2023-02-11 08:21:50 +01:00
|
|
|
<ButtonGroup items={items} selectedKey={selectedKey} onSelect={onSelect}>
|
2023-02-10 12:26:57 +01:00
|
|
|
{({ key, label }) => <Button key={key}>{label}</Button>}
|
|
|
|
</ButtonGroup>
|
|
|
|
</Flexbox>
|
2020-10-13 01:31:51 +02:00
|
|
|
);
|
|
|
|
}
|
2023-04-21 17:00:42 +02:00
|
|
|
|
|
|
|
export default FilterButtons;
|