Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

massive refactoring

  • Loading branch information...
commit ae405f18d36b5c6c785137ca1ed3b890ad8e56af 1 parent e936f2a
elclanrs authored
Showing with 27,656 additions and 0 deletions.
  1. +1 −0  css/jquery.tiles.min.css
  2. +146 −0 css/styles.css
  3. +44 −0 grunt.js
  4. BIN  img/bg.png
  5. BIN  img/bike.jpg
  6. BIN  img/boat.jpg
  7. BIN  img/bridge.jpg
  8. BIN  img/city.jpg
  9. BIN  img/club.jpg
  10. BIN  img/drop.jpg
  11. BIN  img/dust.jpg
  12. BIN  img/fruit.jpg
  13. BIN  img/girl.jpg
  14. BIN  img/mountain.jpg
  15. BIN  img/snake.jpg
  16. BIN  img/tiger.jpg
  17. +144 −0 index.html
  18. +269 −0 js/jquery.tiles.js
  19. +1 −0  js/min/jquery.tiles.min.js
  20. +188 −0 less/jquery.tiles.less
  21. +3 −0  node_modules/grunt-contrib-compress/.npmignore
  22. +3 −0  node_modules/grunt-contrib-compress/.travis.yml
  23. +3 −0  node_modules/grunt-contrib-compress/AUTHORS
  24. +23 −0 node_modules/grunt-contrib-compress/CHANGELOG
  25. +22 −0 node_modules/grunt-contrib-compress/LICENSE-MIT
  26. +79 −0 node_modules/grunt-contrib-compress/README.md
  27. +13 −0 node_modules/grunt-contrib-compress/docs/examples.md
  28. +37 −0 node_modules/grunt-contrib-compress/docs/options.md
  29. +4 −0 node_modules/grunt-contrib-compress/docs/overview.md
  30. +112 −0 node_modules/grunt-contrib-compress/grunt.js
  31. +3 −0  node_modules/grunt-contrib-compress/node_modules/archiver/.npmignore
  32. +4 −0 node_modules/grunt-contrib-compress/node_modules/archiver/.travis.yml
  33. +5 −0 node_modules/grunt-contrib-compress/node_modules/archiver/CHANGELOG
  34. +22 −0 node_modules/grunt-contrib-compress/node_modules/archiver/LICENSE-MIT
  35. +59 −0 node_modules/grunt-contrib-compress/node_modules/archiver/README.md
  36. +293 −0 node_modules/grunt-contrib-compress/node_modules/archiver/lib/archiver.js
  37. +86 −0 node_modules/grunt-contrib-compress/node_modules/archiver/lib/util/crc32.js
  38. +42 −0 node_modules/grunt-contrib-compress/node_modules/archiver/package.json
  39. +61 −0 node_modules/grunt-contrib-compress/node_modules/archiver/test/tests.js
  40. +5 −0 node_modules/grunt-contrib-compress/node_modules/fstream/.npmignore
  41. +3 −0  node_modules/grunt-contrib-compress/node_modules/fstream/.travis.yml
  42. +25 −0 node_modules/grunt-contrib-compress/node_modules/fstream/LICENCE
  43. +76 −0 node_modules/grunt-contrib-compress/node_modules/fstream/README.md
  44. +131 −0 node_modules/grunt-contrib-compress/node_modules/fstream/examples/filter-pipe.js
  45. +115 −0 node_modules/grunt-contrib-compress/node_modules/fstream/examples/pipe.js
  46. +54 −0 node_modules/grunt-contrib-compress/node_modules/fstream/examples/reader.js
  47. +24 −0 node_modules/grunt-contrib-compress/node_modules/fstream/examples/symlink-write.js
  48. +31 −0 node_modules/grunt-contrib-compress/node_modules/fstream/fstream.js
  49. +85 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/abstract.js
  50. +67 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/collect.js
  51. +250 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/dir-reader.js
  52. +171 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/dir-writer.js
  53. +147 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/file-reader.js
  54. +95 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/file-writer.js
  55. +32 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/get-type.js
  56. +54 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/link-reader.js
  57. +95 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/link-writer.js
  58. +93 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/proxy-reader.js
  59. +109 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/proxy-writer.js
  60. +259 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/reader.js
  61. +38 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/socket-reader.js
  62. +390 −0 node_modules/grunt-contrib-compress/node_modules/fstream/lib/writer.js
  63. +1 −0  node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/graceful-fs/.npmignore
  64. +23 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/graceful-fs/LICENSE
  65. +5 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/graceful-fs/README.md
  66. +312 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/graceful-fs/graceful-fs.js
  67. +35 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/graceful-fs/package.json
  68. +41 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/graceful-fs/test/open.js
  69. +51 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/inherits/README.md
  70. +29 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/inherits/inherits.js
  71. +26 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/inherits/package.json
  72. +2 −0  node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/.npmignore
  73. +4 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/.travis.yml
  74. +21 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/LICENSE
  75. +61 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/README.markdown
  76. +6 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/examples/pow.js
  77. +82 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/index.js
  78. +32 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/package.json
  79. +38 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/chmod.js
  80. +37 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/clobber.js
  81. +28 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/mkdirp.js
  82. +32 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/perm.js
  83. +39 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/perm_sync.js
  84. +41 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/race.js
  85. +32 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/rel.js
  86. +25 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/return.js
  87. +24 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/return_sync.js
  88. +18 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/root.js
  89. +32 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/sync.js
  90. +28 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/umask.js
  91. +32 −0 node_modules/grunt-contrib-compress/node_modules/fstream/node_modules/mkdirp/test/umask_sync.js
  92. +34 −0 node_modules/grunt-contrib-compress/node_modules/fstream/package.json
  93. +1 −0  node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/.gitattributes
  94. +3 −0  node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/.npmignore
  95. +3 −0  node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/.travis.yml
  96. +4 −0 node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/AUTHORS
  97. +14 −0 node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/CHANGELOG
  98. +22 −0 node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/LICENSE-MIT
  99. +56 −0 node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/README.md
  100. +62 −0 node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/grunt.js
  101. +193 −0 node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/lib/contrib.js
  102. +54 −0 node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/package.json
  103. +123 −0 node_modules/grunt-contrib-compress/node_modules/grunt-lib-contrib/test/lib_test.js
  104. +6 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/AUTHORS
  105. +23 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/LICENSE
  106. +21 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/README.md
  107. +1 −0  node_modules/grunt-contrib-compress/node_modules/rimraf/node_modules/graceful-fs/.npmignore
  108. +23 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/node_modules/graceful-fs/LICENSE
  109. +5 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/node_modules/graceful-fs/README.md
  110. +312 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/node_modules/graceful-fs/graceful-fs.js
  111. +35 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/node_modules/graceful-fs/package.json
  112. +41 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/node_modules/graceful-fs/test/open.js
  113. +54 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/package.json
  114. +161 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/rimraf.js
  115. +10 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/test/run.sh
  116. +47 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/test/setup.sh
  117. +5 −0 node_modules/grunt-contrib-compress/node_modules/rimraf/test/test-async.js
  118. 0  node_modules/grunt-contrib-compress/node_modules/rimraf/test/test-fiber.js
  119. +3 −0  node_modules/grunt-contrib-compress/node_modules/rimraf/test/test-sync.js
  120. +5 −0 node_modules/grunt-contrib-compress/node_modules/tar/.npmignore
  121. +3 −0  node_modules/grunt-contrib-compress/node_modules/tar/.travis.yml
  122. +50 −0 node_modules/grunt-contrib-compress/node_modules/tar/README.md
  123. +11 −0 node_modules/grunt-contrib-compress/node_modules/tar/examples/extracter.js
  124. +36 −0 node_modules/grunt-contrib-compress/node_modules/tar/examples/reader.js
  125. +30 −0 node_modules/grunt-contrib-compress/node_modules/tar/lib/buffer-entry.js
  126. +169 −0 node_modules/grunt-contrib-compress/node_modules/tar/lib/entry-writer.js
  127. +212 −0 node_modules/grunt-contrib-compress/node_modules/tar/lib/entry.js
  128. +192 −0 node_modules/grunt-contrib-compress/node_modules/tar/lib/extended-header-writer.js
  129. +139 −0 node_modules/grunt-contrib-compress/node_modules/tar/lib/extended-header.js
  130. +78 −0 node_modules/grunt-contrib-compress/node_modules/tar/lib/extract.js
  131. +14 −0 node_modules/grunt-contrib-compress/node_modules/tar/lib/global-header-writer.js
  132. +385 −0 node_modules/grunt-contrib-compress/node_modules/tar/lib/header.js
  133. +226 −0 node_modules/grunt-contrib-compress/node_modules/tar/lib/pack.js
  134. +270 −0 node_modules/grunt-contrib-compress/node_modules/tar/lib/parse.js
  135. +25 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/LICENCE
  136. +14 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/README.md
  137. +70 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/bench/block-stream-pause.js
  138. +68 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/bench/block-stream.js
  139. +70 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/bench/dropper-pause.js
  140. +68 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/bench/dropper.js
  141. +209 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/block-stream.js
  142. +31 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/package.json
  143. +27 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/test/basic.js
  144. +68 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/test/nopad-thorough.js
  145. +57 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/test/nopad.js
  146. +73 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/test/pause-resume.js
  147. +68 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/test/thorough.js
  148. +59 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/block-stream/test/two-stream.js
  149. +51 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/inherits/README.md
  150. +29 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/inherits/inherits.js
  151. +25 −0 node_modules/grunt-contrib-compress/node_modules/tar/node_modules/inherits/package.json
  152. +33 −0 node_modules/grunt-contrib-compress/node_modules/tar/package.json
  153. +172 −0 node_modules/grunt-contrib-compress/node_modules/tar/tar.js
  154. +53 −0 node_modules/grunt-contrib-compress/node_modules/tar/test/00-setup-fixtures.js
  155. +358 −0 node_modules/grunt-contrib-compress/node_modules/tar/test/extract.js
  156. BIN  node_modules/grunt-contrib-compress/node_modules/tar/test/fixtures.tgz
  157. +183 −0 node_modules/grunt-contrib-compress/node_modules/tar/test/header.js
  158. +854 −0 node_modules/grunt-contrib-compress/node_modules/tar/test/pack-no-proprietary.js
  159. +898 −0 node_modules/grunt-contrib-compress/node_modules/tar/test/pack.js
  160. +359 −0 node_modules/grunt-contrib-compress/node_modules/tar/test/parse.js
  161. +20 −0 node_modules/grunt-contrib-compress/node_modules/tar/test/zz-cleanup.js
  162. +61 −0 node_modules/grunt-contrib-compress/package.json
  163. +256 −0 node_modules/grunt-contrib-compress/tasks/compress.js
  164. +108 −0 node_modules/grunt-contrib-compress/test/compress_test.js
  165. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_file.gz
  166. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_file2.gz
  167. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_files.tar
  168. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_files.zip
  169. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_files_template.tar
  170. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_files_template.zip
  171. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_flatten.tar
  172. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_flatten.zip
  173. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_rootdir.tar
  174. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_rootdir.zip
  175. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_v0.1.0.tar
  176. BIN  node_modules/grunt-contrib-compress/test/expected/compress_test_v0.1.0.zip
  177. +1 −0  node_modules/grunt-contrib-compress/test/fixtures/folder_one/one.css
  178. +1 −0  node_modules/grunt-contrib-compress/test/fixtures/folder_one/one.js
  179. +1 −0  node_modules/grunt-contrib-compress/test/fixtures/folder_two/two.css
  180. +1 −0  node_modules/grunt-contrib-compress/test/fixtures/folder_two/two.js
  181. +1 −0  node_modules/grunt-contrib-compress/test/fixtures/test.css
  182. +1 −0  node_modules/grunt-contrib-compress/test/fixtures/test.js
  183. +3 −0  node_modules/grunt-contrib-less/.npmignore
  184. +3 −0  node_modules/grunt-contrib-less/.travis.yml
  185. +7 −0 node_modules/grunt-contrib-less/AUTHORS
  186. +19 −0 node_modules/grunt-contrib-less/CHANGELOG
  187. +22 −0 node_modules/grunt-contrib-less/LICENSE-MIT
  188. +74 −0 node_modules/grunt-contrib-less/README.md
  189. +21 −0 node_modules/grunt-contrib-less/docs/examples.md
  190. +25 −0 node_modules/grunt-contrib-less/docs/options.md
  191. +105 −0 node_modules/grunt-contrib-less/grunt.js
  192. +15 −0 node_modules/grunt-contrib-less/node_modules/.bin/lessc
  193. +6 −0 node_modules/grunt-contrib-less/node_modules/.bin/lessc.cmd
  194. +1 −0  node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/.gitattributes
  195. +3 −0  node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/.npmignore
  196. +3 −0  node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/.travis.yml
  197. +4 −0 node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/AUTHORS
  198. +14 −0 node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/CHANGELOG
  199. +22 −0 node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/LICENSE-MIT
  200. +56 −0 node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/README.md
  201. +62 −0 node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/grunt.js
  202. +193 −0 node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/lib/contrib.js
  203. +54 −0 node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/package.json
  204. +123 −0 node_modules/grunt-contrib-less/node_modules/grunt-lib-contrib/test/lib_test.js
  205. +2 −0  node_modules/grunt-contrib-less/node_modules/less/.npmignore
  206. +26 −0 node_modules/grunt-contrib-less/node_modules/less/CHANGELOG
  207. +179 −0 node_modules/grunt-contrib-less/node_modules/less/LICENSE
  208. +75 −0 node_modules/grunt-contrib-less/node_modules/less/Makefile
  209. +20 −0 node_modules/grunt-contrib-less/node_modules/less/README.md
  210. +47 −0 node_modules/grunt-contrib-less/node_modules/less/benchmark/less-benchmark.js
  211. +139 −0 node_modules/grunt-contrib-less/node_modules/less/bin/lessc
  212. +2,695 −0 node_modules/grunt-contrib-less/node_modules/less/dist/less-1.1.0.js
  213. +16 −0 node_modules/grunt-contrib-less/node_modules/less/dist/less-1.1.0.min.js
  214. +2,710 −0 node_modules/grunt-contrib-less/node_modules/less/dist/less-1.1.1.js
  215. +16 −0 node_modules/grunt-contrib-less/node_modules/less/dist/less-1.1.1.min.js
  216. +2,712 −0 node_modules/grunt-contrib-less/node_modules/less/dist/less-1.1.2.js
  217. +16 −0 node_modules/grunt-contrib-less/node_modules/less/dist/less-1.1.2.min.js
  218. +2,721 −0 node_modules/grunt-contrib-less/node_modules/less/dist/less-1.1.3.js
  219. +16 −0 node_modules/grunt-contrib-less/node_modules/less/dist/less-1.1.3.min.js
  220. +2,769 −0 node_modules/grunt-contrib-less/node_modules/less/dist/less-1.1.4.js
