Support srcset and multiple attributes on the same element

Had to change the HTML handler significantly so that it can handle multiple attributes in a single element.

Closes #9.