{"_id":"littering","_rev":"10-e988a161af70a214b3d36ba435b0f705","name":"littering","description":"ender based library for littering text with span markup, based on Lettering.js","dist-tags":{"latest":"0.0.5"},"versions":{"0.0.1":{"name":"littering","description":"ender based library for littering text with span markup, based on Lettering.js","version":"0.0.1","homepage":"https://github.com/cjc/littering","authors":["Cameron Coley"],"repository":{"type":"git","url":"git://github.com/cjc/littering.git"},"main":"./littering.js","dependencies":{"qwery":"*","bonzo":"*"},"devDependencies":{},"_id":"littering@0.0.1","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.6","_nodeVersion":"v0.4.5","_defaultsLoaded":true,"dist":{"shasum":"7eea14356ab5f4b05a30b04ec2d089a178bb1167","tarball":"https://registry.npmjs.org/littering/-/littering-0.0.1.tgz","integrity":"sha512-dBSvZtH3cxayNGXOLXgj5oXvE1bA9g4OKwoe1prPrujK/Cr+2B/7Tq+Nk47kqW6avbL+bTLNB3TGq7RpSyZpiQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQC2xJGW93aIjiTP+CvHAjErUscfHZut4kLYL6Z86QYfrQIhAIT/4HL+w3iw7irFLtJ4tX9u6kAjtpqbkbLjuTeLvQV6"}]},"scripts":{}},"0.0.2":{"name":"littering","description":"ender based library for littering text with span markup, based on Lettering.js","version":"0.0.2","homepage":"https://github.com/cjc/littering","authors":["Cameron Coley"],"repository":{"type":"git","url":"git://github.com/cjc/littering.git"},"main":"./littering.js","dependencies":{"qwery":"*","bonzo":"*"},"devDependencies":{},"_id":"littering@0.0.2","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.6","_nodeVersion":"v0.4.5","_defaultsLoaded":true,"dist":{"shasum":"250e814a4cd7afae0a5028948d03b9ed8242d765","tarball":"https://registry.npmjs.org/littering/-/littering-0.0.2.tgz","integrity":"sha512-edNCVpqmRvkzZQhca86fbxb2jSImLpJ4gP18WIPVlxFibcmvyDjCODgjkszLf+xKiy+tDrrjVJcIhpjxc0b7Vg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD8quK452XaPn6f95fmp6eWcdhmruBAr/ppZGl4adfP9wIgFfoUkksbfc3JeKwrUM1e9y//7uDb5dxwBlNe6eAgSvk="}]},"scripts":{}},"0.0.3":{"name":"littering","description":"ender based library for littering text with span markup, based on Lettering.js","version":"0.0.3","homepage":"https://github.com/cjc/littering","authors":["Cameron Coley"],"repository":{"type":"git","url":"git://github.com/cjc/littering.git"},"main":"./littering.js","dependencies":{"qwery":"*","bonzo":"*"},"devDependencies":{},"engines":{"node":"*"},"optionalDependencies":{},"author":{"name":"cjc","email":"cjc@cjc.id.au"},"_npmUser":{"name":"cjc","email":"cjc@cjc.id.au"},"_id":"littering@0.0.3","_engineSupported":true,"_npmVersion":"1.1.0-2","_nodeVersion":"v0.6.6","_defaultsLoaded":true,"dist":{"shasum":"ed4bdb53c0220ca37a01763d8567c01ee7106ecd","tarball":"https://registry.npmjs.org/littering/-/littering-0.0.3.tgz","integrity":"sha512-HckAjpyGVyAJ4Q6ARsVAL0bmDEJigEMTyupeIhQ0mxH25RnlM3HPEvI+pKDlJ8LO/1+9d4hKhopK1H1JJRN4Nw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICORokTLscxHoa3CWhC7xUrUkwmcqGXi5AHS0O+96mZaAiBkh/vhStGYSCGCgZcbK02EPgJL7TtaAADtuf+4U6QdWg=="}]},"maintainers":[{"name":"cjc","email":"cjc@cjc.id.au"}]},"0.0.4":{"name":"littering","description":"ender based library for littering text with span markup, based on Lettering.js","version":"0.0.4","homepage":"https://github.com/cjc/littering","authors":["Cameron Coley"],"repository":{"type":"git","url":"git://github.com/cjc/littering.git"},"main":"./littering.js","dependencies":{"qwery":"*","bonzo":"*"},"devDependencies":{},"engines":{"node":"*"},"optionalDependencies":{},"author":{"name":"cjc","email":"cjc@cjc.id.au"},"_npmUser":{"name":"cjc","email":"cjc@cjc.id.au"},"_id":"littering@0.0.4","_engineSupported":true,"_npmVersion":"1.1.0-2","_nodeVersion":"v0.6.6","_defaultsLoaded":true,"dist":{"shasum":"c7c68168ecaee302829e7bfbbabbbb82ebc1cd1a","tarball":"https://registry.npmjs.org/littering/-/littering-0.0.4.tgz","integrity":"sha512-AybLV0b/mRfWmBPsRyCtcKSsYEOACXvYYptJqRZomFHuHSbpYt1qM3AeXHWh/gHs/S9Ufoc0RQ90WW5dheYzaA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDUq8AagLuULZQoGHNI6FxWOhjSXMUcfDWuPbsMnoPGYAiBpF60tbYDosFy4OwB647Tu9cjyYYJefWatNMo+zWm22Q=="}]},"maintainers":[{"name":"cjc","email":"cjc@cjc.id.au"}]},"0.0.5":{"name":"littering","description":"ender based library for littering text with span markup, based on Lettering.js","version":"0.0.5","homepage":"https://github.com/cjc/littering","authors":["Cameron Coley"],"repository":{"type":"git","url":"git://github.com/cjc/littering.git"},"main":"./littering.js","dependencies":{"qwery":"*","bonzo":"*"},"devDependencies":{},"engines":{"node":"*"},"optionalDependencies":{},"author":{"name":"cjc","email":"cjc@cjc.id.au"},"_npmUser":{"name":"cjc","email":"cjc@cjc.id.au"},"_id":"littering@0.0.5","_engineSupported":true,"_npmVersion":"1.1.0-2","_nodeVersion":"v0.6.6","_defaultsLoaded":true,"dist":{"shasum":"a6716e4c0a304663ca3812520d2bce4e9a860616","tarball":"https://registry.npmjs.org/littering/-/littering-0.0.5.tgz","integrity":"sha512-KmGGaQk/wJgD7Xi9hakSGJJZbLGkJAIadjgm0wNoPOvSxy8LMd1a5xtlkY0o3BKjif4TwkKagpiMav1tKh5wzg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGcHcARu/ooTKCzavLEuAFVhGEyxHAsXwlPxkfArOcYfAiB7yKaW0wtImiJxNi+TXwwCVWciB9ZoiObcOXpnGRaUJA=="}]},"maintainers":[{"name":"cjc","email":"cjc@cjc.id.au"}]}},"maintainers":[{"name":"cjc","email":"cjc@cjc.id.au"}],"time":{"modified":"2022-06-19T12:52:09.048Z","created":"2011-05-17T01:31:40.377Z","0.0.1":"2011-05-17T01:31:42.714Z","0.0.2":"2011-05-17T03:09:44.025Z","0.0.3":"2012-01-19T13:16:27.026Z","0.0.4":"2012-02-23T12:04:31.012Z","0.0.5":"2012-03-19T11:14:55.853Z"},"repository":{"type":"git","url":"git://github.com/cjc/littering.git"},"author":{"name":"cjc","email":"cjc@cjc.id.au"},"readme":"#Littering - a less elegant javascript span injector\n\nLittering is an [ender](https://github.com/ender-js/ender) based variation of [Lettering.js](https://github.com/davatron5000/Lettering.js). Where lettering.js injects positional classes for styling chars/words/lins, Littering accepts functions to determine which classes to apply to which elements.\n\n##See it\n\nCheck the examples at [http://cjc.github.com/littering]()\n\n##Use it\n\nGet littering by including it in your ender build\n\n```\nender add littering\n```\n\n###Lettering.js compliant behaviour\n\nLittering mimics the same api as Lettering.js for the base functionality of decorating chars/words/lines with their position.\n\n```javascript\n$(\"#demo1 h1\").littering();\n$(\"#demo2 h1\").littering('words');\n$(\"#demo3 p\").littering('lines');\n$(\"#demo4 h1\").littering('words').children(\"span\").littering();\n$(\"#demo5 h1\").littering().children(\"span\").css({'display':'inline-block', '-webkit-transform':'rotate(-25deg)'});\n```\n\n###Other functionality\n\nIn addition to simply numbering elements, littering accepts custom formatter functions to allow arbitrary substitution of elements and complex class setting.  \n\n```javascript\n$(\"#demo6 h1\").littering('chars',function(){return 'a'});`\n$(\"#demo7 h1\").littering('chars',function(item,i){\n  var str = item.charCodeAt(0) > 64 && item.charCodeAt(0) < 91 ? \" upper\" : \"\" ;\n  return '<span class=\"char'+(i+1)+str+'\">'+item+'</span>';\n});\n```\n\n##History\n\n0.0.2 - Enable and add examples for passed formatter functions.\n0.0.1 - Replicate Lettering.js functionality running on ender.\n\n##Credits\n\nInspiration and some (ok, a bunch of) code (examples/index.html, the injector func) pinched from the excellent [Lettering.js](https://github.com/davatron5000/Lettering.js).\n\n##License\n\nReleased under the [WTFPL](http://sam.zoy.org/wtfpl/) license\n","readmeFilename":""}