使用:悬停选择器并更改img opacity:
.child:hover img { opacity: 0.8; }
或者如果你想改变while子div的不透明度,那么:
.parent:hover .child { opacity: 0.8; }