Newsletter
  • Get a newsletter digest every Friday:
Contact

Send me feedback, tips, bug reports, and anything else:

About me and the blog

My name is Marcin Wichary (he/him). I’ve worked as a UX designer, typographer, front-end person, and manager at Google, Medium, and Figma. I’ve also written a book about keyboards and typing, gave talks, and published essays about design, typography, and technology.

Unsung is my blog about software craft and quality.

More info about Unsung

Send me feedback, tips, bug reports, and anything else:

More info about Unsung

Responsive text and code

Many years ago, I put together a quick proposal of what I called “responsive text” for social proof:

I think you get the idea – instead of dumb truncation, the underlying code could prepare a few strings conveying the information with different levels of specificity, and then the UI could choose the longest one that could still fit.

This idea can apply in a few places. Here, in Figma, one of the menu items switches to a more “compact” string that uses four-letter abbreviations and skips “weight” altogether – but only because there isn’t room for a verbose treatment. You can also compare it with the original, naïve truncation:

Recently, I spotted Jake Archibald, developer working on Firefox, propose something in a similar vein – responsive code:

I think this is a lot more clever and a lot more important. Mobile phones are everywhere. Wrapping code like regular text without understanding it makes it basically impenetrable, but preserving long lines and introducing horizontal scrolling is also frustrating – just in a different way, forcing you to hold more stuff in your head:

I can see Archibald’s solution be very helpful here if used well – and not just on mobile – and perhaps could inspire other kinds of solutions for similar problems (have you ever tried to read any table on Wikipedia on your phone?).