JSFiddle - React, Tailwind, and code Playground
by infralabs
HTML
<!-- Adjacent sibling selectors (former_element + target_element) example with use of :focus and :hover pseudo-classes to get effect on element that follows the former specified element -->
<div>
<input type="text" placeholder="test" id="test">
<label for="test">test</label>
</div>
<div>
<a href="javascript:void(0);">test</a>
<span>test</span>
</div>
CSS
div {
padding:0 0 20px;
}
input:focus + label {
color:#f00;
}
a:hover + span {
color:#f00;
}