fgnass/sheet — pull request #1 by lydell (2013-09-12 20:33:46+00:00)
Title: Add more details to the source maps

- Previously, the whole rules were mapped to the beginning of the original
rule. Now, we go deeper: Map comment to comment, declaration to
declaration, selector to selector, etc.

- Added tests for the generated source maps.

- Improved documentation.

[Demo](http://sokra.github.io/source-map-visualization/#base64,QGNoYXJzZXQgInV0Zi04IjsKCi8qDQogKiBOdWxsYSB2aXRhZSBlbGl0IGxpYmVybywgYSBwaGFyZXRyYSBhdWd1ZS4NCiAqIEN1cmFiaXR1ciBibGFuZGl0IHRlbXB1cyBwb3J0dGl0b3IuDQogKi8KCmJvZHkgewogIC8qIEFub3RoZXIgY29tbWVudC4gKi8KICBiYWNrZ3JvdW5kOiAjZmZmCn0KCkBpbXBvcnQgJ2Zvby5jc3MnOwpAa2V5ZnJhbWVzIGZhZGVJbiB7CiAgZnJvbSB7CiAgICBvcGFjaXR5OiAwOwogICAgb3BhY2l0eTogMQogIH0KICAKICB0byB7CiAgICBvcGFjaXR5OiAxCiAgfQp9CgpAa2V5ZnJhbWVzIGZhZGVJbiB7CiAgZnJvbSB7CiAgICBvcGFjaXR5OiAwOwogICAgY29sb3I6ICMwMDAKICB9CiAgCiAgdG8gewogICAgb3BhY2l0eTogMQogIH0KfQoKQG1lZGlhIHNjcmVlbiwgcHJvamVjdGlvbiB7CiAgaHRtbCB7CiAgICBiYWNrZ3JvdW5kOiBibGFjazsKICAgIGNvbG9yOiB3aGl0ZQogIH0KICAKICBib2R5IHsKICAgIHdpZHRoOiA4MDBweDsKICAgIG1hcmdpbjogMCBhdXRvCiAgfQp9CgpAbWVkaWEgcHJpbnQgewogIGh0bWwgewogICAgYmFja2dyb3VuZDogI2ZmZjsKICAgIGNvbG9yOiAjMDAwCiAgfQogIAogIGJvZHksCiAgc2VjdGlvbiB7CiAgICBwYWRkaW5nOiAyZW0KICB9Cn0KCkBtZWRpYSBzY3JlZW4scHJvamVjdGlvbiB7CiAgaHRtbCB7CiAgICBiYWNrZ3JvdW5kOiB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