Archive for December, 2014

Where’s your bloody Christmas card?

As regular readers may recall, I don’t send paper Xmas cards, because I’m a miserable bastard. With friends and family scattered all over the place, it seems daft to me to send bits of paper to landfills across the globe via plane or road. So instead, I bung the amount I’d spend on paper and postage to a charity where I think the dosh is better spent.

This year, there are two charities: Acorns Children’s Hospice, which is local to me but done in memoriam Rebecca Meyer, whose story moved so many of us this year, and Greenwich & Bexley Community Hospice, where my Dad, Jeff Lawson, was a volunteer counsellor for many years right up until his death in August.

Happy Consumerfest or whatever-you-celebrate. My plans are to get through the weirdness of the first Xmas when my Dad won’t be getting pissed on all my red wine; not put on any of the 6 kgs I lost this year; get healthy enough to go back to kickboxing; record more of my backlog of songs I’ve written; and continue whingeing to make the web better.

If you still feel the need for a bit of commemmorative paper, print this lovely photo of me in a festive mankini for your mantlepiece.

See you in 2015. xxx

Reading List

Wootarama! It’s my 100th reading list as the penultimate blogpost of this blog’s eleventh year. The Queen just sent me a telegram. You can send me Guinness or Laphroiag.

Reading List

Reading List ninety-nine. With a flake in it.

On Multiple Sclerosis, feeling ill, and heroics

(This is sort of a public service announcement as I get lots of visitors who come here from a search for “multiple sclerosis”.)

I’m a bit grumpy today, not just because I’m in bed with a temperature of 38.7, sweating and occasionally coughing so hard I eject alarmingly yellow blobs of what is presumably some gelatinous form of plutonium, but because I should be at the airport flying to Oslo (where my employers are headquartered) for a meet-up with my excellent team-mates and the notoriously Epicurean office Xmas party. But I’ve elected not to go.

“What’s that?”, you cry. “You – Bruce – who plays punk guitar, does kickboxing and wrestles poodles (and wins!) have turned into Shirley Temple!” you mock.

Here’s the reasoning, in the hope that if you are a merry new recruit to the world of MS (I’m a veteran of ’99), it’ll be some help to you.

When you’re newly diagnosed it’s quite normal to be in and out of your neurologists’s office so often that the staff greet you by first name and soon start darting into stock rooms or crouching behind desks as you approach. You’re new, you’re worried and every tiny twinge sets of your anxiety. Later on, particularly if your kind of MS is cyclical remitting-relapsing, you might breathe a sigh of relief and start to think ‘I won’t let this diagnosis change me!’ and potentially push yourself too far. It’s not a good idea to be an MS hero.

As you probably know if you have it, MS is a disease of the auto-immune system. In highly technical terms, think of an MS person’s immune system as being like a crowd of drunk Millwall FC fans waiting for the opposing fans to enter their stadium. When they see the opposition, they’ll beat them up. But once the opposition is defeated, they’ll very likely smash a few windows, beat up some police, their own friends, set fire to their neighbours’ cars and then turn on each other.

Getting even more scientific, there are no police or windows in your immune system, so it will attack your nerves instead, stripping their myelin sheaths which will never regenerate.

As I write this, my eyes hurt if I move them left, right, up or down. This isn’t much fun – you tend to turn your head instead of having to move your eyes which makes you look a bit like a robot in a sci-fi film. But when this happens to me it’s a warning signal. One of my first MS presentations was going effectively blind in my left eye because of Optic Neuritis, which is an inflammation of the optic nerve that makes your eyes painful and vision darkened. (Mine was dealt with by injecting anti-inflammatory goo just behind the eye, a procedure which was pretty low in chuckles.)

I also have an increase in what I call “fizzy fingers” (due to my incorrigible love of alliteration). This is when my fingertips feel numb or full of “pins and needles”. I always have this to some extent – it’s why I can’t play guitar properly any more – and, to my eternal regret, it’s my own fault. When I was eventually diagnosed (3 years after the optic neuritis) my hands were basically not obeying orders – my handwriting was a scrawl, I couldn’t do my own buttons up etc. But I heroically soldiered on before eventually being admitted to hospital and being put on 1000mg of steroids daily in the medical equivalent of tear-gassing the rioting Millwall fans and shutting your immune system down so it can’t do any more damage. But the damage already done can’t be reversed.

So these days, when I get a little bit of a cold I soldier on. But when I start to get other more sinister signs, I give up and take to my bed. While I know that my team mates would love to sit in a room with me and my pathogens, inhaling the gift of a Christmas fever to take to their loved ones, and I understand that the ladies of Oslo have spent many weeks putting up welcoming street decorations, I’m vegging out until the auto-immune Millwall fans go back to their mums’ houses. (From 15 years’ experience, a couple of days.)

