const [ishover, sethover] = useState(false)
function MouseOver() {
sethover(true)
}
function MouseOut() {
sethover(false)
}
<div className={`comment ${ishover ? 'highlighted' : ''}`}>
родитель
</div>
<div onMouseEnter={() => MouseOver(comment.id)} onMouseLeave={() => MouseOut(comment.id)}>
дочерний
</div>
const [isShow, setShow] = useState(false)