Sorry, we could not display the entire diff because too many files (319) changed.
View
1  css/jquery.tiles.min.css
@@ -0,0 +1 @@
+.tiles-preload .tiles-wrap *{-webkit-transition:none!important;-moz-transition:none!important;-ms-transition:none!important;-o-transition:none!important;transition:none!important}.tiles-slider-wrap,.tiles-tile{position:relative}.tiles-wrap{position:absolute;height:100%;width:100%;-webkit-perspective:1000px;-moz-perspective:1000px;-ms-perspective:1000px;-o-perspective:1000px;perspective:1000px}.tiles-tile{float:left;top:0;left:0;right:0;bottom:0;opacity:1;z-index:0;-webkit-transition:all .3s ease-in-out;-moz-transition:all .3s ease-in-out;-ms-transition:all .3s ease-in-out;-o-transition:all .3s ease-in-out;transition:all .3s ease-in-out}.tiles-slider-s100 .tiles-tile{-webkit-transition:all .1s ease-in-out;-moz-transition:all .1s ease-in-out;-ms-transition:all .1s ease-in-out;-o-transition:all .1s ease-in-out;transition:all .1s ease-in-out}.tiles-slider-s200 .tiles-tile{-webkit-transition:all .2s ease-in-out;-moz-transition:all .2s ease-in-out;-ms-transition:all .2s ease-in-out;-o-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.tiles-slider-s300 .tiles-tile{-webkit-transition:all .3s ease-in-out;-moz-transition:all .3s ease-in-out;-ms-transition:all .3s ease-in-out;-o-transition:all .3s ease-in-out;transition:all .3s ease-in-out}.tiles-slider-s400 .tiles-tile{-webkit-transition:all .4s ease-in-out;-moz-transition:all .4s ease-in-out;-ms-transition:all .4s ease-in-out;-o-transition:all .4s ease-in-out;transition:all .4s ease-in-out}.tiles-slider-s500 .tiles-tile{-webkit-transition:all .5s ease-in-out;-moz-transition:all .5s ease-in-out;-ms-transition:all .5s ease-in-out;-o-transition:all .5s ease-in-out;transition:all .5s ease-in-out}.tiles-slider-s600 .tiles-tile{-webkit-transition:all .6s ease-in-out;-moz-transition:all .6s ease-in-out;-ms-transition:all .6s ease-in-out;-o-transition:all .6s ease-in-out;transition:all .6s ease-in-out}.tiles-slider-s700 .tiles-tile{-webkit-transition:all .7s ease-in-out;-moz-transition:all .7s ease-in-out;-ms-transition:all .7s ease-in-out;-o-transition:all .7s ease-in-out;transition:all .7s ease-in-out}.tiles-slider-s800 .tiles-tile{-webkit-transition:all .8s ease-in-out;-moz-transition:all .8s ease-in-out;-ms-transition:all .8s ease-in-out;-o-transition:all .8s ease-in-out;transition:all .8s ease-in-out}.tiles-slider-s900 .tiles-tile{-webkit-transition:all .9s ease-in-out;-moz-transition:all .9s ease-in-out;-ms-transition:all .9s ease-in-out;-o-transition:all .9s ease-in-out;transition:all .9s ease-in-out}.tiles-slider-s1000 .tiles-tile{-webkit-transition:all 1s ease-in-out;-moz-transition:all 1s ease-in-out;-ms-transition:all 1s ease-in-out;-o-transition:all 1s ease-in-out;transition:all 1s ease-in-out}.tiles-tile.tiles-reset{-webkit-transition:all 0s ease-in-out;-moz-transition:all 0s ease-in-out;-ms-transition:all 0s ease-in-out;-o-transition:all 0s ease-in-out;transition:all 0s ease-in-out}.tiles-simple-anim{opacity:0}.tiles-default-anim{position:relative;opacity:0;box-shadow:0 0 10px black;top:-5%;left:5%;z-index:1}.tiles-y1.tiles-up-anim{height:1px!important}.tiles-x1.tiles-left-normal{clear:both}.tiles-x1.tiles-left-anim{width:0!important}.tiles-switchlr-anim.tiles-even.tiles-y1.tiles-x2{left:50%}.tiles-switchlr-anim.tiles-even.tiles-y1.tiles-x4{left:25%}.tiles-switchlr-anim.tiles-even.tiles-y1.tiles-x6{left:16.666666666666668%}.tiles-switchlr-anim.tiles-even.tiles-y1.tiles-x8{left:12.5%}.tiles-switchlr-anim.tiles-even.tiles-y1.tiles-x10{left:10%}.tiles-switchlr-anim.tiles-even.tiles-y1.tiles-x12{left:8.333333333333334%}.tiles-switchlr-anim.tiles-even.tiles-y1.tiles-x14{left:7.142857142857143%}.tiles-switchlr-anim.tiles-even.tiles-y1.tiles-x16{left:6.25%}.tiles-switchlr-anim.tiles-even.tiles-y1.tiles-x18{left:5.555555555555555%}.tiles-switchlr-anim.tiles-even.tiles-y1.tiles-x20{left:5%}.tiles-switchlr-anim.tiles-odd.tiles-y1.tiles-x2{left:-50%}.tiles-switchlr-anim.tiles-odd.tiles-y1.tiles-x4{left:-25%}.tiles-switchlr-anim.tiles-odd.tiles-y1.tiles-x6{left:-16.666666666666668%}.tiles-switchlr-anim.tiles-odd.tiles-y1.tiles-x8{left:-12.5%}.tiles-switchlr-anim.tiles-odd.tiles-y1.tiles-x10{left:-10%}.tiles-switchlr-anim.tiles-odd.tiles-y1.tiles-x12{left:-8.333333333333334%}.tiles-switchlr-anim.tiles-odd.tiles-y1.tiles-x14{left:-7.142857142857143%}.tiles-switchlr-anim.tiles-odd.tiles-y1.tiles-x16{left:-6.25%}.tiles-switchlr-anim.tiles-odd.tiles-y1.tiles-x18{left:-5.555555555555555%}.tiles-switchlr-anim.tiles-odd.tiles-y1.tiles-x20{left:-5%}.tiles-switchud-anim.tiles-even.tiles-x1.tiles-y2{top:50%}.tiles-switchud-anim.tiles-even.tiles-x1.tiles-y4{top:25%}.tiles-switchud-anim.tiles-even.tiles-x1.tiles-y6{top:16.666666666666668%}.tiles-switchud-anim.tiles-even.tiles-x1.tiles-y8{top:12.5%}.tiles-switchud-anim.tiles-even.tiles-x1.tiles-y10{top:10%}.tiles-switchud-anim.tiles-even.tiles-x1.tiles-y12{top:8.333333333333334%}.tiles-switchud-anim.tiles-even.tiles-x1.tiles-y14{top:7.142857142857143%}.tiles-switchud-anim.tiles-even.tiles-x1.tiles-y16{top:6.25%}.tiles-switchud-anim.tiles-even.tiles-x1.tiles-y18{top:5.555555555555555%}.tiles-switchud-anim.tiles-even.tiles-x1.tiles-y20{top:5%}.tiles-switchud-anim.tiles-odd.tiles-x1.tiles-y2{top:-50%}.tiles-switchud-anim.tiles-odd.tiles-x1.tiles-y4{top:-25%}.tiles-switchud-anim.tiles-odd.tiles-x1.tiles-y6{top:-16.666666666666668%}.tiles-switchud-anim.tiles-odd.tiles-x1.tiles-y8{top:-12.5%}.tiles-switchud-anim.tiles-odd.tiles-x1.tiles-y10{top:-10%}.tiles-switchud-anim.tiles-odd.tiles-x1.tiles-y12{top:-8.333333333333334%}.tiles-switchud-anim.tiles-odd.tiles-x1.tiles-y14{top:-7.142857142857143%}.tiles-switchud-anim.tiles-odd.tiles-x1.tiles-y16{top:-6.25%}.tiles-switchud-anim.tiles-odd.tiles-x1.tiles-y18{top:-5.555555555555555%}.tiles-switchud-anim.tiles-odd.tiles-x1.tiles-y20{top:-5%}.tiles-fliplr-anim{-webkit-transform:rotateY(180deg);-moz-transform:rotateY(180deg);-ms-transform:rotateY(180deg);-o-transform:rotateY(180deg);transform:rotateY(180deg)}.tiles-flipud-anim{-webkit-transform:rotateX(180deg);-moz-transform:rotateX(180deg);-ms-transform:rotateX(180deg);-o-transform:rotateX(180deg);transform:rotateX(180deg)}.tiles-reduce-anim{-webkit-transform:scale(0);-moz-transform:scale(0);-ms-transform:scale(0);-o-transform:scale(0);transform:scale(0)}.tiles-360-anim{-webkit-transform:rotateZ(360deg) scale(0);-moz-transform:rotateZ(360deg) scale(0);-ms-transform:rotateZ(360deg) scale(0);-o-transform:rotateZ(360deg) scale(0);transform:rotateZ(360deg) scale(0)}.tiles-leftright-anim.tiles-even{-webkit-transform:translate(50%,0);-moz-transform:translate(50%,0);-ms-transform:translate(50%,0);-o-transform:translate(50%,0);transform:translate(50%,0)}.tiles-leftright-anim.tiles-odd{-webkit-transform:translate(-50%,0);-moz-transform:translate(-50%,0);-ms-transform:translate(-50%,0);-o-transform:translate(-50%,0);transform:translate(-50%,0)}.tiles-updown-anim.tiles-even{-webkit-transform:translate(0,50%);-moz-transform:translate(0,50%);-ms-transform:translate(0,50%);-o-transform:translate(0,50%);transform:translate(0,50%)}.tiles-updown-anim.tiles-odd{-webkit-transform:translate(0,-50%);-moz-transform:translate(0,-50%);-ms-transform:translate(0,-50%);-o-transform:translate(0,-50%);transform:translate(0,-50%)}.tiles-slider-wrap .tiles-switchlr-anim,.tiles-slider-wrap .tiles-switchud-anim,.tiles-slider-wrap .tiles-fliplr-anim,.tiles-slider-wrap .tiles-y1.tiles-up-anim,.tiles-slider-wrap .tiles-x1.tiles-left-anim,.tiles-slider-wrap .tiles-updown-anim,.tiles-slider-wrap .tiles-leftright-anim,.tiles-slider-wrap .tiles-flipud-anim,.tiles-slider-wrap .tiles-reduce-anim{opacity:0;visibility:hidden}.tiles-slider-leftright .tiles-wrap,.tiles-slider-updown .tiles-wrap,.tiles-slider-360 .tiles-wrap{overflow:hidden}
View
146 css/styles.css
@@ -0,0 +1,146 @@
+body {
+ width: 640px;
+ margin: 30px auto;
+ background: url(../img/bg.png);
+ font: normal 13px Arial, sans;
+ overflow-y: scroll;
+ color: #222;
+}
+a {
+ color: #088BBF;
+ text-decoration: none;
+ font-weight: bold;
+}
+a:hover { text-decoration: underline }
+img { display: block; }
+header { margin: 50px 0 30px 0; }
+.effects {
+ float: right;
+ margin-top: 20px;
+ font-family: Arial;
+}
+#effects_select {
+ width: 120px;
+ padding: .3em;
+ outline: 0;
+ border: 1px solid grey;
+ border-radius: 3px;
+}
+label { font-weight: bold; padding-right: .5em; }
+h1, h3 { display: inline-block; }
+h1 {
+ font-size: 42px;
+ font-weight: normal;
+ letter-spacing: -1px;
+ text-shadow: 1px 1px 0 white;
+ margin: 0;
+ font-family: Doppio One, sans;
+}
+h3 {
+ color: #444;
+ font-size: 18px;
+ font-weight: normal;
+ position: relative;
+ top: 4px;
+}
+.code { display: inline-block; }
+code {
+ font-family: Ubuntu Mono, mono;
+ background: #dedede;
+ padding: .3em .8em;
+ font-size: 14px;
+ position: relative;
+ margin: 0 3px;
+ left: 15px;
+ top: 2px;
+ border-radius: 3px;
+ color: #444;
+}
+.title { position: relative; }
+article {
+ background: white;
+ padding: 20px;
+ padding-bottom: 10px;
+ margin: 15px 0;
+ border-radius: 3px;
+ box-shadow: 0 0 5px rgba(0,0,0,.15);
+ -webkit-transition: all .5s ease-in-out;
+ -moz-transition: all .5s ease-in-out;
+ -ms-transition: all .5s ease-in-out;
+ -o-transition: all .5s ease-in-out;
+ transition: all .5s ease-in-out;
+}
+article.active {
+ box-shadow: 0 0 0 1px #088BBF,
+ 0 0 20px rgba(8,139,191,.5),
+ 0 0 40px rgba(0,0,0,.3);
+}
+#down {
+ position: relative;
+ left: 20px;
+ top: -6px;
+}
+#github {
+ position: relative;
+ top: 10px;
+}
+button::-moz-focus-inner { border: 0; }
+button.action {
+ float: right;
+ width: 60px;
+ position: relative;
+ top: 5px;
+ cursor: pointer;
+ font-family: Arial, Helvetica, sans-serif;
+ font-size: 14px;
+ color: #ffffff;
+ padding: 7px 14px;
+ margin: 10px 0 10px 5px;
+ background: #7d7e7d;
+ background: -moz-linear-gradient(top, #7d7e7d 0%, #0e0e0e 100%);
+ background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#7d7e7d), color-stop(100%,#0e0e0e));
+ background: -webkit-linear-gradient(top, #7d7e7d 0%,#0e0e0e 100%);
+ background: -o-linear-gradient(top, #7d7e7d 0%,#0e0e0e 100%);
+ background: -ms-linear-gradient(top, #7d7e7d 0%,#0e0e0e 100%);
+ background: linear-gradient(to bottom, #7d7e7d 0%,#0e0e0e 100%);
+ filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#7d7e7d', endColorstr='#0e0e0e',GradientType=0 );
+ -moz-border-radius: 3px;
+ -webkit-border-radius: 3px;
+ border-radius: 3px;
+ border: 1px solid #000000;
+ -moz-box-shadow:
+ 0px 1px 3px rgba(000,000,000,0.5),
+ inset 0px 0px 1px rgba(255,255,255,0.4);
+ -webkit-box-shadow:
+ 0px 1px 3px rgba(000,000,000,0.5),
+ inset 0px 0px 1px rgba(255,255,255,0.4);
+ box-shadow:
+ 0px 1px 3px rgba(000,000,000,0.5),
+ inset 0px 0px 1px rgba(255,255,255,0.6);
+ text-shadow:
+ 0px -1px 0px rgba(000,000,000,1),
+ 0px 1px 0px rgba(255,255,255,0.2);
+}
+button.action:active {
+ background: #222;
+ top: 6px;
+}
+.active button.action.start {
+ background: #258dc8;
+ background: -moz-linear-gradient(top, #258dc8 0%, #258dc8 100%);
+ background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#258dc8), color-stop(100%,#258dc8));
+ background: -webkit-linear-gradient(top, #258dc8 0%,#258dc8 100%);
+ background: -o-linear-gradient(top, #258dc8 0%,#258dc8 100%);
+ background: -ms-linear-gradient(top, #258dc8 0%,#258dc8 100%);
+ background: linear-gradient(to bottom, #258dc8 0%,#258dc8 100%);
+ filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#258dc8', endColorstr='#258dc8',GradientType=0 );
+ color: white;
+ border: 1px solid #174E9C;
+ text-shadow: 1px 1px rgba(0,0,0,.5);
+}
+button.action.stop { display: none; }
+.slider {
+ width: 600px;
+ height: 400px;
+ margin-bottom: 30px;
+}
View
44 grunt.js
@@ -0,0 +1,44 @@
+module.exports = function(grunt) {
+
+ grunt.initConfig({
+
+ less: {
+ dist: {
+ paths: ['less'],
+ files: { 'css/jquery.tiles.min.css': 'less/*.less' },
+ options: { yuicompress: true }
+ }
+ },
+
+ min: {
+ dist:{
+ src: ['js/*.js'],
+ dest: 'js/min/jquery.tiles.min.js'
+ }
+ },
+
+ compress: {
+ zip: {
+ files: {
+ 'zip/jquery.tiles.zip': [
+ 'css/jquery.tiles.min.css',
+ 'js/min/jquery.tiles.min.js'
+ ]
+ }
+ },
+ options: { flatten: true }
+ },
+
+ watch: {
+ files: ['**'],
+ tasks: 'default'
+ }
+
+ })
+
+ grunt.loadNpmTasks('grunt-contrib-less')
+ grunt.loadNpmTasks('grunt-contrib-compress')
+
+ grunt.registerTask('default', 'less min compress')
+
+}
View
BIN  img/bg.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/bike.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/boat.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/bridge.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/city.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/club.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/drop.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/dust.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/fruit.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/girl.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/mountain.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/snake.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  img/tiger.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
144 index.html
@@ -0,0 +1,144 @@
+<!doctype html>
+<html>
+ <head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="chrome=1">
+ <title>jq-tiles</title>
+ <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
+ <!--[if lt IE 9]>
+ <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
+ <![endif]-->
+ <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.1/jquery.min.js"></script>
+ <script src="js/jquery.tiles.js"></script>
+ <link href='http://fonts.googleapis.com/css?family=Doppio+One' rel='stylesheet' type='text/css'>
+ <link href='http://fonts.googleapis.com/css?family=Ubuntu+Mono' rel='stylesheet' type='text/css'>
+ <link rel="stylesheet" href="http://necolas.github.com/normalize.css/2.0.1/normalize.css"/>
+ <link rel="stylesheet" href="css/jquery.tiles.min.css"/>
+ <link rel="stylesheet" href="css/styles.css"/>
+ </head>
+ <body>
+
+ <a href="https://github.com/elclanrs/jq-tiles"><img style="position: fixed; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub"></a>
+
+ <header>
+ <h1>jq-tiles</h1>
+ <a href="https://github.com/elclanrs/jq-tiles/zipball/master" id="down">Download</a>
+ <div class="effects">
+ <label>Effect:</label>
+ <select id="effects_select">
+ <option value="default">default</option>
+ <option value="simple">simple</option>
+ <option value="left">left</option>
+ <option value="up">up</option>
+ <option value="leftright">leftright</option>
+ <option value="updown">updown</option>
+ <option value="switchlr">switchlr</option>
+ <option value="switchud">switchud</option>
+ <option value="fliplr">fliplr</option>
+ <option value="flipud">flipud</option>
+ <option value="reduce">reduce</option>
+ <option value="360">360</option>
+ </select>
+ </div>
+ </header>
+
+ <section>
+ <article id="default">
+ <div class="title">
+ <h3>&raquo; default</h3>
+ <div class="code">
+ <code>x:6</code>
+ <code>y:4</code>
+ <code>random:true</code>
+ </div>
+ <button type="button" class="start action">Start</button>
+ <button type="button" class="stop action">Stop</button>
+ </div>
+ <div class="slider">
+ <img src="img/bridge.jpg"/>
+ <img src="img/tiger.jpg"/>
+ <img src="img/city.jpg"/>
+ <img src="img/club.jpg"/>
+ <img src="img/snake.jpg"/>
+ <img src="img/mountain.jpg"/>
+ <img src="img/boat.jpg"/>
+ <img src="img/bike.jpg"/>
+ <img src="img/dust.jpg"/>
+ <img src="img/drop.jpg"/>
+ <img src="img/fruit.jpg"/>
+ <img src="img/girl.jpg"/>
+ </div>
+ </article>
+ </section>
+
+ <a id="github" href="https://github.com/elclanrs/jq-tiles">&laquo; Back to Github</a>
+
+ <script>
+
+
+ var html = $('section').html();
+
+ // Options
+ var effects = {
+ 'default': { x:6, y:4, random: true },
+ simple: { x:6, y:4, effect: 'simple', random: true },
+ left: { x:1, y:8, effect: 'left' },
+ up: { x:20, y:1, effect: 'up', rewind: 60 },
+ leftright: { x:1, y:8, effect: 'leftright' },
+ updown: { x:12, y:1, effect: 'updown', cssSpeed: 500 },
+ switchlr: { x:12, y:1, effect: 'switchlr' },
+ switchud: { x:1, y:8, effect: 'switchud' },
+ fliplr: { x:12, y:1, effect: 'fliplr', reverse: true },
+ flipud: { x:1, y:8, effect: 'flipud' },
+ reduce: { x:6, y:4, effect: 'reduce' },
+ 360: { x:1, y:1, effect: '360', fade: true, cssSpeed: 600 }
+ };
+
+ // Change
+ $('#effects_select').change(function(){
+ timer = false;
+ $('.slider').trigger('stop');
+ var effect = $(this).val();
+ $('section').fadeTo(0,0).empty().html(html);
+ setTimeout(function(){
+ $('section').fadeTo(0,1);
+ $('.slider').tilesSlider(effects[effect]);
+ $('article')
+ .find('h3').html('&raquo; '+ effect).end()
+ .find('.code').html(function(){
+ var code = [];
+ var ops = effects[effect];
+ for (var o in ops) {
+ if (!/^(auto|effect)/.test(o)) {
+ code.push('<code>'+ o +':'+ ops[o] +'</code>');
+ }
+ }
+ return code.join('');
+ });
+ $('body').removeClass('tiles-preload');
+ }, 100);
+ });
+
+ // Start
+ $('section').on('click', '.start', function(){
+ $('.stop').delay(150).fadeIn(250);
+ $('.start').text('Next');
+ $('article').addClass('active');
+ $('.slider').tilesSlider('start');
+ });
+
+ // Stop
+ $('section').on('click', '.stop', function(){
+ $('.start').text('Start');
+ $('article').removeClass('active');
+ $('.slider').tilesSlider('stop');
+ $('.stop').delay(150).fadeOut(250);
+ });
+
+ // Init
+ $('.slider').tilesSlider(effects['default']);
+
+ </script>
+
+ </body>
+</html>
View
269 js/jquery.tiles.js
@@ -0,0 +1,269 @@
+
+;(function( $, window, undefined ) {
+
+ // Globals:
+
+ var _interval
+ , _defaults = {
+ x: 4, y: 4,
+ slider: false,
+ effect: 'default',
+ fade: false,
+ random: false,
+ reverse: false,
+ limit: false,
+ rewind: false,
+ auto: false,
+ loop: true,
+ slideSpeed: 2500,
+ tileSpeed: 1000,
+ cssSpeed: 250
+ }
+ , Utils = {
+ /**
+ * range Get an array of numbers within a range
+ * @param min {number} Lowest number in array
+ * @param max {number} Highest number in array
+ * @param rand {bool} Shuffle array
+ * @return {array}
+ */
+ range: function( min, max, rand ) {
+ var arr = ( new Array( ++max - min ) )
+ .join('.').split('.')
+ .map(function( v,i ){ return min + i })
+ return rand
+ ? arr.map(function( v ) { return [ Math.random(), v ] })
+ .sort().map(function( v ) { return v[ 1 ] })
+ : arr
+ }
+ }
+
+ // Constructor
+ function TilesSlider( element, options ) {
+
+ this.opts = $.extend( {}, _defaults, options )
+ this.klass = 'tiles-'+ this.opts.effect
+ this.klassNormal = this.klass + '-normal'
+ this.klassAnim = this.klass + '-anim'
+ this.n_tiles = this.opts.x * this.opts.y
+
+ this.$container = $( element )
+ this.$images = this.$container.find('img')
+
+ // Assign in _init when elements are generated
+ this.$tiles = null
+
+ if ( this.opts.rewind ) { this.opts.fade = true }
+
+ this._init()
+
+ }
+
+ // Methods:
+
+ TilesSlider.prototype = {
+
+ _init: function() {
+
+ var self = this
+ , o = self.opts
+
+ // Do nothing if there are no images
+ if ( !self.$images.length ) { return false }
+
+ self.$container.addClass('tiles-slider-wrap tiles-slider-'+
+ o.effect +' tiles-slider-s'+ o.cssSpeed)
+
+ // Generate tiles
+ self.$images.each(function() { self._generateTiles( $(this) ) })
+
+ // Remove from DOM to handle in slider
+ self.$wraps = self.$container.find('.tiles-wrap').detach()
+ self.$wraps.first().addClass('tiles-wrap-current').appendTo( self.$container )
+
+ // Prevent css3 transitions on load
+ $('body').addClass('tiles-preload')
+ $( window ).load(function(){ $('body').removeClass('tiles-preload') })
+
+ if ( o.auto ) { self.start() }
+
+ },
+
+ _generateTiles: function( $img ) {
+
+ var self = this
+ , o = self.opts
+ , tiles = [], $tiles
+
+ for ( var i = 0; i < self.n_tiles; i++ ) {
+ tiles.push('<div class="tiles-tile '+ self.klassNormal +'"/>')
+ }
+
+ $tiles = $( tiles.join('') )
+
+ $tiles.addClass('tiles-x'+ o.x +' tiles-y'+ o.y)
+ .filter(':odd').addClass('tiles-odd').end()
+ .filter(':even').addClass('tiles-even')
+
+ $tiles.css({
+ width: self.$container.width() / o.x,
+ height: self.$container.height() / o.y,
+ backgroundImage: 'url('+ $img.attr('src') +')'
+ })
+
+ // Insert in DOM
+ $('<div class="tiles-wrap"/>').append( $tiles ).insertAfter( $img.hide() )
+
+ // Calculate offset when image is in DOM
+ $tiles.each(function(){
+ var $this = $(this), pos = $this.position()
+ $this.css('backgroundPosition', -pos.left +'px '+ -pos.top +'px')
+ })
+
+ },
+
+ _animateTiles: function( $wrap, callback ) {
+
+ callback = callback || $.noop
+
+ var self = this
+ , o = self.opts
+ , range = Utils.range( 0, self.n_tiles, o.random )
+ , delay = Math.floor( o.tileSpeed / self.n_tiles )
+ , limit = range.length / ( 100/o.limit )
+ , done = o.tileSpeed + o.cssSpeed
+ , $tiles = $wrap.find('.tiles-tile')
+
+ if ( o.reverse ) { range = range.reverse() }
+
+ if ( o.limit ) {
+ o.reverse
+ ? range.splice( 0, limit )
+ : range.splice( limit, range.length );
+ }
+
+ range.forEach(function( tile, i ) {
+
+ var theTile = $tiles.eq( tile )
+ , theDelay = i * delay
+
+ setTimeout(function() { theTile.addClass( self.klassAnim ) }, theDelay )
+
+ if ( o.rewind ) {
+ theDelay += ( o.cssSpeed / (100/o.rewind) )
+ setTimeout(function() { theTile.removeClass( self.klassAnim ) }, theDelay )
+ }
+
+ })
+
+ // Callback
+ setTimeout( callback, done )
+
+ },
+
+ _resetTiles: function( $wrap ) {
+ $wrap.find('.tiles-tile').removeClass( this.klassAnim )
+ },
+
+ _getCurrentWrap: function() {
+ return this.$wraps.filter('.tiles-wrap-current')
+ },
+
+ _getCurrentIdx: function() {
+ return this.$wraps.index( this._getCurrentWrap() )
+ },
+
+ _navigate: function( idx, callback ) {
+
+ var self = this
+ , o = self.opts
+ , $cur = self._getCurrentWrap()
+ , $target = self.$wraps.eq( idx )
+
+ self.$container.find('.tiles-wrap').removeClass('tiles-wrap-current')
+ $target.addClass('tiles-wrap-current').prependTo( self.$container )
+
+ if ( o.fade ) {
+ $target.fadeOut(1).fadeIn( o.tileSpeed )
+ }
+
+ if ( o.rewind ) {
+ $cur.fadeIn(1).delay( o.tileSpeed/2 ).fadeOut( o.tileSpeed )
+ }
+
+ self._animateTiles( $cur, function() {
+ $cur.remove()
+ self._resetTiles( $cur )
+ callback()
+ })
+
+ return this
+
+ },
+
+ // Public methods:
+
+ prev: function( callback ) {
+
+ var self = this
+ , $cur = self._getCurrentWrap()
+ , isFirst = $cur.is( self.$wraps.first() )
+ , idx = isFirst ? self.$wraps.length - 1 : self._getCurrentIdx() - 1
+
+ return this._navigate( idx, callback || $.noop )
+
+ },
+
+ next: function( callback ) {
+
+ var self = this
+ , $cur = self._getCurrentWrap()
+ , isLast = $cur.is( self.$wraps.last() )
+ , idx = isLast ? 0 : self._getCurrentIdx() + 1
+
+ return this._navigate( idx, callback || $.noop )
+
+ },
+
+ start: function() {
+
+ var self = this
+ , o = self.opts
+ , endLoop = ( o.slideSpeed * (self.$wraps.length-1) ) + o.tileSpeed
+
+ if ( _interval ) { self.stop().next() }
+
+ _interval = setInterval(function() {
+ self.next() }, o.slideSpeed )
+
+ if ( !o.loop ) {
+ setTimeout(function(){ self.stop() }, endLoop );
+ }
+
+ return this
+
+ },
+
+ stop: function() {
+ clearInterval( _interval )
+ _interval = false
+ return this
+ }
+
+ }
+
+ // jQuery plugin:
+
+ $.fn.tilesSlider = function( options ) {
+ var args = Array.prototype.slice.call( arguments, 1 )
+ return this.each(function() {
+ if ( typeof options === 'string' ) {
+ var plugin = $.data( this, 'tiles-slider' )
+ plugin[ options ].apply( plugin, args )
+ } else if ( !$.data(this, 'tiles-slider') ) {
+ $.data( this, 'tiles-slider', new TilesSlider( this, options ) )
+ }
+ })
+ }
+
+}( jQuery, window ))
View
1  js/min/jquery.tiles.min.js
@@ -0,0 +1 @@
+(function(e,t,n){function o(t,n){this.opts=e.extend({},i,n),this.klass="tiles-"+this.opts.effect,this.klassNormal=this.klass+"-normal",this.klassAnim=this.klass+"-anim",this.n_tiles=this.opts.x*this.opts.y,this.$container=e(t),this.$images=this.$container.find("img"),this.$tiles=null,this.opts.rewind&&(this.opts.fade=!0),this._init()}var r,i={x:4,y:4,slider:!1,effect:"default",fade:!1,random:!1,reverse:!1,limit:!1,rewind:!1,auto:!1,loop:!0,slideSpeed:2500,tileSpeed:1e3,cssSpeed:250},s={range:function(e,t,n){var r=(new Array(++t-e)).join(".").split(".").map(function(t,n){return e+n});return n?r.map(function(e){return[Math.random(),e]}).sort().map(function(e){return e[1]}):r}};o.prototype={_init:function(){var n=this,r=n.opts;if(!n.$images.length)return!1;n.$container.addClass("tiles-slider-wrap tiles-slider-"+r.effect+" tiles-slider-s"+r.cssSpeed),n.$images.each(function(){n._generateTiles(e(this))}),n.$wraps=n.$container.find(".tiles-wrap").detach(),n.$wraps.first().addClass("tiles-wrap-current").appendTo(n.$container),e("body").addClass("tiles-preload"),e(t).load(function(){e("body").removeClass("tiles-preload")}),r.auto&&n.start()},_generateTiles:function(t){var n=this,r=n.opts,i=[],s;for(var o=0;o<n.n_tiles;o++)i.push('<div class="tiles-tile '+n.klassNormal+'"/>');s=e(i.join("")),s.addClass("tiles-x"+r.x+" tiles-y"+r.y).filter(":odd").addClass("tiles-odd").end().filter(":even").addClass("tiles-even"),s.css({width:n.$container.width()/r.x,height:n.$container.height()/r.y,backgroundImage:"url("+t.attr("src")+")"}),e('<div class="tiles-wrap"/>').append(s).insertAfter(t.hide()),s.each(function(){var t=e(this),n=t.position();t.css("backgroundPosition",-n.left+"px "+ -n.top+"px")})},_animateTiles:function(t,n){n=n||e.noop;var r=this,i=r.opts,o=s.range(0,r.n_tiles,i.random),u=Math.floor(i.tileSpeed/r.n_tiles),a=o.length/(100/i.limit),f=i.tileSpeed+i.cssSpeed,l=t.find(".tiles-tile");i.reverse&&(o=o.reverse()),i.limit&&(i.reverse?o.splice(0,a):o.splice(a,o.length)),o.forEach(function(e,t){var n=l.eq(e),s=t*u;setTimeout(function(){n.addClass(r.klassAnim)},s),i.rewind&&(s+=i.cssSpeed/(100/i.rewind),setTimeout(function(){n.removeClass(r.klassAnim)},s))}),setTimeout(n,f)},_resetTiles:function(e){e.find(".tiles-tile").removeClass(this.klassAnim)},_getCurrentWrap:function(){return this.$wraps.filter(".tiles-wrap-current")},_getCurrentIdx:function(){return this.$wraps.index(this._getCurrentWrap())},_navigate:function(e,t){var n=this,r=n.opts,i=n._getCurrentWrap(),s=n.$wraps.eq(e);return n.$container.find(".tiles-wrap").removeClass("tiles-wrap-current"),s.addClass("tiles-wrap-current").prependTo(n.$container),r.fade&&s.fadeOut(1).fadeIn(r.tileSpeed),r.rewind&&i.fadeIn(1).delay(r.tileSpeed/2).fadeOut(r.tileSpeed),n._animateTiles(i,function(){i.remove(),n._resetTiles(i),t()}),this},prev:function(t){var n=this,r=n._getCurrentWrap(),i=r.is(n.$wraps.first()),s=i?n.$wraps.length-1:n._getCurrentIdx()-1;return this._navigate(s,t||e.noop)},next:function(t){var n=this,r=n._getCurrentWrap(),i=r.is(n.$wraps.last()),s=i?0:n._getCurrentIdx()+1;return this._navigate(s,t||e.noop)},start:function(){var e=this,t=e.opts,n=t.slideSpeed*(e.$wraps.length-1)+t.tileSpeed;return r&&e.stop().next(),r=setInterval(function(){e.next()},t.slideSpeed),t.loop||setTimeout(function(){e.stop()},n),this},stop:function(){return clearInterval(r),r=!1,this}},e.fn.tilesSlider=function(t){var n=Array.prototype.slice.call(arguments,1);return this.each(function(){if(typeof t=="string"){var r=e.data(this,"tiles-slider");r[t].apply(r,n)}else e.data(this,"tiles-slider")||e.data(this,"tiles-slider",new o(this,t))})}})(jQuery,window);
View
188 less/jquery.tiles.less
@@ -0,0 +1,188 @@
+/*-----------------------------------------------
+ * Mixins:
+ ----------------------------------------------*/
+
+.transition (@transition) {
+ -webkit-transition: @transition;
+ -moz-transition: @transition;
+ -ms-transition: @transition;
+ -o-transition: @transition;
+ transition: @transition;
+}
+.transform (@props) {
+ -webkit-transform: @props;
+ -moz-transform: @props;
+ -ms-transform: @props;
+ -o-transform: @props;
+ transform: @props;
+}
+.origin (@or) {
+ -webkit-transform-origin: @or;
+ -moz-transform-origin: @or;
+ -ms-transform-origin: @or;
+ -o-transform-origin: @or;
+ transform-origin: @or;
+}
+
+/*-----------------------------------------------
+ * Global:
+ ----------------------------------------------*/
+
+.tiles-preload .tiles-wrap * {
+ -webkit-transition: none !important;
+ -moz-transition: none !important;
+ -ms-transition: none !important;
+ -o-transition: none !important;
+ transition: none !important;
+}
+.tiles-slider-wrap,
+.tiles-tile { position: relative; }
+.tiles-wrap {
+ position: absolute;
+ height: 100%;
+ width: 100%;
+ -webkit-perspective: 1000px;
+ -moz-perspective: 1000px;
+ -ms-perspective: 1000px;
+ -o-perspective: 1000px;
+ perspective: 1000px;
+}
+.tiles-tile {
+ float: left;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ opacity: 1;
+ z-index: 0;
+ .transition(all .3s ease-in-out);
+}
+
+/* cssSpeed */
+.tiles-slider-s100 .tiles-tile { .transition(all .1s ease-in-out); }
+.tiles-slider-s200 .tiles-tile { .transition(all .2s ease-in-out); }
+.tiles-slider-s300 .tiles-tile { .transition(all .3s ease-in-out); }
+.tiles-slider-s400 .tiles-tile { .transition(all .4s ease-in-out); }
+.tiles-slider-s500 .tiles-tile { .transition(all .5s ease-in-out); }
+.tiles-slider-s600 .tiles-tile { .transition(all .6s ease-in-out); }
+.tiles-slider-s700 .tiles-tile { .transition(all .7s ease-in-out); }
+.tiles-slider-s800 .tiles-tile { .transition(all .8s ease-in-out); }
+.tiles-slider-s900 .tiles-tile { .transition(all .9s ease-in-out); }
+.tiles-slider-s1000 .tiles-tile { .transition(all 1s ease-in-out); }
+
+.tiles-tile.tiles-reset { .transition(all 0s ease-in-out); }
+
+/*-----------------------------------------------
+ * Effects:
+ ----------------------------------------------*/
+
+/* Simple */
+.tiles-simple-anim { opacity: 0; }
+
+/* Default */
+.tiles-default-anim {
+ position: relative;
+ opacity: 0;
+ box-shadow: 0 0 10px black;
+ top: -5%;
+ left: 5%;
+ z-index: 1;
+}
+
+/* Up */
+.tiles-y1.tiles-up-anim { height: 1px !important; }
+
+/* Left */
+.tiles-x1.tiles-left-normal { clear: both; }
+.tiles-x1.tiles-left-anim { width: 0 !important; }
+
+/* Switch LR */
+.tiles-switchlr-anim.tiles-even {
+ &.tiles-y1.tiles-x2 { left: 100/2%; }
+ &.tiles-y1.tiles-x4 { left: 100/4%; }
+ &.tiles-y1.tiles-x6 { left: 100/6%; }
+ &.tiles-y1.tiles-x8 { left: 100/8%; }
+ &.tiles-y1.tiles-x10 { left: 100/10%; }
+ &.tiles-y1.tiles-x12 { left: 100/12%; }
+ &.tiles-y1.tiles-x14 { left: 100/14%; }
+ &.tiles-y1.tiles-x16 { left: 100/16%; }
+ &.tiles-y1.tiles-x18 { left: 100/18%; }
+ &.tiles-y1.tiles-x20 { left: 100/20%; }
+}
+.tiles-switchlr-anim.tiles-odd {
+ &.tiles-y1.tiles-x2 { left: -100/2%; }
+ &.tiles-y1.tiles-x4 { left: -100/4%; }
+ &.tiles-y1.tiles-x6 { left: -100/6%; }
+ &.tiles-y1.tiles-x8 { left: -100/8%; }
+ &.tiles-y1.tiles-x10 { left: -100/10%; }
+ &.tiles-y1.tiles-x12 { left: -100/12%; }
+ &.tiles-y1.tiles-x14 { left: -100/14%; }
+ &.tiles-y1.tiles-x16 { left: -100/16%; }
+ &.tiles-y1.tiles-x18 { left: -100/18%; }
+ &.tiles-y1.tiles-x20 { left: -100/20%; }
+}
+
+/* Switch UD */
+.tiles-switchud-anim.tiles-even {
+ &.tiles-x1.tiles-y2 { top: 100/2%; }
+ &.tiles-x1.tiles-y4 { top: 100/4%; }
+ &.tiles-x1.tiles-y6 { top: 100/6%; }
+ &.tiles-x1.tiles-y8 { top: 100/8%; }
+ &.tiles-x1.tiles-y10 { top: 100/10%; }
+ &.tiles-x1.tiles-y12 { top: 100/12%; }
+ &.tiles-x1.tiles-y14 { top: 100/14%; }
+ &.tiles-x1.tiles-y16 { top: 100/16%; }
+ &.tiles-x1.tiles-y18 { top: 100/18%; }
+ &.tiles-x1.tiles-y20 { top: 100/20%; }
+}
+.tiles-switchud-anim.tiles-odd {
+ &.tiles-x1.tiles-y2 { top: -100/2%; }
+ &.tiles-x1.tiles-y4 { top: -100/4%; }
+ &.tiles-x1.tiles-y6 { top: -100/6%; }
+ &.tiles-x1.tiles-y8 { top: -100/8%; }
+ &.tiles-x1.tiles-y10 { top: -100/10%; }
+ &.tiles-x1.tiles-y12 { top: -100/12%; }
+ &.tiles-x1.tiles-y14 { top: -100/14%; }
+ &.tiles-x1.tiles-y16 { top: -100/16%; }
+ &.tiles-x1.tiles-y18 { top: -100/18%; }
+ &.tiles-x1.tiles-y20 { top: -100/20%; }
+}
+
+/* Flip */
+.tiles-fliplr-anim { .transform(~"rotateY(180deg)"); }
+.tiles-flipud-anim { .transform(~"rotateX(180deg)"); }
+
+/* Reduce */
+.tiles-reduce-anim { .transform(~"scale(0)"); }
+
+/* 360 */
+.tiles-360-anim { .transform(~"rotateZ(360deg) scale(0)"); }
+
+/* Left & Right */
+.tiles-leftright-anim.tiles-even { .transform(~"translate(50%, 0)"); }
+.tiles-leftright-anim.tiles-odd { .transform(~"translate(-50%, 0)"); }
+
+/* Up & Down */
+.tiles-updown-anim.tiles-even { .transform(~"translate(0, 50%)"); }
+.tiles-updown-anim.tiles-odd { .transform(~"translate(0, -50%)"); }
+
+/* Slider fixes */
+.tiles-slider-wrap {
+ .tiles-switchlr-anim,
+ .tiles-switchud-anim,
+ .tiles-fliplr-anim,
+ .tiles-y1.tiles-up-anim,
+ .tiles-x1.tiles-left-anim,
+ .tiles-updown-anim,
+ .tiles-leftright-anim,
+ .tiles-flipud-anim,
+ .tiles-reduce-anim {
+ opacity: 0;
+ visibility: hidden;
+ }
+}
+.tiles-slider-leftright .tiles-wrap,
+.tiles-slider-updown .tiles-wrap,
+.tiles-slider-360 .tiles-wrap {
+ overflow: hidden;
+}
View
3  node_modules/grunt-contrib-compress/.npmignore
@@ -0,0 +1,3 @@
+node_modules
+npm-debug.log
+tmp
View
3  node_modules/grunt-contrib-compress/.travis.yml
@@ -0,0 +1,3 @@
+language: node_js
+node_js:
+ - 0.8
View
3  node_modules/grunt-contrib-compress/AUTHORS
@@ -0,0 +1,3 @@
+Chris Talkington (http://christalkington.com/)
+Tyler Kellen (http://goingslowly.com/)
+Kyle Robinson Young (http://twitter.com/shamakry)
View
23 node_modules/grunt-contrib-compress/CHANGELOG
@@ -0,0 +1,23 @@
+v0.3.2:
+ date: 2012-10-12
+ changes:
+ - Rename grunt-contrib-lib dep to grunt-lib-contrib.
+v0.3.1:
+ date: 2012-10-09
+ changes:
+ - replace zipstream package.
+v0.3.0:
+ date: 2012-09-24
+ changes:
+ - General cleanup.
+ - Options no longer accepted from global config key.
+v0.2.2:
+ date: 2012-09-18
+ changes:
+ - Test refactoring.
+ - No valid source check.
+ - Automatic mode detection.
+v0.2.0:
+ date: 2012-09-10
+ changes:
+ - Refactored from grunt-contrib into individual repo.
View
22 node_modules/grunt-contrib-compress/LICENSE-MIT
@@ -0,0 +1,22 @@
+Copyright (c) 2012 Chris Talkington, contributors
+
+Permission is hereby granted, free of charge, to any person
+obtaining a copy of this software and associated documentation
+files (the "Software"), to deal in the Software without
+restriction, including without limitation the rights to use,
+copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
View
79 node_modules/grunt-contrib-compress/README.md
@@ -0,0 +1,79 @@
+# grunt-contrib-compress [![Build Status](https://secure.travis-ci.org/gruntjs/grunt-contrib-compress.png?branch=master)](http://travis-ci.org/gruntjs/grunt-contrib-compress)
+
+> Compress files and folders.
+
+## Getting Started
+Install this grunt plugin next to your project's [grunt.js gruntfile][getting_started] with: `npm install grunt-contrib-compress`
+
+Then add this line to your project's `grunt.js` gruntfile:
+
+```javascript
+grunt.loadNpmTasks('grunt-contrib-compress');
+```
+
+[grunt]: https://github.com/gruntjs/grunt
+[getting_started]: https://github.com/gruntjs/grunt/blob/master/docs/getting_started.md
+
+### Overview
+
+Inside your `grunt.js` file, add a section named `compress`. This section specifies the files to compress and the options passed to either [zipstream](https://github.com/wellawaretech/node-zipstream) (for zip) or [tar](https://github.com/isaacs/node-tar) (for tar/tgz) or [zlib](http://nodejs.org/api/zlib.html#zlib_options) (for gzip).
+
+#### Parameters
+
+##### files ```object```
+
+This defines what files this task will compress and should contain key:value pairs.
+
+The key (destination) should be an unique filepath (supports [grunt.template](https://github.com/gruntjs/grunt/blob/master/docs/api_template.md)) and the value (source) should be a filepath or an array of filepaths (supports [minimatch](https://github.com/isaacs/minimatch)).
+
+##### options ```object```
+
+This controls how this task operates and should contain key:value pairs, see options below.
+
+#### Options
+
+##### mode ```string```
+
+This is used to define which mode to use, currently supports gzip, tar, tgz (tar gzip) and zip.
+
+As of v0.3.0, this is now automatically detected per dest:src pair but can be overridden per target if desired.
+
+##### basePath ```string```
+
+This option adjusts internal filenames to be relative to provided path, within the resulting archive file.
+
+This has been automatically detected per dest:src pair for some time now but can be overridden per target if desired.
+
+##### flatten ```boolean```
+
+This option performs a flat copy that dumps all the files into the root of the destination file, overwriting files if they exist.
+
+##### level ```integer``` (zip only)
+
+This option sets the level of archive compression (defaults to 1).
+
+> Currently, gzip compression related options are not supported due to deficiencies in node's zlib library.
+
+##### rootDir ```string```
+
+This option allows the creation of a root folder to contain files within the resulting archive file.
+
+#### Config Example
+
+``` javascript
+compress: {
+ zip: {
+ files: {
+ "path/to/result.zip": "path/to/source/*", // includes files in dir
+ "path/to/another.tar": "path/to/source/**", // includes files in dir and subdirs
+ "path/to/final.tgz": ["path/to/sources/*.js", "path/to/more/*.js"], // include JS files in two diff dirs
+ "path/to/single.gz": "path/to/source/single.js", // gzip a single file
+ "path/to/project-<%= pkg.version %>.zip": "path/to/source/**" // variables in destination
+ }
+ }
+}
+```
+
+--
+
+*Task submitted by [Chris Talkington](https://github.com/ctalkington).*
View
13 node_modules/grunt-contrib-compress/docs/examples.md
@@ -0,0 +1,13 @@
+``` javascript
+compress: {
+ zip: {
+ files: {
+ "path/to/result.zip": "path/to/source/*", // includes files in dir
+ "path/to/another.tar": "path/to/source/**", // includes files in dir and subdirs
+ "path/to/final.tgz": ["path/to/sources/*.js", "path/to/more/*.js"], // include JS files in two diff dirs
+ "path/to/single.gz": "path/to/source/single.js", // gzip a single file
+ "path/to/project-<%= pkg.version %>.zip": "path/to/source/**" // variables in destination
+ }
+ }
+}
+```
View
37 node_modules/grunt-contrib-compress/docs/options.md
@@ -0,0 +1,37 @@
+##### files ```object```
+
+This defines what files this task will compress and should contain key:value pairs.
+
+The key (destination) should be an unique filepath (supports [grunt.template](https://github.com/gruntjs/grunt/blob/master/docs/api_template.md)) and the value (source) should be a filepath or an array of filepaths (supports [minimatch](https://github.com/isaacs/minimatch)).
+
+##### options ```object```
+
+This controls how this task operates and should contain key:value pairs, see options below.
+
+#### Options
+
+##### mode ```string```
+
+This is used to define which mode to use, currently supports gzip, tar, tgz (tar gzip) and zip.
+
+As of v0.3.0, this is now automatically detected per dest:src pair but can be overridden per target if desired.
+
+##### basePath ```string```
+
+This option adjusts internal filenames to be relative to provided path, within the resulting archive file.
+
+This has been automatically detected per dest:src pair for some time now but can be overridden per target if desired.
+
+##### flatten ```boolean```
+
+This option performs a flat copy that dumps all the files into the root of the destination file, overwriting files if they exist.
+
+##### level ```integer``` (zip only)
+
+This option sets the level of archive compression (defaults to 1).
+
+> Currently, gzip compression related options are not supported due to deficiencies in node's zlib library.
+
+##### rootDir ```string```
+
+This option allows the creation of a root folder to contain files within the resulting archive file.
View
4 node_modules/grunt-contrib-compress/docs/overview.md
@@ -0,0 +1,4 @@
+Node Libraries Used:
+[zipstream](https://github.com/wellawaretech/node-zipstream) (for zip)
+[tar](https://github.com/isaacs/node-tar) (for tar/tgz)
+[zlib](http://nodejs.org/api/zlib.html#zlib_options) (for gzip).
View
112 node_modules/grunt-contrib-compress/grunt.js
@@ -0,0 +1,112 @@
+/*
+ * grunt-contrib-compress
+ * http://gruntjs.com/
+ *
+ * Copyright (c) 2012 Chris Talkington, contributors
+ * Licensed under the MIT license.
+ */
+
+module.exports = function(grunt) {
+ 'use strict';
+
+ // Project configuration.
+ grunt.initConfig({
+ test_vars: {
+ name: 'grunt-contrib-compress',
+ version: '0.1.0'
+ },
+
+ lint: {
+ all: ['grunt.js', 'tasks/*.js', '<config:nodeunit.tasks>']
+ },
+
+ jshint: {
+ options: {
+ curly: true,
+ eqeqeq: true,
+ immed: true,
+ latedef: true,
+ newcap: true,
+ noarg: true,
+ sub: true,
+ undef: true,
+ boss: true,
+ eqnull: true,
+ node: true,
+ es5: true
+ }
+ },
+
+ // Before generating any new files, remove any previously-created files.
+ clean: {
+ test: ['tmp']
+ },
+
+ files: {
+ compress_test: 'test/fixtures/folder_one'
+ },
+
+ // Configuration to be run (and then tested).
+ compress: {
+ main: {
+ files: {
+ 'tmp/compress_test_files.zip': ['test/fixtures/*'],
+ 'tmp/compress_test_v<%= test_vars.version %>.zip': ['test/fixtures/**'],
+ 'tmp/compress_test_files_template.zip': ['<%= files.compress_test %>/**'],
+
+ 'tmp/compress_test_files.tar': ['test/fixtures/*'],
+ 'tmp/compress_test_v<%= test_vars.version %>.tar': ['test/fixtures/**'],
+ 'tmp/compress_test_files_template.tar': ['<%= files.compress_test %>/**'],
+
+ 'tmp/compress_test_files.tgz': ['test/fixtures/*'],
+ 'tmp/compress_test_v<%= test_vars.version %>.tgz': ['test/fixtures/**'],
+ 'tmp/compress_test_files_template.tgz': ['<%= files.compress_test %>/**'],
+
+ 'tmp/compress_test_file.gz': ['test/fixtures/test.js'],
+ 'tmp/compress_test_file2.gz': ['test/fixtures/folder_one/one.js']
+ }
+ },
+
+ flatten: {
+ options: {
+ flatten: true
+ },
+ files: {
+ 'tmp/compress_test_flatten.zip': ['test/fixtures/**'],
+ 'tmp/compress_test_flatten.tar': ['test/fixtures/**'],
+ 'tmp/compress_test_flatten.tgz': ['test/fixtures/**']
+ }
+ },
+
+ rootdir: {
+ options: {
+ rootDir: 'abc123'
+ },
+ files: {
+ 'tmp/compress_test_rootdir.zip': ['test/fixtures/**'],
+ 'tmp/compress_test_rootdir.tar': ['test/fixtures/**'],
+ 'tmp/compress_test_rootdir.tgz': ['test/fixtures/**']
+ }
+ }
+ },
+
+ // Unit tests.
+ nodeunit: {
+ tasks: ['test/*_test.js']
+ }
+ });
+
+ // Actually load this plugin's task(s).
+ grunt.loadTasks('tasks');
+
+ // The clean plugin helps in testing.
+ grunt.loadNpmTasks('grunt-contrib-clean');
+
+ // Whenever the "test" task is run, first clean the "tmp" dir, then run this
+ // plugin's task(s), then test the result.
+ grunt.renameTask('test', 'nodeunit');
+ grunt.registerTask('test', 'clean compress nodeunit');
+
+ // By default, lint and run all tests.
+ grunt.registerTask('default', 'lint test');
+};
View
3  node_modules/grunt-contrib-compress/node_modules/archiver/.npmignore
@@ -0,0 +1,3 @@
+npm-debug.log
+node_modules/
+tmp/
View
4 node_modules/grunt-contrib-compress/node_modules/archiver/.travis.yml
@@ -0,0 +1,4 @@
+language: node_js
+node_js:
+ - 0.8
+ - 0.6
View
5 node_modules/grunt-contrib-compress/node_modules/archiver/CHANGELOG
@@ -0,0 +1,5 @@
+v0.1.0:
+ date: 2012-10-09
+ changes:
+ - First release.
+ - Import ZipStream logic.
View
22 node_modules/grunt-contrib-compress/node_modules/archiver/LICENSE-MIT
@@ -0,0 +1,22 @@
+Copyright (c) 2012 Chris Talkington, contributors.
+
+Permission is hereby granted, free of charge, to any person
+obtaining a copy of this software and associated documentation
+files (the "Software"), to deal in the Software without
+restriction, including without limitation the rights to use,
+copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
View
59 node_modules/grunt-contrib-compress/node_modules/archiver/README.md
@@ -0,0 +1,59 @@
+# Archiver [![Build Status](https://secure.travis-ci.org/ctalkington/node-archiver.png?branch=master)](http://travis-ci.org/ctalkington/node-archiver)
+
+Creates Archives (ZIP) via Node Streams. Depends on Node's build-in zlib module for compression available since version 0.6.3.
+
+## Install
+
+```bash
+npm install archiver
+```
+
+## API
+
+#### createZip(options)
+
+Creates an Archiver ZIP object. Options are passed to zlib.
+
+#### archive.addFile(inputStream, options, callback)
+
+Adds a file to the Archiver stream. At this moment, options must contain "name". If the "store" option is set to true, the file will be added uncompressed.
+
+#### archive.finalize(callback(written))
+
+Finalizes the Archiver stream. When everything is done, callback is called with the total number of bytes in the archive.
+
+## Example
+```javascript
+var fs = require('fs');
+
+var archiver = require('archiver');
+
+var out = fs.createWriteStream('out.zip');
+var zip = archiver.createZip({ level: 1 });
+
+zip.pipe(out);
+
+zip.addFile(fs.createReadStream('file1.js'), { name: 'file1.js' }, function() {
+ zip.addFile(fs.createReadStream('file2.js'), { name: 'file2.js' }, function() {
+ zip.finalize(function(written) { console.log(written + ' total bytes written'); });
+ });
+});
+```
+
+## Contributing
+
+#### Code Style Guide
+
+* code should be indented with 2 spaces
+* single quotes should be used where feasible
+* commas should be followed by a single space (function params, etc)
+* variable declaration should include `var`, [no multiple declarations](http://benalman.com/news/2012/05/multiple-var-statements-javascript/)
+
+#### Tests
+
+* tests should be added to the nodeunit config in `test/tests.js`
+* tests can be run with `npm test`
+* see existing tests for guidance
+
+## Credits
+Originally inspired by Antoine van Wel's [node-zipstream](https://github.com/wellawaretech/node-zipstream).
View
293 node_modules/grunt-contrib-compress/node_modules/archiver/lib/archiver.js
@@ -0,0 +1,293 @@
+/*
+ * node-archiver
+ *
+ * Copyright (c) 2012 Chris Talkington, contributors.
+ * Licensed under the MIT license.
+ * https://github.com/ctalkington/node-archiver/blob/master/LICENSE-MIT
+ */
+
+var stream = require('stream');
+var util = require('util');
+var zlib = require('zlib');
+
+var crc32 = require('./util/crc32');
+
+function Archiver(opt) {
+ var self = this;
+
+ self.readable = true;
+ self.paused = false;
+ self.busy = false;
+ self.eof = false;
+
+ self.queue = [];
+ self.fileptr = 0;
+ self.files = [];
+ self.options = opt;
+}
+
+util.inherits(Archiver, stream.Stream);
+
+exports.createZip = function(opt) {
+ return new Archiver(opt);
+};
+
+// converts datetime to DOS format
+function convertDate(d) {
+ var year = d.getFullYear();
+
+ if (year < 1980) {
+ return (1<<21) | (1<<16);
+ }
+ return ((year-1980) << 25) | ((d.getMonth()+1) << 21) | (d.getDate() << 16) |
+ (d.getHours() << 11) | (d.getMinutes() << 5) | (d.getSeconds() >> 1);
+}
+
+
+Archiver.prototype.pause = function() {
+ var self = this;
+ self.paused = true;
+};
+
+Archiver.prototype.resume = function() {
+ var self = this;
+ self.paused = false;
+
+ self._read();
+};
+
+Archiver.prototype.destroy = function() {
+ var self = this;
+ self.readable = false;
+};
+
+Archiver.prototype._read = function() {
+ var self = this;
+
+ if (!self.readable || self.paused) { return; }
+
+ if (self.queue.length > 0) {
+ var data = self.queue.shift();
+ self.emit('data', data);
+ }
+
+ if (self.eof && self.queue.length === 0) {
+ self.emit('end');
+ self.readable = false;
+
+ if (self.callback) {
+ self.callback(self.fileptr);
+ }
+ }
+
+ process.nextTick(function() { self._read(); }); //TODO improve
+};
+
+Archiver.prototype.finalize = function(callback) {
+ var self = this;
+
+ if (self.files.length === 0) {
+ self.emit('error', 'no files in zip');
+ return;
+ }
+
+ self.callback = callback;
+ self._pushCentralDirectory();
+ self.eof = true;
+};
+
+Archiver.prototype._addFileStore = function(source, file, callback) {
+ // placeholder
+};
+
+Archiver.prototype._addFileDeflate = function(source, file, callback) {
+ // placeholder
+};
+
+Archiver.prototype.addFile = function(source, file, callback) {
+ var self = this;
+
+ if (self.busy) {
+ self.emit('error', 'previous file not finished');
+ return;
+ }
+
+ if (typeof source === 'string') {
+ source = new Buffer(source, 'utf-8');
+ }
+
+ self.busy = true;
+ self.file = file;
+ self._pushLocalFileHeader(file);
+
+ var checksum = crc32.createCRC32();
+ file.uncompressed = 0;
+ file.compressed = 0;
+
+ function onEnd() {
+ file.crc32 = checksum.digest();
+ if (file.store) { file.compressed = file.uncompressed; }
+
+ self.fileptr += file.compressed;
+ self._pushDataDescriptor(file);
+
+ self.files.push(file);
+ self.busy = false;
+ callback();
+ }
+
+ function update(chunk) {
+ checksum.update(chunk);
+ file.uncompressed += chunk.length;
+ }
+
+ if (file.store) {
+ if (Buffer.isBuffer(source)) {
+ update(source);
+
+ self.queue.push(source);
+ process.nextTick(onEnd);
+ } else {
+ // Assume stream
+ source.on('data', function(chunk) {
+ update(chunk);
+ self.queue.push(chunk);
+ });
+
+ source.on('end', onEnd);
+ }
+ } else {
+ var deflate = zlib.createDeflateRaw(self.options);
+
+ deflate.on('data', function(chunk) {
+ file.compressed += chunk.length;
+ self.queue.push(chunk);
+ });
+
+ deflate.on('end', onEnd);
+
+ if (Buffer.isBuffer(source)) {
+ update(source);
+ deflate.write(source);
+ deflate.end();
+ } else {
+ // Assume stream
+ source.on('data', function(chunk) {
+ update(chunk);
+ deflate.write(chunk); //TODO check for false & wait for drain
+ });
+ source.on('end', function() {
+ deflate.end();
+ });
+ }
+ }
+
+ process.nextTick(function() { self._read(); });
+};
+
+// TODO remove listeners on end
+
+// local file header
+Archiver.prototype._pushLocalFileHeader = function(file) {
+ var self = this;
+
+ file.version = 20;
+ file.bitflag = (1<<3) | (1<<11);
+ file.method = file.store ? 0 : 8;
+ if (!file.date) { file.date = new Date(); }
+ file.moddate = convertDate(file.date);
+ file.offset = self.fileptr;
+
+ var buf = new Buffer(1024);
+ var len;
+
+ buf.writeUInt32LE(0x04034b50, 0); // local file header signature
+ buf.writeUInt16LE(file.version, 4); // version needed to extract
+ buf.writeUInt16LE(file.bitflag, 6); // general purpose bit flag
+ buf.writeUInt16LE(file.method, 8); // compression method
+ buf.writeUInt32LE(file.moddate, 10); // last mod file date and time
+ buf.writeInt32LE(0, 14); // crc32
+ buf.writeUInt32LE(0, 18); // compressed size
+ buf.writeUInt32LE(0, 22); // uncompressed size
+
+ buf.writeUInt16LE(0, 28); // extra field length
+ len = buf.write(file.name, 30); // file name
+ buf.writeUInt16LE(len, 26); // file name length
+
+ len += 30;
+ self.queue.push(buf.slice(0, len));
+ self.fileptr += len;
+};
+
+Archiver.prototype._pushDataDescriptor = function(file) {
+ var self = this;
+
+ var buf = new Buffer(16);
+ buf.writeUInt32LE(0x08074b50, 0); // data descriptor record signature
+ buf.writeInt32LE(file.crc32, 4); // crc-32
+ buf.writeUInt32LE(file.compressed, 8); // compressed size
+ buf.writeUInt32LE(file.uncompressed, 12); // uncompressed size
+
+ self.queue.push(buf);
+ self.fileptr += buf.length;
+};
+
+Archiver.prototype._pushCentralDirectory = function() {
+ var self = this;
+ var cdoffset = self.fileptr;
+
+ var ptr = 0;
+ var cdsize = 0;
+
+ var len, buf;
+
+ for (var i=0; i<self.files.length; i++) {
+ var file = self.files[i];
+
+ buf = new Buffer(1024);
+
+ // central directory file header
+ buf.writeUInt32LE(0x02014b50, 0); // central file header signature
+ buf.writeUInt16LE(file.version, 4); // TODO version made by
+ buf.writeUInt16LE(file.version, 6); // version needed to extract
+ buf.writeUInt16LE(file.bitflag, 8); // general purpose bit flag
+ buf.writeUInt16LE(file.method, 10); // compression method
+ buf.writeUInt32LE(file.moddate, 12); // last mod file time and date
+ buf.writeInt32LE(file.crc32, 16); // crc-32
+ buf.writeUInt32LE(file.compressed, 20); // compressed size
+ buf.writeUInt32LE(file.uncompressed, 24); // uncompressed size
+
+ buf.writeUInt16LE(0, 30); // extra field length
+ buf.writeUInt16LE(0, 32); // file comment length
+ buf.writeUInt16LE(0, 34); // disk number where file starts
+ buf.writeUInt16LE(0, 36); // internal file attributes
+ buf.writeUInt32LE(0, 38); // external file attributes
+ buf.writeUInt32LE(file.offset, 42); // relative offset
+ len = buf.write(file.name, 46); // file name
+ buf.writeUInt16LE(len, 28); // file name length
+
+ len += 46;
+ ptr = ptr + len;
+ self.queue.push(buf.slice(0, len));
+ }
+
+ cdsize = ptr;
+
+ // end of central directory record
+ len = 22;
+ buf = new Buffer(len);
+
+ buf.writeUInt32LE(0x06054b50, 0); // end of central dir signature
+ buf.writeUInt16LE(0, 4); // number of this disk
+ buf.writeUInt16LE(0, 6); // disk where central directory starts
+ buf.writeUInt16LE(self.files.length, 8); // number of central directory records on this disk
+ buf.writeUInt16LE(self.files.length, 10); // total number of central directory records
+ buf.writeUInt32LE(cdsize, 12); // size of central directory in bytes
+ buf.writeUInt32LE(cdoffset, 16); // offset of start of central directory, relative to start of archive
+ buf.writeUInt16LE(0, 20); // comment length
+
+ ptr = ptr + len;
+
+ self.queue.push(buf);
+ self.fileptr += ptr;
+};
View
86 node_modules/grunt-contrib-compress/node_modules/archiver/lib/util/crc32.js
@@ -0,0 +1,86 @@
+// crc32 functionality for zip
+
+exports.createCRC32 = function() {
+ return new CRC32();
+};
+
+function CRC32() {
+ this.crc = ~0;
+}
+
+CRC32.prototype.update = function(buf) {
+ for (var i=0; i<buf.length; i++) {
+ this.crc = (this.crc >>> 8) ^ lookup[(this.crc ^ buf[i]) & 0xff];
+ }
+};
+
+CRC32.prototype.digest = function() {
+ return this.crc ^ -1;
+};
+
+var lookup = [
+ 0x00000000, 0x77073096, 0xee0e612c, 0x990951ba,
+ 0x076dc419, 0x706af48f, 0xe963a535, 0x9e6495a3,
+ 0x0edb8832, 0x79dcb8a4, 0xe0d5e91e, 0x97d2d988,
+ 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, 0x90bf1d91,
+ 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de,
+ 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7,
+ 0x136c9856, 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec,
+ 0x14015c4f, 0x63066cd9, 0xfa0f3d63, 0x8d080df5,
+ 0x3b6e20c8, 0x4c69105e, 0xd56041e4, 0xa2677172,
+ 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b,
+ 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940,
+ 0x32d86ce3, 0x45df5c75, 0xdcd60dcf, 0xabd13d59,
+ 0x26d930ac, 0x51de003a, 0xc8d75180, 0xbfd06116,
+ 0x21b4f4b5, 0x56b3c423, 0xcfba9599, 0xb8bda50f,
+ 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924,
+ 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d,
+ 0x76dc4190, 0x01db7106, 0x98d220bc, 0xefd5102a,
+ 0x71b18589, 0x06b6b51f, 0x9fbfe4a5, 0xe8b8d433,
+ 0x7807c9a2, 0x0f00f934, 0x9609a88e, 0xe10e9818,
+ 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01,
+ 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e,
+ 0x6c0695ed, 0x1b01a57b, 0x8208f4c1, 0xf50fc457,
+ 0x65b0d9c6, 0x12b7e950, 0x8bbeb8ea, 0xfcb9887c,
+ 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, 0xfbd44c65,
+ 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2,
+ 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb,
+ 0x4369e96a, 0x346ed9fc, 0xad678846, 0xda60b8d0,
+ 0x44042d73, 0x33031de5, 0xaa0a4c5f, 0xdd0d7cc9,
+ 0x5005713c, 0x270241aa, 0xbe0b1010, 0xc90c2086,
+ 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f,
+ 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4,
+ 0x59b33d17, 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad,
+ 0xedb88320, 0x9abfb3b6, 0x03b6e20c, 0x74b1d29a,
+ 0xead54739, 0x9dd277af, 0x04db2615, 0x73dc1683,
+ 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8,
+ 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1,
+ 0xf00f9344, 0x8708a3d2, 0x1e01f268, 0x6906c2fe,
+ 0xf762575d, 0x806567cb, 0x196c3671, 0x6e6b06e7,
+ 0xfed41b76, 0x89d32be0, 0x10da7a5a, 0x67dd4acc,
+ 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5,
+ 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252,
+ 0xd1bb67f1, 0xa6bc5767, 0x3fb506dd, 0x48b2364b,
+ 0xd80d2bda, 0xaf0a1b4c, 0x36034af6, 0x41047a60,
+ 0xdf60efc3, 0xa867df55, 0x316e8eef, 0x4669be79,
+ 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236,
+ 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f,
+ 0xc5ba3bbe, 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04,
+ 0xc2d7ffa7, 0xb5d0cf31, 0x2cd99e8b, 0x5bdeae1d,
+ 0x9b64c2b0, 0xec63f226, 0x756aa39c, 0x026d930a,
+ 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713,
+ 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38,
+ 0x92d28e9b, 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21,
+ 0x86d3d2d4, 0xf1d4e242, 0x68ddb3f8, 0x1fda836e,
+ 0x81be16cd, 0xf6b9265b, 0x6fb077e1, 0x18b74777,
+ 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c,
+ 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45,
+ 0xa00ae278, 0xd70dd2ee, 0x4e048354, 0x3903b3c2,
+ 0xa7672661, 0xd06016f7, 0x4969474d, 0x3e6e77db,
+ 0xaed16a4a, 0xd9d65adc, 0x40df0b66, 0x37d83bf0,
+ 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9,
+ 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6,
+ 0xbad03605, 0xcdd70693, 0x54de5729, 0x23d967bf,
+ 0xb3667a2e, 0xc4614ab8, 0x5d681b02, 0x2a6f2b94,
+ 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, 0x2d02ef8d
+];
View
42 node_modules/grunt-contrib-compress/node_modules/archiver/package.json
@@ -0,0 +1,42 @@
+{
+ "name": "archiver",
+ "version": "0.1.0",
+ "description": "Creates Archives (ZIP) via Node Streams.",
+ "homepage": "https://github.com/ctalkington/node-archiver",
+ "author": {
+ "name": "Chris Talkington",
+ "url": "http://christalkington.com/"
+ },
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/ctalkington/node-archiver.git"
+ },
+ "bugs": {
+ "url": "https://github.com/ctalkington/node-archiver/issues"
+ },
+ "licenses": [
+ {
+ "type": "MIT",
+ "url": "https://github.com/ctalkington/node-archiver/blob/master/LICENSE-MIT"
+ }
+ ],
+ "main": "lib/archiver.js",
+ "engines": {
+ "node": ">= 0.6.3"
+ },
+ "scripts": {
+ "test": "nodeunit --reporter=minimal test/tests.js"
+ },
+ "dependencies": {},
+ "devDependencies": {
+ "nodeunit": "~0.7.4"
+ },
+ "keywords": [
+ "archive",
+ "archiver",
+ "zip"
+ ],
+ "readme": "# Archiver [![Build Status](https://secure.travis-ci.org/ctalkington/node-archiver.png?branch=master)](http://travis-ci.org/ctalkington/node-archiver)\r\n\r\nCreates Archives (ZIP) via Node Streams. Depends on Node's build-in zlib module for compression available since version 0.6.3.\r\n\r\n## Install\r\n\r\n```bash\r\nnpm install archiver\r\n```\r\n\r\n## API\r\n\r\n#### createZip(options)\r\n\r\nCreates an Archiver ZIP object. Options are passed to zlib.\r\n\r\n#### archive.addFile(inputStream, options, callback)\r\n\r\nAdds a file to the Archiver stream. At this moment, options must contain \"name\". If the \"store\" option is set to true, the file will be added uncompressed.\r\n\r\n#### archive.finalize(callback(written))\r\n\r\nFinalizes the Archiver stream. When everything is done, callback is called with the total number of bytes in the archive.\r\n\r\n## Example\r\n```javascript\r\nvar fs = require('fs');\r\n\r\nvar archiver = require('archiver');\r\n\r\nvar out = fs.createWriteStream('out.zip');\r\nvar zip = archiver.createZip({ level: 1 });\r\n\r\nzip.pipe(out);\r\n\r\nzip.addFile(fs.createReadStream('file1.js'), { name: 'file1.js' }, function() {\r\n zip.addFile(fs.createReadStream('file2.js'), { name: 'file2.js' }, function() {\r\n zip.finalize(function(written) { console.log(written + ' total bytes written'); });\r\n });\r\n});\r\n```\r\n\r\n## Contributing\r\n\r\n#### Code Style Guide\r\n\r\n* code should be indented with 2 spaces\r\n* single quotes should be used where feasible\r\n* commas should be followed by a single space (function params, etc)\r\n* variable declaration should include `var`, [no multiple declarations](http://benalman.com/news/2012/05/multiple-var-statements-javascript/)\r\n\r\n#### Tests\r\n\r\n* tests should be added to the nodeunit config in `test/tests.js`\r\n* tests can be run with `npm test`\r\n* see existing tests for guidance\r\n\r\n## Credits\r\nOriginally inspired by Antoine van Wel's [node-zipstream](https://github.com/wellawaretech/node-zipstream).",
+ "_id": "archiver@0.1.0",
+ "_from": "archiver@~0.1.0"
+}
View
61 node_modules/grunt-contrib-compress/node_modules/archiver/test/tests.js
@@ -0,0 +1,61 @@
+var crypto = require('crypto');
+
+var archiver = require('../lib/archiver');
+
+module.exports = {
+ buffer: function(test) {
+ test.expect(1);
+
+ var hash = crypto.createHash('sha1');
+ var zip = archiver.createZip({level: 1});
+
+ // create a buffer and fill it
+ var buf = new Buffer(20000);
+
+ for (var i = 0; i < 20000; i++) {
+ buf.writeUInt8(i&255, i);
+ }
+
+ zip.addFile(buf, {name: 'buffer.out', date: new Date('April 13, 2011 CET')}, function() {
+ zip.finalize();
+ });
+
+ zip.on('data', function(data) {
+ hash.update(data);
+ });
+
+ zip.on('end', function() {
+ var digest = hash.digest('hex');
+ test.equals(digest, '5641d2b95f2cadaabcc22a7d646bfd41036c347d', 'data hex values should match.');
+ test.done();
+ });
+ },
+
+ store: function(test) {
+ test.expect(1);
+
+ var hash = crypto.createHash('sha1');
+ var zip = archiver.createZip({level: 1});
+
+ // create a buffer and fill it
+ var buf = new Buffer(20000);
+
+ for (var i = 0; i < 20000; i++) {
+ buf.writeUInt8(i&255, i);
+ }
+
+ zip.addFile(buf, {name: 'buffer.out', date: new Date('April 13, 2011 CET'), store: true}, function() {
+ zip.finalize();
+ });
+
+ zip.on('data', function(data) {
+ hash.update(data);
+ });
+
+ zip.on('end', function() {
+ var digest = hash.digest('hex');
+ test.equals(digest, 'a777c51ca558e9a2ff36f1f9b7fc70b95560df28', 'data hex values should match.');
+ test.done();
+ });
+ }
+};
View
5 node_modules/grunt-contrib-compress/node_modules/fstream/.npmignore
@@ -0,0 +1,5 @@
+.*.swp
+node_modules/
+examples/deep-copy/
+examples/path/
+examples/filter-copy/
View
3  node_modules/grunt-contrib-compress/node_modules/fstream/.travis.yml
@@ -0,0 +1,3 @@
+language: node_js
+node_js:
+ - 0.6
View
25 node_modules/grunt-contrib-compress/node_modules/fstream/LICENCE
@@ -0,0 +1,25 @@
+Copyright (c) Isaac Z. Schlueter
+All rights reserved.
+
+The BSD License
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+1. Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+2. Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
+``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
+BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
View
76 node_modules/grunt-contrib-compress/node_modules/fstream/README.md
<
@@ -0,0 +1,76 @@
+Like FS streams, but with stat on them, and supporting directories and
+symbolic links, as well as normal files. Also, you can use this to set
+the stats on a file, even if you don't change its contents, or to create
+a symlink, etc.
+
+So, for example, you can "write" a directory, and it'll call `mkdir`. You
+can specify a uid and gid, and it'll call `chown`. You can specify a
+`mtime` and `atime`, and it'll call `utimes`. You can call it a symlink
+and provide a `linkpath` and it'll call `symlink`.
+
+Note that it won't automatically resolve symbolic links. So, if you
+call `fstream.Reader('/some/symlink')` then you'll get an object
+that stats and then ends immediately (since it has no data). To follow
+symbolic links, do this: `fstream.Reader({path:'/some/symlink', follow:
+true })`.
+
+There are various checks to make sure that the bytes emitted are the
+same as the intended size, if the size is set.
+
+## Examples
+
+```javascript
+fstream
+ .Writer({ path: "path/to/file"