Is it possible to highlight a box when I drag a document over it? It should be highlighted only when
- you hover over the element
- you drag something
- when you drag-leave it shouldn't be highlighted anymore
I use React + Typescript, but any CSS Tipps would help.
Right now it looks something like this:
import { useDragging } from '../../../common/useDragging';
const useStyles = makeStyles(
theme => ({
root: {
'&.dragging, &:focus': {
outline: `4px solid ${theme.palette.primary.main}50`,
boxShadow: '0px 4px 12px rgba(131, 142, 158, 0.22)',
},
}
})
);