mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-10 01:43:43 +00:00
22 lines
586 B
React
22 lines
586 B
React
import { IconButton } from '@chakra-ui/button';
|
|
import { Tooltip } from '@chakra-ui/tooltip';
|
|
import { FiTarget } from 'react-icons/fi';
|
|
|
|
export default function LockIconBtn(props) {
|
|
const { clickhandler, active, ref } = props;
|
|
return (
|
|
<Tooltip label='Lock cursor to current'>
|
|
<IconButton
|
|
ref={ref}
|
|
size={props.size || 'xs'}
|
|
icon={<FiTarget />}
|
|
colorScheme='pink'
|
|
color={'pink.300'}
|
|
variant={active ? 'solid' : 'outline'}
|
|
onClick={clickhandler}
|
|
_focus={{ boxShadow: 'none' }}
|
|
/>
|
|
</Tooltip>
|
|
);
|
|
}
|