It’s not worth being heroic when the risk is irreparable damage (and I have 2 dependant kids, too). Your MS will be different; your level of heroism may be different. Good luck and take care.

Reading List

Ooh,ooh, it’s the 98th Reading List (including last week’s Device Detection vs Responsive Web Design-themed list). Will I get to 100 before 2015?

Autumn

The smell of roasting dust heralds the fan heater’s first use of the autumn, like the smell of the crematorium we’re all another year closer to.

On the accessibility of web components. Again.

I enjoyed watching Dimitri Glazkov’s introduction to Web Components Easy composition and reuse with Web Components, given at the Chrome Developer Summit. It’s an excellently-constructed talk that builds on the use-cases that web components address to make a compelling argument for the technology.

At 11 min 55 seconds, after a slide reading “Make HTML useful”, Dimitri says

Custom elements is really neat. It basically says, “HTML it’s been a pleasure”.

There we are. Bye-bye HTML; you weren’t useful enough. Hello, brave new world of custom elements. Of course, this isn’t the full messaging; a 20 minute video can’t go into the nuances. But it’s what a lot of people are hearing.

Let’s straighten that out.

One of the advantages of oh-so-boring HTML was that certain elements carried default behaviours in browsers and assistive technology. Like, when you use this mark-up

<label for="form-name">What's yer name?<label>
<input id="form-name">

and you click on the label, the focus goes into the associated input. There’s no need for JavaScript, there’s no fancy stuff extra for a developer (except setting up the association with the for="" attribute), and there’s a significant usability and accessibility advantage for the end-user.

A recent HTML5 Rocks article by Addy Osmani and Alice Boxhall called Accessible Web Components begins with the words

Custom Elements present a fantastic opportunity for us to improve accessibility on the web.

Yes. Yes. Yes. (Thanks Addy and Alice!) It’s perfectly possible to make web components and custom elements accessible. Alice has an example which I’ve screenshotted in Opera (top) and Safari (bottom).

Opera and Safari screenshots

Note that in the Safari screenshot, the second column of sexy checkboxes don’t work at all – there is no checkbox. That’s because Safari doesn’t support web components. You’ll see the same in IE, or browsers without JavaScript.

Note that the first column does render in Safari, but it’s just normal checkboxes; they aren’t sexy web component-ised as they are in Opera. But – crucially – you can still interact with them, as they’re web components progressively enhancing silly old “useless” HTML. It works like this:

<input type="checkbox" is="io-checkbox">

Simple, huh? You have a silly old useless HTML element, and a new attribute that says “this is extended via web components into a special element I’m calling ‘io-checkbox'”. The web component inherits all the silly old useless behaviour like associating labels with form fields, activation with keyboard for free.

Compare with the sexy but not progressively-enhanced way that doesn’t work in older browsers (the second column):

<io-custom-checkbox tabindex="0" role="checkbox"></io-custom-checkbox>

There’s a super-whizzo-fabbo-megalicious UltraShiny custom element there, which has no graceful degradation. It needs a tabindex and a role there because who wants that silly old useless HTML behaviour? Not us! We’re post-HTML. Yay!

Snarking aside, why do so few people talk about extending existing HTML elements with web components? Why’s all the talk about brand new custom elements? I don’t know.

Of course, not every new element you’ll want to make can extend an existing HTML element. In this case, you can still make your custom element accessible. Just because you’re in the super-whizzo-fabbo-megalicious UltraShiny world of web components, you can – and should – still add ARIA information to make your code accessible. Just because you’re hiding nasty code behind the Shadow DOM, it doesn’t mean that you can brush proper coding under the web components carpet.

You’d hope that those who are assiduously pushing components into the platform would ensure that their demos did this – after all, those demos are meant to be studied, copied and adapted by developers, right?

Wrong. Take a look at Polymer gmail, a “Polymer version of New Gmail app”. Patrick Lauke points out

Google has expertise in-house to create functional, beautiful, web-component stuff that is also accessible. It would be great if high-profile demos like these would actually take advantage of those resources to create things that work not just for sighted mouse/touchscreen users…

To which he received the reply

There’s plenty that can be done in the convenience of unlimited time and resources. If you’d like to help, please submit a PR.

A big demo of a Google cutting-edge technology, made by Google, and there’s no resources simply to make it accessible.

At Paris Web, Karl Groves and I talked about Web Components – the right way, we talked of extending existing elements, adding ARIA and suggested that web accessibility advocates actively fix issues on Open-Source projects. But I meant fixing small projects that you’re using in your own sites – like the WordPress Live Comment Preview plugin, which I tweaked, thereby making 44,837 sites accessible.

I wasn’t talking about fixing demos by a company with a $362.48 Billion market capitalisation. As Patrick Lauke so eloquently puts it:

My resources are currently a bit more stretched than Google’s…but I’ll put it on my to-do list 😉

I’m a fan of web components. But I’m increasingly worried about the messaging surrounding them.