import { Box, createStyles, useMantineTheme } from '@mantine/core'; import { useMouse } from '@mantine/hooks'; import { PolkaElement } from './PolkaElement'; export const FloatingBackground = () => { const { classes } = useStyles(); return ( ); }; const MouseBackdrop = () => { const { x, y } = useMouse(); const radius = 40; return ( { const dropColor = theme.colorScheme === 'dark' ? theme.fn.rgba(theme.colors.red[8], 0.05) : theme.fn.rgba(theme.colors.red[2], 0.4); const boxShadow = `0px 0px ${radius}px ${radius}px ${dropColor}`; return { width: 50, height: 50, borderRadius: '5rem', boxShadow: boxShadow, backgroundColor: dropColor, }; }} top={y - 25} left={x - 25} pos="absolute" > ); }; const useStyles = createStyles(() => ({ noOverflow: { overflow: 'hidden', }, }));