Hacker News new | ask | show | jobs
by chrisfarms 4487 days ago
I find there is often a need for a relative inverse relationship between screen width and the size of an element.

The most obvious of which is buttons. As screen width decreases the probability of the user being on a touch device increases, and you tend to want relatively larger fat-finger-friendly buttons at smaller screen sizes.

I guess calc() with rem sizing could work well here. But calc() always feels like cheating to me.

1 comments

There's no law against big buttons on big screens, you know. Doing things big may go against the grain (the typical desktop convention is to squeeze as much stuff in as possible), but it very frequently ends up with surprisingly pleasant results. Also Fitt's Law comes into play—big button, bigger target to aim for.