p标签增加一个 tabindex="-1"
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>BFW NEW PAGE</title>
<style>
p{
display: block;
}
p:focus + div{
background: red;
}
</style>
</head>
<body>
<p tabindex="-1">测试</p>
<div >
测试
</div>
</body>
</html>
网友回复