I have a unique challenge at hand:
<table>
<tr>
<td class="order-delivered"><i>order</i><br/><i>delivered</i><br/>
<a class="check-mark">✔</a>
</td>
<td class="prep-pizza"><i>prep</i><br/><i>pizza</i><br/>
<a class="check-mark">✔</a>
</td>
<td class="bake-pizza"><i>bake</i><br/><i>pizza</i><br/>
<a class="check-mark">✔</a>
</td>
<td class="out-for-deliver"><i>out for</i><br/><i>delivery</i><br/>
<a class="check-mark">✔</a>
</td>
</tr>
</table>
My goal is to create an interactive effect when hovering over certain classes. Specifically, when I hover over the prep-pizza
class, it should change the text color of the a
elements within both the prep-pizza
and order-delivered
classes.
Similarly, hovering over the bake-pizza
class should change the text color of the a
elements in the prep-pizza
, order-delivered
, and bake-pizza
classes simultaneously.
Lastly, hovering over the out-for-deliver
class should adjust the text color of all a
elements within each td
.
It's worth noting that only the check mark symbol should change color, not any other characters.
How can I achieve this dynamic effect where hovering targets multiple different class elements?
UPDATE:
The color change should be contextually based on the location of the current hover action.
For example, hovering solely over the order-delivered
class should only affect the a
element within that specific class.