xing/wysihtml5 — pull request #90 by cs (2012-05-30 11:38:47+00:00)
Title: Allow Digits in HTML class names in commands

Changed commands:

* fontSize
* fontColor
* justifyCenter
* justifyLeft
* justifyRight

All these commands are adding classes to some kind of HTML element (such as ``). These classes are supposed to be disjunctive, i.e. there should never be an HTML element with two classes from the same group.

To achieve this behavior, each of the above commands uses an regular expression to remove all the previously added classes before adding the new one.

There's no restriction to prevent class names containing digits from being added. However, the regular expression to remove old class names doesn't match class names containing digits. All in all, we end up with HTML elements with multiple classes from the same command.