Home / This developer's life / 4/14/2019, fitt's law UI exploration edit

 
Fitt's law states an obvious thing: the bigger the target, the easier it is to hit.
I did an exploration of that theme: what if an element becomes bigger when the mouse pointer gets closer to it?
It's rather simple:
  • hook mousemove event on document
  • in mouse move handler calculate a distance to the center of the element
  • set the font of the element: the smaller the distance, the bigger the font
 
Go to index of articles.

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:

Share on