solvas-jsduck 6.0.0.beta.1888

Sign up to get free protection for your applications and to get access to all the features.
Files changed (659) hide show
  1. checksums.yaml +7 -0
  2. data/COPYING +674 -0
  3. data/README.md +115 -0
  4. data/bin/solvas-jsduck +27 -0
  5. data/js-classes/Array.js +1054 -0
  6. data/js-classes/Boolean.js +110 -0
  7. data/js-classes/Date.js +1022 -0
  8. data/js-classes/Function.js +336 -0
  9. data/js-classes/Number.js +308 -0
  10. data/js-classes/Object.js +1042 -0
  11. data/js-classes/RegExp.js +415 -0
  12. data/js-classes/String.js +1052 -0
  13. data/lib/jsduck/aggregator.rb +200 -0
  14. data/lib/jsduck/app.rb +63 -0
  15. data/lib/jsduck/assets.rb +54 -0
  16. data/lib/jsduck/base_type.rb +53 -0
  17. data/lib/jsduck/batch_parser.rb +46 -0
  18. data/lib/jsduck/batch_processor.rb +83 -0
  19. data/lib/jsduck/cache.rb +137 -0
  20. data/lib/jsduck/categories/auto.rb +83 -0
  21. data/lib/jsduck/categories/class_name.rb +39 -0
  22. data/lib/jsduck/categories/factory.rb +75 -0
  23. data/lib/jsduck/categories/file.rb +69 -0
  24. data/lib/jsduck/class.rb +218 -0
  25. data/lib/jsduck/class_doc_expander.rb +132 -0
  26. data/lib/jsduck/class_name.rb +23 -0
  27. data/lib/jsduck/class_writer.rb +53 -0
  28. data/lib/jsduck/columns.rb +56 -0
  29. data/lib/jsduck/css/parser.rb +90 -0
  30. data/lib/jsduck/css/type.rb +57 -0
  31. data/lib/jsduck/doc/comment.rb +40 -0
  32. data/lib/jsduck/doc/delimited_parser.rb +105 -0
  33. data/lib/jsduck/doc/map.rb +23 -0
  34. data/lib/jsduck/doc/parser.rb +135 -0
  35. data/lib/jsduck/doc/processor.rb +52 -0
  36. data/lib/jsduck/doc/scanner.rb +83 -0
  37. data/lib/jsduck/doc/standard_tag_parser.rb +125 -0
  38. data/lib/jsduck/doc/subproperties.rb +71 -0
  39. data/lib/jsduck/examples.rb +63 -0
  40. data/lib/jsduck/export_writer.rb +63 -0
  41. data/lib/jsduck/exporter/app.rb +80 -0
  42. data/lib/jsduck/exporter/examples.rb +58 -0
  43. data/lib/jsduck/exporter/full.rb +60 -0
  44. data/lib/jsduck/external_classes.rb +362 -0
  45. data/lib/jsduck/format/batch.rb +58 -0
  46. data/lib/jsduck/format/class.rb +62 -0
  47. data/lib/jsduck/format/doc.rb +172 -0
  48. data/lib/jsduck/format/html_stack.rb +108 -0
  49. data/lib/jsduck/format/shortener.rb +55 -0
  50. data/lib/jsduck/format/subproperties.rb +64 -0
  51. data/lib/jsduck/grouped_asset.rb +59 -0
  52. data/lib/jsduck/guide_anchors.rb +39 -0
  53. data/lib/jsduck/guide_toc.rb +68 -0
  54. data/lib/jsduck/guide_toc_entry.rb +54 -0
  55. data/lib/jsduck/guide_writer.rb +58 -0
  56. data/lib/jsduck/guides.rb +188 -0
  57. data/lib/jsduck/img/dir.rb +94 -0
  58. data/lib/jsduck/img/dir_set.rb +39 -0
  59. data/lib/jsduck/img/writer.rb +23 -0
  60. data/lib/jsduck/inline/auto_link.rb +106 -0
  61. data/lib/jsduck/inline/example.rb +44 -0
  62. data/lib/jsduck/inline/img.rb +63 -0
  63. data/lib/jsduck/inline/link.rb +100 -0
  64. data/lib/jsduck/inline/link_renderer.rb +70 -0
  65. data/lib/jsduck/inline/video.rb +61 -0
  66. data/lib/jsduck/inline_examples.rb +94 -0
  67. data/lib/jsduck/js/associator.rb +224 -0
  68. data/lib/jsduck/js/ast.rb +69 -0
  69. data/lib/jsduck/js/class.rb +248 -0
  70. data/lib/jsduck/js/evaluator.rb +70 -0
  71. data/lib/jsduck/js/event.rb +34 -0
  72. data/lib/jsduck/js/ext_define.rb +46 -0
  73. data/lib/jsduck/js/ext_patterns.rb +75 -0
  74. data/lib/jsduck/js/fires.rb +42 -0
  75. data/lib/jsduck/js/listener.rb +35 -0
  76. data/lib/jsduck/js/method.rb +99 -0
  77. data/lib/jsduck/js/method_calls.rb +40 -0
  78. data/lib/jsduck/js/node.rb +267 -0
  79. data/lib/jsduck/js/node_array.rb +36 -0
  80. data/lib/jsduck/js/parser.rb +44 -0
  81. data/lib/jsduck/js/property.rb +81 -0
  82. data/lib/jsduck/js/returns.rb +211 -0
  83. data/lib/jsduck/js/rkelly_adapter.rb +587 -0
  84. data/lib/jsduck/js/scoped_traverser.rb +42 -0
  85. data/lib/jsduck/js/serializer.rb +263 -0
  86. data/lib/jsduck/js/utils.rb +21 -0
  87. data/lib/jsduck/logger.rb +186 -0
  88. data/lib/jsduck/member_registry.rb +41 -0
  89. data/lib/jsduck/members_index.rb +141 -0
  90. data/lib/jsduck/merger.rb +83 -0
  91. data/lib/jsduck/news.rb +149 -0
  92. data/lib/jsduck/options/config.rb +35 -0
  93. data/lib/jsduck/options/helpful_parser.rb +111 -0
  94. data/lib/jsduck/options/input_files.rb +60 -0
  95. data/lib/jsduck/options/jsb.rb +25 -0
  96. data/lib/jsduck/options/parser.rb +968 -0
  97. data/lib/jsduck/options/processor.rb +47 -0
  98. data/lib/jsduck/options/record.rb +51 -0
  99. data/lib/jsduck/output_dir.rb +29 -0
  100. data/lib/jsduck/params_merger.rb +47 -0
  101. data/lib/jsduck/parser.rb +76 -0
  102. data/lib/jsduck/process/accessors.rb +152 -0
  103. data/lib/jsduck/process/circular_deps.rb +58 -0
  104. data/lib/jsduck/process/components.rb +19 -0
  105. data/lib/jsduck/process/enums.rb +90 -0
  106. data/lib/jsduck/process/ext4_events.rb +46 -0
  107. data/lib/jsduck/process/fires.rb +71 -0
  108. data/lib/jsduck/process/global_members.rb +35 -0
  109. data/lib/jsduck/process/ignored_classes.rb +16 -0
  110. data/lib/jsduck/process/importer.rb +75 -0
  111. data/lib/jsduck/process/inherit_class.rb +58 -0
  112. data/lib/jsduck/process/inherit_doc.rb +32 -0
  113. data/lib/jsduck/process/inherit_members.rb +259 -0
  114. data/lib/jsduck/process/lint.rb +118 -0
  115. data/lib/jsduck/process/no_doc.rb +50 -0
  116. data/lib/jsduck/process/overrides.rb +99 -0
  117. data/lib/jsduck/process/return_values.rb +72 -0
  118. data/lib/jsduck/process/versions.rb +137 -0
  119. data/lib/jsduck/relations.rb +95 -0
  120. data/lib/jsduck/render/class.rb +152 -0
  121. data/lib/jsduck/render/sidebar.rb +97 -0
  122. data/lib/jsduck/render/signature_util.rb +14 -0
  123. data/lib/jsduck/render/subproperties.rb +117 -0
  124. data/lib/jsduck/render/tags.rb +50 -0
  125. data/lib/jsduck/source/file.rb +89 -0
  126. data/lib/jsduck/tag/abstract.rb +11 -0
  127. data/lib/jsduck/tag/accessor.rb +10 -0
  128. data/lib/jsduck/tag/alias.rb +42 -0
  129. data/lib/jsduck/tag/alternate_class_names.rb +13 -0
  130. data/lib/jsduck/tag/aside.rb +71 -0
  131. data/lib/jsduck/tag/author.rb +30 -0
  132. data/lib/jsduck/tag/boolean_tag.rb +24 -0
  133. data/lib/jsduck/tag/cfg.rb +79 -0
  134. data/lib/jsduck/tag/chainable.rb +12 -0
  135. data/lib/jsduck/tag/class.rb +77 -0
  136. data/lib/jsduck/tag/class_list_tag.rb +40 -0
  137. data/lib/jsduck/tag/component.rb +19 -0
  138. data/lib/jsduck/tag/constructor.rb +24 -0
  139. data/lib/jsduck/tag/css_mixin.rb +31 -0
  140. data/lib/jsduck/tag/css_var.rb +50 -0
  141. data/lib/jsduck/tag/default.rb +25 -0
  142. data/lib/jsduck/tag/deprecated.rb +23 -0
  143. data/lib/jsduck/tag/deprecated_tag.rb +60 -0
  144. data/lib/jsduck/tag/doc.rb +32 -0
  145. data/lib/jsduck/tag/docauthor.rb +12 -0
  146. data/lib/jsduck/tag/enum.rb +67 -0
  147. data/lib/jsduck/tag/event.rb +36 -0
  148. data/lib/jsduck/tag/evented.rb +10 -0
  149. data/lib/jsduck/tag/experimental.rb +28 -0
  150. data/lib/jsduck/tag/extends.rb +39 -0
  151. data/lib/jsduck/tag/fires.rb +55 -0
  152. data/lib/jsduck/tag/ftype.rb +19 -0
  153. data/lib/jsduck/tag/hide.rb +11 -0
  154. data/lib/jsduck/tag/icons/cfg.png +0 -0
  155. data/lib/jsduck/tag/icons/class-large.png +0 -0
  156. data/lib/jsduck/tag/icons/class-redirect.png +0 -0
  157. data/lib/jsduck/tag/icons/class.png +0 -0
  158. data/lib/jsduck/tag/icons/component-large.png +0 -0
  159. data/lib/jsduck/tag/icons/component-redirect.png +0 -0
  160. data/lib/jsduck/tag/icons/component.png +0 -0
  161. data/lib/jsduck/tag/icons/css_mixin.png +0 -0
  162. data/lib/jsduck/tag/icons/css_var.png +0 -0
  163. data/lib/jsduck/tag/icons/event.png +0 -0
  164. data/lib/jsduck/tag/icons/listener.png +0 -0
  165. data/lib/jsduck/tag/icons/method.png +0 -0
  166. data/lib/jsduck/tag/icons/property.png +0 -0
  167. data/lib/jsduck/tag/icons/singleton-large.png +0 -0
  168. data/lib/jsduck/tag/icons/singleton-redirect.png +0 -0
  169. data/lib/jsduck/tag/icons/singleton.png +0 -0
  170. data/lib/jsduck/tag/ignore.rb +12 -0
  171. data/lib/jsduck/tag/inheritable.rb +10 -0
  172. data/lib/jsduck/tag/inheritdoc.rb +48 -0
  173. data/lib/jsduck/tag/listener.rb +36 -0
  174. data/lib/jsduck/tag/localdoc.rb +33 -0
  175. data/lib/jsduck/tag/markdown.rb +14 -0
  176. data/lib/jsduck/tag/member.rb +24 -0
  177. data/lib/jsduck/tag/member_tag.rb +131 -0
  178. data/lib/jsduck/tag/method.rb +75 -0
  179. data/lib/jsduck/tag/mixins.rb +27 -0
  180. data/lib/jsduck/tag/new.rb +32 -0
  181. data/lib/jsduck/tag/override.rb +37 -0
  182. data/lib/jsduck/tag/overrides.rb +29 -0
  183. data/lib/jsduck/tag/param.rb +46 -0
  184. data/lib/jsduck/tag/preventable.rb +37 -0
  185. data/lib/jsduck/tag/private.rb +35 -0
  186. data/lib/jsduck/tag/property.rb +67 -0
  187. data/lib/jsduck/tag/protected.rb +12 -0
  188. data/lib/jsduck/tag/ptype.rb +19 -0
  189. data/lib/jsduck/tag/readonly.rb +11 -0
  190. data/lib/jsduck/tag/removed.rb +32 -0
  191. data/lib/jsduck/tag/required.rb +23 -0
  192. data/lib/jsduck/tag/requires.rb +13 -0
  193. data/lib/jsduck/tag/return.rb +48 -0
  194. data/lib/jsduck/tag/since.rb +30 -0
  195. data/lib/jsduck/tag/singleton.rb +28 -0
  196. data/lib/jsduck/tag/static.rb +12 -0
  197. data/lib/jsduck/tag/subproperties.rb +23 -0
  198. data/lib/jsduck/tag/tag.rb +164 -0
  199. data/lib/jsduck/tag/template.rb +29 -0
  200. data/lib/jsduck/tag/throws.rb +39 -0
  201. data/lib/jsduck/tag/type.rb +38 -0
  202. data/lib/jsduck/tag/uses.rb +13 -0
  203. data/lib/jsduck/tag/xtype.rb +31 -0
  204. data/lib/jsduck/tag_loader.rb +50 -0
  205. data/lib/jsduck/tag_registry.rb +95 -0
  206. data/lib/jsduck/type_parser.rb +388 -0
  207. data/lib/jsduck/util/html.rb +27 -0
  208. data/lib/jsduck/util/io.rb +49 -0
  209. data/lib/jsduck/util/json.rb +60 -0
  210. data/lib/jsduck/util/md5.rb +32 -0
  211. data/lib/jsduck/util/null_object.rb +36 -0
  212. data/lib/jsduck/util/os.rb +14 -0
  213. data/lib/jsduck/util/parallel.rb +38 -0
  214. data/lib/jsduck/util/singleton.rb +35 -0
  215. data/lib/jsduck/util/stdout.rb +33 -0
  216. data/lib/jsduck/version.rb +5 -0
  217. data/lib/jsduck/videos.rb +40 -0
  218. data/lib/jsduck/warning/all.rb +36 -0
  219. data/lib/jsduck/warning/basic.rb +57 -0
  220. data/lib/jsduck/warning/deprecated.rb +40 -0
  221. data/lib/jsduck/warning/nodoc.rb +79 -0
  222. data/lib/jsduck/warning/parser.rb +168 -0
  223. data/lib/jsduck/warning/registry.rb +108 -0
  224. data/lib/jsduck/warning/tag.rb +57 -0
  225. data/lib/jsduck/warning/warn_exception.rb +10 -0
  226. data/lib/jsduck/web/class_icons.rb +76 -0
  227. data/lib/jsduck/web/css.rb +40 -0
  228. data/lib/jsduck/web/data.rb +52 -0
  229. data/lib/jsduck/web/index_html.rb +105 -0
  230. data/lib/jsduck/web/member_icons.rb +43 -0
  231. data/lib/jsduck/web/search.rb +153 -0
  232. data/lib/jsduck/web/source.rb +89 -0
  233. data/lib/jsduck/web/template.rb +51 -0
  234. data/lib/jsduck/web/tree.rb +22 -0
  235. data/lib/jsduck/web/writer.rb +100 -0
  236. data/lib/jsduck/welcome.rb +31 -0
  237. data/template-min/README.md +14 -0
  238. data/template-min/app-0f524ddd276c4019a11a6128932a9c96.js +1 -0
  239. data/template-min/eg-iframe.html +26 -0
  240. data/template-min/extjs/ext-all.js +38 -0
  241. data/template-min/extjs/resources/themes/images/default/boundlist/trigger-arrow.png +0 -0
  242. data/template-min/extjs/resources/themes/images/default/box/corners-blue.gif +0 -0
  243. data/template-min/extjs/resources/themes/images/default/box/corners.gif +0 -0
  244. data/template-min/extjs/resources/themes/images/default/box/l-blue.gif +0 -0
  245. data/template-min/extjs/resources/themes/images/default/box/l.gif +0 -0
  246. data/template-min/extjs/resources/themes/images/default/box/r-blue.gif +0 -0
  247. data/template-min/extjs/resources/themes/images/default/box/r.gif +0 -0
  248. data/template-min/extjs/resources/themes/images/default/box/tb-blue.gif +0 -0
  249. data/template-min/extjs/resources/themes/images/default/box/tb.gif +0 -0
  250. data/template-min/extjs/resources/themes/images/default/btn-group/btn-group-default-framed-corners.gif +0 -0
  251. data/template-min/extjs/resources/themes/images/default/btn-group/btn-group-default-framed-notitle-corners.gif +0 -0
  252. data/template-min/extjs/resources/themes/images/default/btn-group/btn-group-default-framed-notitle-sides.gif +0 -0
  253. data/template-min/extjs/resources/themes/images/default/btn-group/btn-group-default-framed-sides.gif +0 -0
  254. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-bg.gif +0 -0
  255. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-corners.gif +0 -0
  256. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-disabled-bg.gif +0 -0
  257. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-disabled-corners.gif +0 -0
  258. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-disabled-sides.gif +0 -0
  259. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-focus-bg.gif +0 -0
  260. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-focus-corners.gif +0 -0
  261. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-focus-sides.gif +0 -0
  262. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-over-bg.gif +0 -0
  263. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-over-corners.gif +0 -0
  264. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-over-sides.gif +0 -0
  265. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-pressed-bg.gif +0 -0
  266. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-pressed-corners.gif +0 -0
  267. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-pressed-sides.gif +0 -0
  268. data/template-min/extjs/resources/themes/images/default/btn/btn-default-large-sides.gif +0 -0
  269. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-bg.gif +0 -0
  270. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-corners.gif +0 -0
  271. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-disabled-bg.gif +0 -0
  272. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-disabled-corners.gif +0 -0
  273. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-disabled-sides.gif +0 -0
  274. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-focus-bg.gif +0 -0
  275. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-focus-corners.gif +0 -0
  276. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-focus-sides.gif +0 -0
  277. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-over-bg.gif +0 -0
  278. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-over-corners.gif +0 -0
  279. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-over-sides.gif +0 -0
  280. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-pressed-bg.gif +0 -0
  281. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-pressed-corners.gif +0 -0
  282. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-pressed-sides.gif +0 -0
  283. data/template-min/extjs/resources/themes/images/default/btn/btn-default-medium-sides.gif +0 -0
  284. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-bg.gif +0 -0
  285. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-corners.gif +0 -0
  286. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-disabled-bg.gif +0 -0
  287. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-disabled-corners.gif +0 -0
  288. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-disabled-sides.gif +0 -0
  289. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-focus-bg.gif +0 -0
  290. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-focus-corners.gif +0 -0
  291. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-focus-sides.gif +0 -0
  292. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-over-bg.gif +0 -0
  293. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-over-corners.gif +0 -0
  294. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-over-sides.gif +0 -0
  295. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-pressed-bg.gif +0 -0
  296. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-pressed-corners.gif +0 -0
  297. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-pressed-sides.gif +0 -0
  298. data/template-min/extjs/resources/themes/images/default/btn/btn-default-small-sides.gif +0 -0
  299. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-corners.gif +0 -0
  300. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-disabled-corners.gif +0 -0
  301. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-disabled-sides.gif +0 -0
  302. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-focus-bg.gif +0 -0
  303. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-focus-corners.gif +0 -0
  304. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-focus-sides.gif +0 -0
  305. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-over-bg.gif +0 -0
  306. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-over-corners.gif +0 -0
  307. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-over-sides.gif +0 -0
  308. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-pressed-bg.gif +0 -0
  309. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-pressed-corners.gif +0 -0
  310. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-pressed-sides.gif +0 -0
  311. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-large-sides.gif +0 -0
  312. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-corners.gif +0 -0
  313. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-disabled-corners.gif +0 -0
  314. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-disabled-sides.gif +0 -0
  315. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-focus-bg.gif +0 -0
  316. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-focus-corners.gif +0 -0
  317. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-focus-sides.gif +0 -0
  318. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-over-bg.gif +0 -0
  319. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-over-corners.gif +0 -0
  320. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-over-sides.gif +0 -0
  321. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-pressed-bg.gif +0 -0
  322. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-pressed-corners.gif +0 -0
  323. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-pressed-sides.gif +0 -0
  324. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-medium-sides.gif +0 -0
  325. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-corners.gif +0 -0
  326. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-disabled-corners.gif +0 -0
  327. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-disabled-sides.gif +0 -0
  328. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-focus-bg.gif +0 -0
  329. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-focus-corners.gif +0 -0
  330. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-focus-sides.gif +0 -0
  331. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-over-bg.gif +0 -0
  332. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-over-corners.gif +0 -0
  333. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-over-sides.gif +0 -0
  334. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-pressed-bg.gif +0 -0
  335. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-pressed-corners.gif +0 -0
  336. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-pressed-sides.gif +0 -0
  337. data/template-min/extjs/resources/themes/images/default/btn/btn-default-toolbar-small-sides.gif +0 -0
  338. data/template-min/extjs/resources/themes/images/default/button/arrow.gif +0 -0
  339. data/template-min/extjs/resources/themes/images/default/button/btn.gif +0 -0
  340. data/template-min/extjs/resources/themes/images/default/button/group-cs.gif +0 -0
  341. data/template-min/extjs/resources/themes/images/default/button/group-lr.gif +0 -0
  342. data/template-min/extjs/resources/themes/images/default/button/group-tb.gif +0 -0
  343. data/template-min/extjs/resources/themes/images/default/button/s-arrow-b-noline.gif +0 -0
  344. data/template-min/extjs/resources/themes/images/default/button/s-arrow-b.gif +0 -0
  345. data/template-min/extjs/resources/themes/images/default/button/s-arrow-bo.gif +0 -0
  346. data/template-min/extjs/resources/themes/images/default/button/s-arrow-light.gif +0 -0
  347. data/template-min/extjs/resources/themes/images/default/button/s-arrow-noline.gif +0 -0
  348. data/template-min/extjs/resources/themes/images/default/button/s-arrow-o.gif +0 -0
  349. data/template-min/extjs/resources/themes/images/default/button/s-arrow.gif +0 -0
  350. data/template-min/extjs/resources/themes/images/default/datepicker/datepicker-footer-bg.gif +0 -0
  351. data/template-min/extjs/resources/themes/images/default/datepicker/datepicker-footer-bg.png +0 -0
  352. data/template-min/extjs/resources/themes/images/default/datepicker/datepicker-header-bg.gif +0 -0
  353. data/template-min/extjs/resources/themes/images/default/datepicker/datepicker-header-bg.png +0 -0
  354. data/template-min/extjs/resources/themes/images/default/dd/drop-add.gif +0 -0
  355. data/template-min/extjs/resources/themes/images/default/dd/drop-no.gif +0 -0
  356. data/template-min/extjs/resources/themes/images/default/dd/drop-yes.gif +0 -0
  357. data/template-min/extjs/resources/themes/images/default/editor/tb-sprite.gif +0 -0
  358. data/template-min/extjs/resources/themes/images/default/form-invalid-tip/form-invalid-tip-corners.gif +0 -0
  359. data/template-min/extjs/resources/themes/images/default/form-invalid-tip/form-invalid-tip-default-corners.gif +0 -0
  360. data/template-min/extjs/resources/themes/images/default/form-invalid-tip/form-invalid-tip-default-sides.gif +0 -0
  361. data/template-min/extjs/resources/themes/images/default/form-invalid-tip/form-invalid-tip-sides.gif +0 -0
  362. data/template-min/extjs/resources/themes/images/default/form/checkbox.gif +0 -0
  363. data/template-min/extjs/resources/themes/images/default/form/clear-trigger.gif +0 -0
  364. data/template-min/extjs/resources/themes/images/default/form/date-trigger.gif +0 -0
  365. data/template-min/extjs/resources/themes/images/default/form/error-tip-corners.gif +0 -0
  366. data/template-min/extjs/resources/themes/images/default/form/exclamation.gif +0 -0
  367. data/template-min/extjs/resources/themes/images/default/form/radio.gif +0 -0
  368. data/template-min/extjs/resources/themes/images/default/form/search-trigger.gif +0 -0
  369. data/template-min/extjs/resources/themes/images/default/form/spinner-small.gif +0 -0
  370. data/template-min/extjs/resources/themes/images/default/form/spinner.gif +0 -0
  371. data/template-min/extjs/resources/themes/images/default/form/text-bg.gif +0 -0
  372. data/template-min/extjs/resources/themes/images/default/form/trigger-square.gif +0 -0
  373. data/template-min/extjs/resources/themes/images/default/form/trigger-tpl.gif +0 -0
  374. data/template-min/extjs/resources/themes/images/default/form/trigger.gif +0 -0
  375. data/template-min/extjs/resources/themes/images/default/grid/arrow-left-white.gif +0 -0
  376. data/template-min/extjs/resources/themes/images/default/grid/arrow-right-white.gif +0 -0
  377. data/template-min/extjs/resources/themes/images/default/grid/cell-special-bg.gif +0 -0
  378. data/template-min/extjs/resources/themes/images/default/grid/cell-special-bg.png +0 -0
  379. data/template-min/extjs/resources/themes/images/default/grid/cell-special-selected-bg.gif +0 -0
  380. data/template-min/extjs/resources/themes/images/default/grid/cell-special-selected-bg.png +0 -0
  381. data/template-min/extjs/resources/themes/images/default/grid/checked.gif +0 -0
  382. data/template-min/extjs/resources/themes/images/default/grid/col-move-bottom.gif +0 -0
  383. data/template-min/extjs/resources/themes/images/default/grid/col-move-top.gif +0 -0
  384. data/template-min/extjs/resources/themes/images/default/grid/column-header-bg.gif +0 -0
  385. data/template-min/extjs/resources/themes/images/default/grid/column-header-bg.png +0 -0
  386. data/template-min/extjs/resources/themes/images/default/grid/column-header-over-bg.gif +0 -0
  387. data/template-min/extjs/resources/themes/images/default/grid/column-header-over-bg.png +0 -0
  388. data/template-min/extjs/resources/themes/images/default/grid/columns.gif +0 -0
  389. data/template-min/extjs/resources/themes/images/default/grid/dd-insert-arrow-left.gif +0 -0
  390. data/template-min/extjs/resources/themes/images/default/grid/dd-insert-arrow-left.png +0 -0
  391. data/template-min/extjs/resources/themes/images/default/grid/dd-insert-arrow-right.gif +0 -0
  392. data/template-min/extjs/resources/themes/images/default/grid/dd-insert-arrow-right.png +0 -0
  393. data/template-min/extjs/resources/themes/images/default/grid/dirty.gif +0 -0
  394. data/template-min/extjs/resources/themes/images/default/grid/done.gif +0 -0
  395. data/template-min/extjs/resources/themes/images/default/grid/drop-no.gif +0 -0
  396. data/template-min/extjs/resources/themes/images/default/grid/drop-yes.gif +0 -0
  397. data/template-min/extjs/resources/themes/images/default/grid/footer-bg.gif +0 -0
  398. data/template-min/extjs/resources/themes/images/default/grid/grid-blue-hd.gif +0 -0
  399. data/template-min/extjs/resources/themes/images/default/grid/grid-blue-split.gif +0 -0
  400. data/template-min/extjs/resources/themes/images/default/grid/grid-hrow.gif +0 -0
  401. data/template-min/extjs/resources/themes/images/default/grid/grid-loading.gif +0 -0
  402. data/template-min/extjs/resources/themes/images/default/grid/grid-split.gif +0 -0
  403. data/template-min/extjs/resources/themes/images/default/grid/grid-vista-hd.gif +0 -0
  404. data/template-min/extjs/resources/themes/images/default/grid/grid3-hd-btn.gif +0 -0
  405. data/template-min/extjs/resources/themes/images/default/grid/grid3-hrow-over.gif +0 -0
  406. data/template-min/extjs/resources/themes/images/default/grid/grid3-hrow.gif +0 -0
  407. data/template-min/extjs/resources/themes/images/default/grid/grid3-rowheader.gif +0 -0
  408. data/template-min/extjs/resources/themes/images/default/grid/group-by.gif +0 -0
  409. data/template-min/extjs/resources/themes/images/default/grid/group-collapse.gif +0 -0
  410. data/template-min/extjs/resources/themes/images/default/grid/group-expand-sprite.gif +0 -0
  411. data/template-min/extjs/resources/themes/images/default/grid/group-expand.gif +0 -0
  412. data/template-min/extjs/resources/themes/images/default/grid/hd-pop.gif +0 -0
  413. data/template-min/extjs/resources/themes/images/default/grid/hmenu-asc.gif +0 -0
  414. data/template-min/extjs/resources/themes/images/default/grid/hmenu-desc.gif +0 -0
  415. data/template-min/extjs/resources/themes/images/default/grid/hmenu-lock.gif +0 -0
  416. data/template-min/extjs/resources/themes/images/default/grid/hmenu-lock.png +0 -0
  417. data/template-min/extjs/resources/themes/images/default/grid/hmenu-unlock.gif +0 -0
  418. data/template-min/extjs/resources/themes/images/default/grid/hmenu-unlock.png +0 -0
  419. data/template-min/extjs/resources/themes/images/default/grid/invalid_line.gif +0 -0
  420. data/template-min/extjs/resources/themes/images/default/grid/loading.gif +0 -0
  421. data/template-min/extjs/resources/themes/images/default/grid/mso-hd.gif +0 -0
  422. data/template-min/extjs/resources/themes/images/default/grid/nowait.gif +0 -0
  423. data/template-min/extjs/resources/themes/images/default/grid/page-first-disabled.gif +0 -0
  424. data/template-min/extjs/resources/themes/images/default/grid/page-first.gif +0 -0
  425. data/template-min/extjs/resources/themes/images/default/grid/page-last-disabled.gif +0 -0
  426. data/template-min/extjs/resources/themes/images/default/grid/page-last.gif +0 -0
  427. data/template-min/extjs/resources/themes/images/default/grid/page-next-disabled.gif +0 -0
  428. data/template-min/extjs/resources/themes/images/default/grid/page-next.gif +0 -0
  429. data/template-min/extjs/resources/themes/images/default/grid/page-prev-disabled.gif +0 -0
  430. data/template-min/extjs/resources/themes/images/default/grid/page-prev.gif +0 -0
  431. data/template-min/extjs/resources/themes/images/default/grid/pick-button.gif +0 -0
  432. data/template-min/extjs/resources/themes/images/default/grid/property-cell-bg.gif +0 -0
  433. data/template-min/extjs/resources/themes/images/default/grid/property-cell-selected-bg.gif +0 -0
  434. data/template-min/extjs/resources/themes/images/default/grid/refresh-disabled.gif +0 -0
  435. data/template-min/extjs/resources/themes/images/default/grid/refresh.gif +0 -0
  436. data/template-min/extjs/resources/themes/images/default/grid/row-check-sprite.gif +0 -0
  437. data/template-min/extjs/resources/themes/images/default/grid/row-expand-sprite.gif +0 -0
  438. data/template-min/extjs/resources/themes/images/default/grid/row-over.gif +0 -0
  439. data/template-min/extjs/resources/themes/images/default/grid/row-sel.gif +0 -0
  440. data/template-min/extjs/resources/themes/images/default/grid/sort-hd.gif +0 -0
  441. data/template-min/extjs/resources/themes/images/default/grid/sort_asc.gif +0 -0
  442. data/template-min/extjs/resources/themes/images/default/grid/sort_desc.gif +0 -0
  443. data/template-min/extjs/resources/themes/images/default/grid/unchecked.gif +0 -0
  444. data/template-min/extjs/resources/themes/images/default/grid/wait.gif +0 -0
  445. data/template-min/extjs/resources/themes/images/default/layout/mini-bottom.gif +0 -0
  446. data/template-min/extjs/resources/themes/images/default/layout/mini-left.gif +0 -0
  447. data/template-min/extjs/resources/themes/images/default/layout/mini-right.gif +0 -0
  448. data/template-min/extjs/resources/themes/images/default/layout/mini-top.gif +0 -0
  449. data/template-min/extjs/resources/themes/images/default/menu/checked.gif +0 -0
  450. data/template-min/extjs/resources/themes/images/default/menu/group-checked.gif +0 -0
  451. data/template-min/extjs/resources/themes/images/default/menu/item-over.gif +0 -0
  452. data/template-min/extjs/resources/themes/images/default/menu/menu-item-active-bg.gif +0 -0
  453. data/template-min/extjs/resources/themes/images/default/menu/menu-item-active-corners.gif +0 -0
  454. data/template-min/extjs/resources/themes/images/default/menu/menu-item-active-sides.gif +0 -0
  455. data/template-min/extjs/resources/themes/images/default/menu/menu-parent.gif +0 -0
  456. data/template-min/extjs/resources/themes/images/default/menu/menu.gif +0 -0
  457. data/template-min/extjs/resources/themes/images/default/menu/unchecked.gif +0 -0
  458. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-bottom-bg.gif +0 -0
  459. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-bottom-bg.gif +0 -0
  460. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-bottom-corners.gif +0 -0
  461. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-bottom-sides.gif +0 -0
  462. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-bottom-bg.gif +0 -0
  463. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-bottom-corners.gif +0 -0
  464. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-bottom-sides.gif +0 -0
  465. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-left-bg.gif +0 -0
  466. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-left-corners.gif +0 -0
  467. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-left-sides.gif +0 -0
  468. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-right-bg.gif +0 -0
  469. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-right-corners.gif +0 -0
  470. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-right-sides.gif +0 -0
  471. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-top-bg.gif +0 -0
  472. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-top-corners.gif +0 -0
  473. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-collapsed-top-sides.gif +0 -0
  474. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-left-bg.gif +0 -0
  475. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-left-corners.gif +0 -0
  476. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-left-sides.gif +0 -0
  477. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-right-bg.gif +0 -0
  478. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-right-corners.gif +0 -0
  479. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-right-sides.gif +0 -0
  480. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-top-bg.gif +0 -0
  481. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-top-corners.gif +0 -0
  482. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-framed-top-sides.gif +0 -0
  483. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-left-bg.gif +0 -0
  484. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-right-bg.gif +0 -0
  485. data/template-min/extjs/resources/themes/images/default/panel-header/panel-header-default-top-bg.gif +0 -0
  486. data/template-min/extjs/resources/themes/images/default/panel/panel-default-framed-corners.gif +0 -0
  487. data/template-min/extjs/resources/themes/images/default/panel/panel-default-framed-sides.gif +0 -0
  488. data/template-min/extjs/resources/themes/images/default/progress/progress-default-bg.gif +0 -0
  489. data/template-min/extjs/resources/themes/images/default/shared/blue-loading.gif +0 -0
  490. data/template-min/extjs/resources/themes/images/default/shared/calendar.gif +0 -0
  491. data/template-min/extjs/resources/themes/images/default/shared/glass-bg.gif +0 -0
  492. data/template-min/extjs/resources/themes/images/default/shared/hd-sprite.gif +0 -0
  493. data/template-min/extjs/resources/themes/images/default/shared/icon-error.gif +0 -0
  494. data/template-min/extjs/resources/themes/images/default/shared/icon-info.gif +0 -0
  495. data/template-min/extjs/resources/themes/images/default/shared/icon-question.gif +0 -0
  496. data/template-min/extjs/resources/themes/images/default/shared/icon-warning.gif +0 -0
  497. data/template-min/extjs/resources/themes/images/default/shared/large-loading.gif +0 -0
  498. data/template-min/extjs/resources/themes/images/default/shared/left-btn.gif +0 -0
  499. data/template-min/extjs/resources/themes/images/default/shared/loading-balls.gif +0 -0
  500. data/template-min/extjs/resources/themes/images/default/shared/right-btn.gif +0 -0
  501. data/template-min/extjs/resources/themes/images/default/shared/shadow-c.png +0 -0
  502. data/template-min/extjs/resources/themes/images/default/shared/shadow-lr.png +0 -0
  503. data/template-min/extjs/resources/themes/images/default/shared/shadow.png +0 -0
  504. data/template-min/extjs/resources/themes/images/default/shared/warning.gif +0 -0
  505. data/template-min/extjs/resources/themes/images/default/sizer/e-handle-dark.gif +0 -0
  506. data/template-min/extjs/resources/themes/images/default/sizer/e-handle.gif +0 -0
  507. data/template-min/extjs/resources/themes/images/default/sizer/ne-handle-dark.gif +0 -0
  508. data/template-min/extjs/resources/themes/images/default/sizer/ne-handle.gif +0 -0
  509. data/template-min/extjs/resources/themes/images/default/sizer/nw-handle-dark.gif +0 -0
  510. data/template-min/extjs/resources/themes/images/default/sizer/nw-handle.gif +0 -0
  511. data/template-min/extjs/resources/themes/images/default/sizer/s-handle-dark.gif +0 -0
  512. data/template-min/extjs/resources/themes/images/default/sizer/s-handle.gif +0 -0
  513. data/template-min/extjs/resources/themes/images/default/sizer/se-handle-dark.gif +0 -0
  514. data/template-min/extjs/resources/themes/images/default/sizer/se-handle.gif +0 -0
  515. data/template-min/extjs/resources/themes/images/default/sizer/square.gif +0 -0
  516. data/template-min/extjs/resources/themes/images/default/sizer/sw-handle-dark.gif +0 -0
  517. data/template-min/extjs/resources/themes/images/default/sizer/sw-handle.gif +0 -0
  518. data/template-min/extjs/resources/themes/images/default/slider/slider-bg.gif +0 -0
  519. data/template-min/extjs/resources/themes/images/default/slider/slider-bg.png +0 -0
  520. data/template-min/extjs/resources/themes/images/default/slider/slider-thumb.gif +0 -0
  521. data/template-min/extjs/resources/themes/images/default/slider/slider-thumb.png +0 -0
  522. data/template-min/extjs/resources/themes/images/default/slider/slider-v-bg.gif +0 -0
  523. data/template-min/extjs/resources/themes/images/default/slider/slider-v-bg.png +0 -0
  524. data/template-min/extjs/resources/themes/images/default/slider/slider-v-thumb.gif +0 -0
  525. data/template-min/extjs/resources/themes/images/default/slider/slider-v-thumb.png +0 -0
  526. data/template-min/extjs/resources/themes/images/default/tab-bar/scroll-left.gif +0 -0
  527. data/template-min/extjs/resources/themes/images/default/tab-bar/scroll-right.gif +0 -0
  528. data/template-min/extjs/resources/themes/images/default/tab-bar/tab-bar-default-bg.gif +0 -0
  529. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-active-bg.gif +0 -0
  530. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-active-corners.gif +0 -0
  531. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-active-sides.gif +0 -0
  532. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-bg.gif +0 -0
  533. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-corners.gif +0 -0
  534. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-disabled-bg.gif +0 -0
  535. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-disabled-corners.gif +0 -0
  536. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-disabled-sides.gif +0 -0
  537. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-over-bg.gif +0 -0
  538. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-over-corners.gif +0 -0
  539. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-over-sides.gif +0 -0
  540. data/template-min/extjs/resources/themes/images/default/tab/tab-default-bottom-sides.gif +0 -0
  541. data/template-min/extjs/resources/themes/images/default/tab/tab-default-close.gif +0 -0
  542. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-active-bg.gif +0 -0
  543. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-active-corners.gif +0 -0
  544. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-active-sides.gif +0 -0
  545. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-bg.gif +0 -0
  546. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-corners.gif +0 -0
  547. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-disabled-bg.gif +0 -0
  548. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-disabled-corners.gif +0 -0
  549. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-disabled-sides.gif +0 -0
  550. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-over-bg.gif +0 -0
  551. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-over-corners.gif +0 -0
  552. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-over-sides.gif +0 -0
  553. data/template-min/extjs/resources/themes/images/default/tab/tab-default-top-sides.gif +0 -0
  554. data/template-min/extjs/resources/themes/images/default/tip/tip-corners.gif +0 -0
  555. data/template-min/extjs/resources/themes/images/default/tip/tip-sides.gif +0 -0
  556. data/template-min/extjs/resources/themes/images/default/toolbar/more.gif +0 -0
  557. data/template-min/extjs/resources/themes/images/default/toolbar/scroll-left.gif +0 -0
  558. data/template-min/extjs/resources/themes/images/default/toolbar/scroll-right.gif +0 -0
  559. data/template-min/extjs/resources/themes/images/default/toolbar/toolbar-default-bg.gif +0 -0
  560. data/template-min/extjs/resources/themes/images/default/tools/tool-sprite-tpl.gif +0 -0
  561. data/template-min/extjs/resources/themes/images/default/tools/tool-sprites.gif +0 -0
  562. data/template-min/extjs/resources/themes/images/default/tools/tools-sprites-trans.gif +0 -0
  563. data/template-min/extjs/resources/themes/images/default/tree/arrows.gif +0 -0
  564. data/template-min/extjs/resources/themes/images/default/tree/drop-above.gif +0 -0
  565. data/template-min/extjs/resources/themes/images/default/tree/drop-add.gif +0 -0
  566. data/template-min/extjs/resources/themes/images/default/tree/drop-append.gif +0 -0
  567. data/template-min/extjs/resources/themes/images/default/tree/drop-below.gif +0 -0
  568. data/template-min/extjs/resources/themes/images/default/tree/drop-between.gif +0 -0
  569. data/template-min/extjs/resources/themes/images/default/tree/drop-no.gif +0 -0
  570. data/template-min/extjs/resources/themes/images/default/tree/drop-over.gif +0 -0
  571. data/template-min/extjs/resources/themes/images/default/tree/drop-under.gif +0 -0
  572. data/template-min/extjs/resources/themes/images/default/tree/drop-yes.gif +0 -0
  573. data/template-min/extjs/resources/themes/images/default/tree/elbow-end-minus-nl.gif +0 -0
  574. data/template-min/extjs/resources/themes/images/default/tree/elbow-end-minus.gif +0 -0
  575. data/template-min/extjs/resources/themes/images/default/tree/elbow-end-plus-nl.gif +0 -0
  576. data/template-min/extjs/resources/themes/images/default/tree/elbow-end-plus.gif +0 -0
  577. data/template-min/extjs/resources/themes/images/default/tree/elbow-end.gif +0 -0
  578. data/template-min/extjs/resources/themes/images/default/tree/elbow-line.gif +0 -0
  579. data/template-min/extjs/resources/themes/images/default/tree/elbow-minus-nl.gif +0 -0
  580. data/template-min/extjs/resources/themes/images/default/tree/elbow-minus.gif +0 -0
  581. data/template-min/extjs/resources/themes/images/default/tree/elbow-plus-nl.gif +0 -0
  582. data/template-min/extjs/resources/themes/images/default/tree/elbow-plus.gif +0 -0
  583. data/template-min/extjs/resources/themes/images/default/tree/elbow.gif +0 -0
  584. data/template-min/extjs/resources/themes/images/default/tree/folder-open.gif +0 -0
  585. data/template-min/extjs/resources/themes/images/default/tree/folder.gif +0 -0
  586. data/template-min/extjs/resources/themes/images/default/tree/leaf.gif +0 -0
  587. data/template-min/extjs/resources/themes/images/default/tree/loading.gif +0 -0
  588. data/template-min/extjs/resources/themes/images/default/tree/s.gif +0 -0
  589. data/template-min/extjs/resources/themes/images/default/util/splitter/mini-bottom.gif +0 -0
  590. data/template-min/extjs/resources/themes/images/default/util/splitter/mini-left.gif +0 -0
  591. data/template-min/extjs/resources/themes/images/default/util/splitter/mini-right.gif +0 -0
  592. data/template-min/extjs/resources/themes/images/default/util/splitter/mini-top.gif +0 -0
  593. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-bottom-corners.gif +0 -0
  594. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-bottom-sides.gif +0 -0
  595. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-bottom-corners.gif +0 -0
  596. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-bottom-sides.gif +0 -0
  597. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-left-corners.gif +0 -0
  598. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-left-sides.gif +0 -0
  599. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-right-corners.gif +0 -0
  600. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-right-sides.gif +0 -0
  601. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-top-corners.gif +0 -0
  602. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-collapsed-top-sides.gif +0 -0
  603. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-left-corners.gif +0 -0
  604. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-left-sides.gif +0 -0
  605. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-right-corners.gif +0 -0
  606. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-right-sides.gif +0 -0
  607. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-top-corners.gif +0 -0
  608. data/template-min/extjs/resources/themes/images/default/window-header/window-header-default-top-sides.gif +0 -0
  609. data/template-min/extjs/resources/themes/images/default/window/window-default-corners.gif +0 -0
  610. data/template-min/extjs/resources/themes/images/default/window/window-default-sides.gif +0 -0
  611. data/template-min/favicon.ico +0 -0
  612. data/template-min/index-template.html +35 -0
  613. data/template-min/index.php +95 -0
  614. data/template-min/mobile-redirect.js +1 -0
  615. data/template-min/print-template.html +52 -0
  616. data/template-min/resources/css/app-de670120f43fdad3091a0cc2c10daadb.css +1 -0
  617. data/template-min/resources/images/ajax-loader.gif +0 -0
  618. data/template-min/resources/images/arrows.png +0 -0
  619. data/template-min/resources/images/comment-bubble.png +0 -0
  620. data/template-min/resources/images/comment.png +0 -0
  621. data/template-min/resources/images/default-guide.png +0 -0
  622. data/template-min/resources/images/doc-m.png +0 -0
  623. data/template-min/resources/images/down-arr.png +0 -0
  624. data/template-min/resources/images/elbow-end.gif +0 -0
  625. data/template-min/resources/images/example-icons.png +0 -0
  626. data/template-min/resources/images/expandcollapse.png +0 -0
  627. data/template-min/resources/images/group-expand-sprite.gif +0 -0
  628. data/template-min/resources/images/header.png +0 -0
  629. data/template-min/resources/images/hero-extjs4-alt.png +0 -0
  630. data/template-min/resources/images/icons.png +0 -0
  631. data/template-min/resources/images/icons.xcf +0 -0
  632. data/template-min/resources/images/link-green-standard-over.png +0 -0
  633. data/template-min/resources/images/link-green-standard.png +0 -0
  634. data/template-min/resources/images/loading.gif +0 -0
  635. data/template-min/resources/images/logo-screen-noglow.png +0 -0
  636. data/template-min/resources/images/logo.png +0 -0
  637. data/template-min/resources/images/member-collapsed.gif +0 -0
  638. data/template-min/resources/images/member-expanded.gif +0 -0
  639. data/template-min/resources/images/member-hover.gif +0 -0
  640. data/template-min/resources/images/more.png +0 -0
  641. data/template-min/resources/images/phone-l.jpg +0 -0
  642. data/template-min/resources/images/phone-p.jpg +0 -0
  643. data/template-min/resources/images/phone-small-l.jpg +0 -0
  644. data/template-min/resources/images/phone-small-p.jpg +0 -0
  645. data/template-min/resources/images/print.png +0 -0
  646. data/template-min/resources/images/sample-over.gif +0 -0
  647. data/template-min/resources/images/search-box.png +0 -0
  648. data/template-min/resources/images/tablet-l.jpg +0 -0
  649. data/template-min/resources/images/tablet-p.jpg +0 -0
  650. data/template-min/resources/images/tabs.png +0 -0
  651. data/template-min/resources/images/text-bg.gif +0 -0
  652. data/template-min/resources/images/vote-arrows.png +0 -0
  653. data/template-min/resources/images/welcome-bg-js4.gif +0 -0
  654. data/template-min/resources/images/x.png +0 -0
  655. data/template-min/resources/images/x12.png +0 -0
  656. data/template-min/resources/prettify/prettify.css +1 -0
  657. data/template-min/resources/prettify/prettify.js +30 -0
  658. data/template-min/template.html +44 -0
  659. metadata +828 -0
