ndreckshage/roughdraft.js — pull request #19 by renoirb (2014-07-28 18:05:29+00:00)
Title: Improving sequencer, adding SVG image generator

Here is the promised patch.

What’s new:
1. Refactored sequencer so it change classnames during draft-repeat.

Problem with original classname sequencer is that it’s searching the whole DOM and create sequences. This operation can become intensive; this is why it’s disabled by default.

Instead, how about we only support the class name sequencer to be changed for loops that are already managed in `data-draft-repeat="n"`. Since we are already looping to clone nodes, we could check if it has the `alfa` trigger in a `class` attribute and, if enabled, replace the cloned node `alfa` className the next name it’s at.

In other words, my suggestion is to support `class="whatever-alfa"` to be sequenced ONLY when that member ALSO has `data-draft-repeat="n"` and make the feature enabled by default.

2. Added SVG image generator

Added a new "photoAlbum", to give auto-generated SVG image through `data-uri`. It’s also suggested to become the default.