Safari display:contents bug
I just came across an interesting bug. In Safari 11.0.2 on desktop and on the phone, display:contents falls back to display:inline instead of being ignored. I created a Pen to demonstrate: See the Pen display contents by Jonathan Snook (@snookca) on CodePen. I also was able to test on iOS 10.3.3 and it also seemed to exhibit this behaviour. iOS 9 didn't....
The Open Graph and Sharing Tags
Awhile back, I decided I wanted to have those fancy cards show up when I or anyone else posted a link to my blog. Twitter card with small image on the left To do this, you need to add a few meta tags to your pages. <meta property="og:url" content="https://snook.ca/archives/html_and_css/css-concerns"> <meta property="og:title" content=&qu...
Not So Reflective
It’s the new year. Not all that shocking to you, I’m sure, unless you’ve been busy for the last few weeks. But here we are. Many are posting their retrospectives of how their year went. Or they’re posting their theme word for the year or their resolutions or their goals. I’ve tried resolutions and themes. A year is a long time to stick to such a thing and—inevitably—things happen....
Curation
Personal curation is one way in which we create good experiences. We choose how to use our time, choose the friends we have, and choose the things we collect. Feeling dispassionate about my experiences on Twitter, I decided to spend some time curating it. Like an overgrown garden, I needed to cut back the branches and pull out some weeds. I mute keywords. I mute some people. I turn off retwe...
Calendar with CSS Grid
Laying out events on a calendar can be somewhat tricky. Many years ago, I had a client project where I needed to do a calendar similar to Google Calendar. I ended up using bitwise operators to figure out if there was room to put an event on a particular line. If there’s no room, it placed the event on the next available line. There’s a lot of looping involved just to place an event on th...
Quiet Time
Unbelievably—at least, to me—I’ve been speaking at conferences for over 11 years now. I’m finding it difficult not to be self-congratulatory in recognizing that I’ve been doing it so long. I still remember my first talk at Webvisions. I had a full slide deck of JavaScript tidbits to cover. I don’t think I looked up from my computer once as I delivered my talk. I was nervous and...

