2022-05-06 10:46:42 -07:00
|
|
|
import React from 'react';
|
|
|
|
import ReactToggle, { ToggleProps } from 'react-toggle';
|
|
|
|
|
2022-05-06 12:55:16 -07:00
|
|
|
/** A glorified checkbox. Wrapper around react-toggle. */
|
2022-05-06 10:46:42 -07:00
|
|
|
const Toggle: React.FC<ToggleProps> = ({ icons = false, ...rest }) => {
|
|
|
|
return (
|
|
|
|
<ReactToggle
|
|
|
|
icons={icons}
|
|
|
|
{...rest}
|
|
|
|
/>
|
|
|
|
);
|
|
|
|
};
|
|
|
|
|
|
|
|
export default Toggle;
|