Using closest() to return the correct DOM element

Comment icon Small gray icon for comments Comments

I was recently working with a vertical navigation component and ran into a hiccup where the JavaScript code wouldn’t fire depending on where I clicked on the menu item link. I did some digging and thought I’d share a little about what I discovered and how I was able to...

Read the full post

Phone number links and accessibility

Comment icon Small gray icon for comments Comments

One design challenge that used to stump me was making phone numbers accessible in the browser while still being functional. The WCAG 2.0 guidelines state: Link underlines or some other non-color visual distinction are required (when the links are discernible to those with color vision). Let’s consider for a moment...

Read the full post

Nope, nope, nope, line-height is unitless

Comment icon Small gray icon for comments Comments

Here’s a bit of CSS trivia that, at least on the surface, seems straightforward but that I see misused repeatedly. Let’s start with an oldie-but-goodie CSS interview question: You want the text on your website to be double-spaced by default. Which of the following line-height values is the best way...

Read the full post