@@ -0,0 +1,64 @@
1
+ require 'jsduck/util/html'
2
+ require 'jsduck/logger'
3
+ require 'jsduck/type_parser'
4
+
5
+ module JsDuck
6
+ module Format
7
+
8
+ # Helper for recursively formatting subproperties.
9
+ class Subproperties
10
+
11
+ def initialize(formatter)
12
+ @formatter = formatter
13
+ @skip_type_parsing = false
14
+ end
15
+
16
+ # Set to true to skip parsing and formatting of types.
17
+ # Used to skip parsing of SCSS typesdefs.
18
+ attr_accessor :skip_type_parsing
19
+
20
+ # Takes a hash of param, return value, throws value or subproperty.
21
+ #
22
+ # - Markdown-formats the :doc field in it.
23
+ # - Parses the :type field and saves HTML to :html_type.
24
+ # - Recursively does the same with all items in :properties field.
25
+ #
26
+ def format(item)
27
+ item[:doc] = @formatter.format(item[:doc]) if item[:doc]
28
+
29
+ if item[:type]
30
+ item[:html_type] = format_type(item[:type])
31
+ end
32
+
33
+ if item[:properties]
34
+ item[:properties].each {|p| format(p) }
35
+ end
36
+ end
37
+
38
+ # Formats the given type definition string using TypeParser.
39
+ #
40
+ # - On success returns HTML-version of the type definition.
41
+ # - On failure logs error and returns the type string with only HTML escaped.
42
+ #
43
+ def format_type(type)
44
+ # Skip the formatting entirely when type-parsing is turned off.
45
+ return Util::HTML.escape(type) if @skip_type_parsing
46
+
47
+ tp = TypeParser.new(@formatter)
48
+ if tp.parse(type)
49
+ tp.out
50
+ else
51
+ context = @formatter.doc_context
52
+ if tp.error == :syntax
53
+ Logger.warn(:type_syntax, "Incorrect type syntax #{type}", context)
54
+ else
55
+ Logger.warn(:type_name, "Unknown type #{type}", context)
56
+ end
57
+ Util::HTML.escape(type)
58
+ end
59
+ end
60
+
61
+ end
62
+
63
+ end
64
+ end
@@ -0,0 +1,59 @@
1
+ require 'jsduck/logger'
2
+
3
+ module JsDuck
4
+
5
+ # Parent class for assets that consist of groups.
6
+ # That is: guides, vides, examples.
7
+ #
8
+ # Subclasses must initialize @groups before calling any of the
9
+ # methods in this class.
10
+ class GroupedAsset
11
+ # Should be called from constructor after @groups have been read in,
12
+ # and after it's been ensured that all items in groupes have names.
13
+ def build_map_by_name
14
+ @map_by_name = {}
15
+ each_item do |item|
16
+ @map_by_name[item["name"]] = item
17
+ end
18
+ end
19
+
20
+ # Accesses item by name
21
+ def [](name)
22
+ @map_by_name[name]
23
+ end
24
+
25
+ # Iterates over all items in all groups
26
+ def each_item(group=nil, &block)
27
+ group = group || @groups
28
+
29
+ group.each do |item|
30
+ if item["items"]
31
+ each_item(item["items"], &block)
32
+ else
33
+ block.call(item)
34
+ end
35
+ end
36
+ end
37
+
38
+ def map_items(group=nil, &block)
39
+ group = group || @groups
40
+
41
+ group.map do |item|
42
+ if item["items"]
43
+ {
44
+ "title" => item["title"],
45
+ "items" => map_items(item["items"], &block)
46
+ }
47
+ else
48
+ block.call(item)
49
+ end
50
+ end
51
+ end
52
+
53
+ # Returns all groups as array
54
+ def to_array
55
+ @groups
56
+ end
57
+ end
58
+
59
+ end
@@ -0,0 +1,39 @@
1
+ require 'cgi'
2
+
3
+ module JsDuck
4
+
5
+ # Transforms in-page links so they won't break docs app #!-navigation.
6
+ #
7
+ # For example a link to "#automation" in testing guide will be
8
+ # replaced with "#!/guide/testing-section-automation" and the link
9
+ # target ID will be transformed into "testing-section-automation".
10
+ class GuideAnchors
11
+
12
+ def self.transform(html, guide_name)
13
+ html.gsub(/(<a\s+(?:[^<>]*\s+)?href=['"]#)([^!\/].*?)(['"])/i) do |m|
14
+ $1 + "!/guide/" + transform_id($2, guide_name) + $3
15
+
16
+ end.gsub(/(<a\s+(?:[^<>]*\s+)?name=['"])(.*?)(['"])/i) do |m|
17
+ $1 + transform_id($2, guide_name) + $3
18
+
19
+ end.gsub(/(<\w+\s+(?:[^<>]*\s+)?id=['"])(.*?)(['"])/i) do |m|
20
+ $1 + transform_id($2, guide_name) + $3
21
+ end
22
+ end
23
+
24
+ def self.transform_id(id, guide_name)
25
+ if id =~ /^#{guide_name}-section-/
26
+ id
27
+ else
28
+ # Escape the ID if it's not already escaped. This check is
29
+ # needed to avoid re-escaping anchor-links created with
30
+ # Markdown - these get auto-escaped by RDiscount.
31
+ id = (id =~ /%[0-9A-F]{2}/) ? id : CGI::escape(id)
32
+
33
+ "#{guide_name}-section-#{id}"
34
+ end
35
+ end
36
+
37
+ end
38
+
39
+ end
@@ -0,0 +1,68 @@
1
+ require 'jsduck/util/html'
2
+ require 'jsduck/guide_toc_entry'
3
+
4
+ module JsDuck
5
+
6
+ # Adds Table of Contents section to guide HTML.
7
+ class GuideToc
8
+ def initialize(html, guide_name, max_level=2)
9
+ @html = html
10
+ @guide_name = guide_name
11
+
12
+ @min_level = 2
13
+ @max_level = max_level
14
+
15
+ @toc = GuideTocEntry.new
16
+ @new_html = []
17
+ end
18
+
19
+ # Inserts table of contents at the top of guide HTML by looking
20
+ # for headings at or below the specified maximum level.
21
+ def inject!
22
+ @html.each_line do |line|
23
+ if line =~ /^\s*<h([1-6])>(.*?)<\/h[1-6]>$/
24
+ level = $1.to_i
25
+ original_text = $2
26
+ text = Util::HTML.strip_tags(original_text)
27
+ id = title_to_id(text)
28
+
29
+ if include_to_toc?(level)
30
+ @toc.add(level, id, text)
31
+ end
32
+
33
+ @new_html << "<h#{level} id='#{id}'>#{original_text}</h#{level}>\n"
34
+ else
35
+ @new_html << line
36
+ end
37
+ end
38
+
39
+ inject_toc!
40
+
41
+ @new_html.flatten.join
42
+ end
43
+
44
+ private
45
+
46
+ def include_to_toc?(level)
47
+ (@min_level..@max_level).include?(level)
48
+ end
49
+
50
+ def title_to_id(title)
51
+ @guide_name + "-section-" + CGI::escape(title.downcase.gsub(/ /, "-"))
52
+ end
53
+
54
+ # Injects TOC below first heading if at least 2 items in TOC
55
+ def inject_toc!
56
+ return if @toc.count < 2
57
+
58
+ @new_html.insert(1, [
59
+ "<div class='toc'>\n",
60
+ "<p><strong>Contents</strong></p>\n",
61
+ @toc.to_html,
62
+ "</div>\n",
63
+ ])
64
+ end
65
+
66
+ end
67
+
68
+ end
@@ -0,0 +1,54 @@
1
+ require 'jsduck/util/html'
2
+
3
+ module JsDuck
4
+
5
+ # Manages the single TOC entry (with possible subentries).
6
+ class GuideTocEntry
7
+ attr_accessor :label, :items
8
+
9
+ def initialize(parent=nil)
10
+ @parent = parent
11
+ @label = ""
12
+ @items = []
13
+ @min_level = 2
14
+ end
15
+
16
+ # Adds entry at the corresponding heading level.
17
+ def add(level, id, text)
18
+ if level == @min_level
19
+ @items << GuideTocEntry.new(self)
20
+ @items.last.label = "#{prefix} <a href='#!/guide/#{id}'>#{text}</a>\n"
21
+ else
22
+ if @items.empty?
23
+ @items << GuideTocEntry.new(self)
24
+ end
25
+ @items.last.add(level-1, id, text)
26
+ end
27
+ end
28
+
29
+ # Generates the heading counter, like "1.5.4."
30
+ def prefix
31
+ (@parent ? @parent.prefix : "") + "#{@items.length}."
32
+ end
33
+
34
+ # Total number of headings in TOC
35
+ def count
36
+ @items.map {|item| 1 + item.count}.reduce(0, :+)
37
+ end
38
+
39
+ # Converts to nested HTML list.
40
+ def to_html
41
+ return if @items.empty?
42
+
43
+ return [
44
+ "<ul>",
45
+ @items.map do |item|
46
+ "<li>#{item.label} #{item.to_html}</li>"
47
+ end,
48
+ "</ul>",
49
+ ].flatten.compact.join("\n")
50
+ end
51
+
52
+ end
53
+
54
+ end
@@ -0,0 +1,58 @@
1
+ require 'jsduck/util/parallel'
2
+ require 'jsduck/util/stdout'
3
+ require 'jsduck/util/json'
4
+ require 'jsduck/logger'
5
+ require 'fileutils'
6
+
7
+ module JsDuck
8
+
9
+ # Writes guide data into files in JSON or JSONP format or to STDOUT.
10
+ class GuideWriter
11
+ def initialize(exporter_class, guides, opts)
12
+ @guides = guides
13
+ @exporter = exporter_class.new(guides, opts)
14
+ end
15
+
16
+ # Writes guide data into given directory or STDOUT when dir == :stdout.
17
+ #
18
+ # Extension is either ".json" for normal JSON output
19
+ # or ".js" for JsonP output.
20
+ def write(dir, extension)
21
+ dir == :stdout ? write_stdout : write_dir(dir, extension)
22
+ end
23
+
24
+ private
25
+
26
+ def write_stdout
27
+ json = ParallelWrap.map(all_guides) {|guide| @exporter.export_guide(guide) }.compact
28
+ Util::Stdout.add(json)
29
+ end
30
+
31
+ def write_dir(dir, extension)
32
+ FileUtils.mkdir(dir) unless File.exists?(dir)
33
+ Util::Parallel.each(all_guides) do |guide|
34
+ filename = dir + "/" + guide["name"] + extension
35
+ Logger.log("Writing guide", filename)
36
+ json = @exporter.export_guide(guide)
37
+ # skip file if exporter returned nil
38
+ if json
39
+ if extension == ".json"
40
+ Util::Json.write_json(filename, json)
41
+ elsif extension == ".js"
42
+ Util::Json.write_jsonp(filename, guide["name"], json)
43
+ else
44
+ throw "Unexpected file extension: #{extension}"
45
+ end
46
+ end
47
+ end
48
+ end
49
+
50
+ def all_guides
51
+ arr = []
52
+ @guides.each_item {|g| arr << g }
53
+ arr
54
+ end
55
+
56
+ end
57
+
58
+ end
@@ -0,0 +1,188 @@
1
+ require 'jsduck/logger'
2
+ require 'jsduck/util/json'
3
+ require 'jsduck/util/io'
4
+ require 'jsduck/util/null_object'
5
+ require 'jsduck/logger'
6
+ require 'jsduck/grouped_asset'
7
+ require 'jsduck/guide_toc'
8
+ require 'jsduck/guide_anchors'
9
+ require 'jsduck/img/dir'
10
+ require 'fileutils'
11
+
12
+ module JsDuck
13
+
14
+ # Reads in guides and converts them to JsonP files
15
+ class Guides < GroupedAsset
16
+ # Creates Guides object from filename and formatter
17
+ def self.create(filename, formatter, opts)
18
+ if filename
19
+ Guides.new(filename, formatter, opts)
20
+ else
21
+ Util::NullObject.new(:to_array => [], :to_html => "", :[] => nil)
22
+ end
23
+ end
24
+
25
+ # Parses guides config file
26
+ def initialize(filename, formatter, opts)
27
+ @path = File.dirname(filename)
28
+ @groups = Util::Json.read(filename)
29
+ @formatter = formatter
30
+ @opts = opts
31
+ build_map_by_name
32
+ load_all_guides
33
+ end
34
+
35
+ # Writes all guides to given dir in JsonP format
36
+ def write(dir)
37
+ FileUtils.mkdir(dir) unless File.exists?(dir)
38
+ each_item {|guide| write_guide(guide, dir) }
39
+ end
40
+
41
+ def load_all_guides
42
+ each_item do |guide|
43
+ guide["url"] = resolve_url(guide)
44
+ guide[:dir] = resolve_dir(guide)
45
+ guide[:filename] = resolve_filename(guide)
46
+ guide[:html] = load_guide(guide)
47
+ end
48
+ end
49
+
50
+ # Modified to_array that excludes the :html from guide nodes
51
+ def to_array
52
+ map_items do |item|
53
+ Hash[item.select {|k, v| k != :html }]
54
+ end
55
+ end
56
+
57
+ def load_guide(guide)
58
+ unless File.exists?(guide[:dir])
59
+ return Logger.warn(:guide, "Guide not found", {:filename => guide[:dir]})
60
+ end
61
+ unless File.exists?(guide[:filename])
62
+ return Logger.warn(:guide, "Guide not found", {:filename => guide[:filename]})
63
+ end
64
+ unless js_ident?(guide["name"])
65
+ # Guide name is also used as JSONP callback method name.
66
+ return Logger.warn(:guide, "Guide name is not valid JS identifier: #{guide["name"]}", {:filename => guide[:filename]})
67
+ end
68
+
69
+ begin
70
+ return format_guide(guide)
71
+ rescue
72
+ Logger.fatal_backtrace("Error while reading/formatting guide #{guide[:filename]}", $!)
73
+ exit(1)
74
+ end
75
+ end
76
+
77
+ def format_guide(guide)
78
+ @formatter.doc_context = {:filename => guide[:filename], :linenr => 0}
79
+ @formatter.images = Img::Dir.new(guide[:dir], "guides/#{guide["name"]}")
80
+ html = @formatter.format(Util::IO.read(guide[:filename]))
81
+ html = GuideToc.new(html, guide['name'], @opts.guides_toc_level).inject!
82
+ html = GuideAnchors.transform(html, guide['name'])
83
+
84
+ # Report unused images (but ignore the icon files)
85
+ @formatter.images.get("icon.png")
86
+ @formatter.images.get("icon-lg.png")
87
+ @formatter.images.report_unused
88
+
89
+ return html
90
+ end
91
+
92
+ def write_guide(guide, dir)
93
+ return unless guide[:html]
94
+
95
+ out_dir = dir + "/" + guide["name"]
96
+
97
+ Logger.log("Writing guide", out_dir)
98
+ # Copy the whole guide dir over
99
+ FileUtils.cp_r(guide[:dir], out_dir)
100
+
101
+ # Ensure the guide has an icon
102
+ fix_icon(out_dir)
103
+
104
+ Util::Json.write_jsonp(out_dir+"/README.js", guide["name"], {:guide => guide[:html], :title => guide["title"]})
105
+ end
106
+
107
+ # Turns guide URL into full path.
108
+ # If no URL given at all, creates it from guide name.
109
+ def resolve_url(guide)
110
+ if guide["url"]
111
+ File.expand_path(guide["url"], @path)
112
+ else
113
+ @path + "/guides/" + guide["name"]
114
+ end
115
+ end
116
+
117
+ # Detects guide directory.
118
+ # The URL either points to a file or directory.
119
+ def resolve_dir(guide)
120
+ if File.file?(guide["url"])
121
+ File.expand_path("..", guide["url"])
122
+ else
123
+ guide["url"]
124
+ end
125
+ end
126
+
127
+ # Detects guide filename.
128
+ # Either use URL pointing to a file or look up README.md from directory.
129
+ def resolve_filename(guide)
130
+ if File.file?(guide["url"])
131
+ guide["url"]
132
+ else
133
+ guide[:dir] + "/README.md"
134
+ end
135
+ end
136
+
137
+ # True when string is valid JavaScript identifier
138
+ def js_ident?(str)
139
+ /\A[$\w]+\z/ =~ str
140
+ end
141
+
142
+ # Ensures the guide dir contains icon.png.
143
+ # When there isn't looks for icon-lg.png and renames it to icon.png.
144
+ # When neither exists, copies over default icon.
145
+ def fix_icon(dir)
146
+ if File.exists?(dir+"/icon.png")
147
+ # All ok
148
+ elsif File.exists?(dir+"/icon-lg.png")
149
+ FileUtils.mv(dir+"/icon-lg.png", dir+"/icon.png")
150
+ else
151
+ FileUtils.cp(@opts.template+"/resources/images/default-guide.png", dir+"/icon.png")
152
+ end
153
+ end
154
+
155
+ # Returns HTML listing of guides
156
+ def to_html(style="")
157
+ html = @groups.map do |group|
158
+ [
159
+ "<h3>#{group['title']}</h3>",
160
+ "<ul>",
161
+ flatten_subgroups(group["items"]).map {|g| "<li><a href='#!/guide/#{g['name']}'>#{g['title']}</a></li>" },
162
+ "</ul>",
163
+ ]
164
+ end.flatten.join("\n")
165
+
166
+ return <<-EOHTML
167
+ <div id='guides-content' style='#{style}'>
168
+ #{html}
169
+ </div>
170
+ EOHTML
171
+ end
172
+
173
+ def flatten_subgroups(items)
174
+ result = []
175
+ each_item(items) do |item|
176
+ result << item
177
+ end
178
+ result
179
+ end
180
+
181
+ # Extracts guide icon URL from guide hash
182
+ def icon_url(guide)
183
+ "guides/" + guide["name"] + "/icon.png"
184
+ end
185
+
186
+ end
187
+
188
+ end