# Dynamically highlighting elements sharing common properties

I want to make a table of elements such that when the cursor is over a target element, all other elements of the table sharing some specified common property with the target are highlighted (let's say change color and font).

I'm however having some problems in finding a simple way to achieve this. Here is a sample code that should highlight all the numbers differing from the one under the cursor for an even number:

mouseHighLightPermutationProperties[originalTable_List, rule_Symbol] :=
With[{replacementRule = HoldForm[
t_Integer -> EventHandler[
t,
{"MouseMoved" :> (table = (originalTable /. rule[t]))}
]
]},
DynamicModule[{table = originalTable},
Dynamic[table /. ReleaseHold[replacementRule]]
]
]
highlightEvenTest[n_Integer] :=
target_Integer?(EvenQ[# - n] &) -> Style[target, Bold, Green]
mouseHighLightPermutationProperties[Range@20, highlightEvenTest]


This almost works: the substitution when mouseovering is done, but the output is this:

Using FullForm reveals that the Style is printed that way because what appears to be a simple number in the output is actually an EventHandler object. The problem is thus that in my code the Style is applied to the EventHandler, instead of the EventHandler being applied to the Style. I think I see why this happens, but I'm not sure how to fix it.

Besides, this function seems rather convoluted to me. Is there a simpler, possibly flexible, way to achieve this?

rulf[x_] := Function[{y}, If[EvenQ[x - y], Style[y, Red, Bold], y]]