help_kit 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (698) hide show
  1. checksums.yaml +7 -0
  2. data/MIT-LICENSE +20 -0
  3. data/README.rdoc +3 -0
  4. data/Rakefile +26 -0
  5. data/app/assets/images/help_kit/document.png +0 -0
  6. data/app/assets/javascripts/ace/ace.js +18298 -0
  7. data/app/assets/javascripts/ace/ext-beautify.js +334 -0
  8. data/app/assets/javascripts/ace/ext-chromevox.js +541 -0
  9. data/app/assets/javascripts/ace/ext-elastic_tabstops_lite.js +275 -0
  10. data/app/assets/javascripts/ace/ext-emmet.js +1190 -0
  11. data/app/assets/javascripts/ace/ext-error_marker.js +6 -0
  12. data/app/assets/javascripts/ace/ext-keybinding_menu.js +170 -0
  13. data/app/assets/javascripts/ace/ext-language_tools.js +1934 -0
  14. data/app/assets/javascripts/ace/ext-linking.js +52 -0
  15. data/app/assets/javascripts/ace/ext-modelist.js +187 -0
  16. data/app/assets/javascripts/ace/ext-old_ie.js +494 -0
  17. data/app/assets/javascripts/ace/ext-searchbox.js +409 -0
  18. data/app/assets/javascripts/ace/ext-settings_menu.js +637 -0
  19. data/app/assets/javascripts/ace/ext-spellcheck.js +71 -0
  20. data/app/assets/javascripts/ace/ext-split.js +246 -0
  21. data/app/assets/javascripts/ace/ext-static_highlight.js +154 -0
  22. data/app/assets/javascripts/ace/ext-statusbar.js +51 -0
  23. data/app/assets/javascripts/ace/ext-textarea.js +632 -0
  24. data/app/assets/javascripts/ace/ext-themelist.js +27 -0
  25. data/app/assets/javascripts/ace/ext-whitespace.js +181 -0
  26. data/app/assets/javascripts/ace/keybinding-emacs.js +1182 -0
  27. data/app/assets/javascripts/ace/keybinding-vim.js +5320 -0
  28. data/app/assets/javascripts/ace/mode-markdown.js +2795 -0
  29. data/app/assets/javascripts/ace/worker-coffee.js +7599 -0
  30. data/app/assets/javascripts/ace/worker-css.js +8682 -0
  31. data/app/assets/javascripts/ace/worker-html.js +11527 -0
  32. data/app/assets/javascripts/ace/worker-javascript.js +10429 -0
  33. data/app/assets/javascripts/ace/worker-json.js +2319 -0
  34. data/app/assets/javascripts/ace/worker-lua.js +3554 -0
  35. data/app/assets/javascripts/ace/worker-php.js +6947 -0
  36. data/app/assets/javascripts/ace/worker-xquery.js +49532 -0
  37. data/app/assets/javascripts/help_kit/application.js +12 -0
  38. data/app/assets/javascripts/help_kit/editor.js.coffee +37 -0
  39. data/app/assets/javascripts/help_kit/jquery.transit.min.js +1 -0
  40. data/app/assets/javascripts/help_kit/search.js.coffee +22 -0
  41. data/app/assets/javascripts/help_kit/setup.js.coffee +6 -0
  42. data/app/assets/javascripts/help_kit/theme-helpkit.js +128 -0
  43. data/app/assets/stylesheets/help_kit/admin/categories.scss +26 -0
  44. data/app/assets/stylesheets/help_kit/application.scss +27 -0
  45. data/app/assets/stylesheets/help_kit/article.scss +190 -0
  46. data/app/assets/stylesheets/help_kit/article_compiled.scss +9 -0
  47. data/app/assets/stylesheets/help_kit/base/_base.scss +25 -0
  48. data/app/assets/stylesheets/help_kit/base/_buttons.scss +12 -0
  49. data/app/assets/stylesheets/help_kit/base/_forms.scss +122 -0
  50. data/app/assets/stylesheets/help_kit/base/_grid-settings.scss +14 -0
  51. data/app/assets/stylesheets/help_kit/base/_lists.scss +31 -0
  52. data/app/assets/stylesheets/help_kit/base/_tables.scss +24 -0
  53. data/app/assets/stylesheets/help_kit/base/_typography.scss +105 -0
  54. data/app/assets/stylesheets/help_kit/base/_variables.scss +66 -0
  55. data/app/assets/stylesheets/help_kit/base/extends/_button.scss +22 -0
  56. data/app/assets/stylesheets/help_kit/base/extends/_clearfix.scss +3 -0
  57. data/app/assets/stylesheets/help_kit/base/extends/_errors.scss +11 -0
  58. data/app/assets/stylesheets/help_kit/base/extends/_flashes.scss +38 -0
  59. data/app/assets/stylesheets/help_kit/base/extends/_hide-text.scss +3 -0
  60. data/app/assets/stylesheets/help_kit/editor.scss +127 -0
  61. data/app/assets/stylesheets/help_kit/footer.scss +7 -0
  62. data/app/assets/stylesheets/help_kit/grid-list.scss +8 -0
  63. data/app/assets/stylesheets/help_kit/header.scss +134 -0
  64. data/app/assets/stylesheets/help_kit/landing.scss +68 -0
  65. data/app/assets/stylesheets/help_kit/letters.scss +31 -0
  66. data/app/assets/stylesheets/help_kit/mce.scss +0 -0
  67. data/app/assets/stylesheets/help_kit/page-container.scss +13 -0
  68. data/app/assets/stylesheets/help_kit/panel.scss +10 -0
  69. data/app/assets/stylesheets/help_kit/search.scss +0 -0
  70. data/app/assets/stylesheets/help_kit/select-style.scss +11 -0
  71. data/app/assets/stylesheets/help_kit/split-view.scss +69 -0
  72. data/app/assets/stylesheets/help_kit/syntax.scss +63 -0
  73. data/app/assets/stylesheets/tinymce/skins/light/content.inline.min.css +1 -0
  74. data/app/assets/stylesheets/tinymce/skins/light/content.min.css +1 -0
  75. data/app/assets/stylesheets/tinymce/skins/light/fonts/tinymce-small.eot +0 -0
  76. data/app/assets/stylesheets/tinymce/skins/light/fonts/tinymce-small.json +1043 -0
  77. data/app/assets/stylesheets/tinymce/skins/light/fonts/tinymce-small.svg +62 -0
  78. data/app/assets/stylesheets/tinymce/skins/light/fonts/tinymce-small.ttf +0 -0
  79. data/app/assets/stylesheets/tinymce/skins/light/fonts/tinymce-small.woff +0 -0
  80. data/app/assets/stylesheets/tinymce/skins/light/fonts/tinymce.eot +0 -0
  81. data/app/assets/stylesheets/tinymce/skins/light/fonts/tinymce.json +1191 -0
  82. data/app/assets/stylesheets/tinymce/skins/light/fonts/tinymce.svg +63 -0
  83. data/app/assets/stylesheets/tinymce/skins/light/fonts/tinymce.ttf +0 -0
  84. data/app/assets/stylesheets/tinymce/skins/light/fonts/tinymce.woff +0 -0
  85. data/app/assets/stylesheets/tinymce/skins/light/img/anchor.gif +0 -0
  86. data/app/assets/stylesheets/tinymce/skins/light/img/loader.gif +0 -0
  87. data/app/assets/stylesheets/tinymce/skins/light/img/object.gif +0 -0
  88. data/app/assets/stylesheets/tinymce/skins/light/img/trans.gif +0 -0
  89. data/app/assets/stylesheets/tinymce/skins/light/skin.ie7.min.css +1 -0
  90. data/app/assets/stylesheets/tinymce/skins/light/skin.min.css +28 -0
  91. data/app/controllers/help_kit/admin/categories_controller.rb +50 -0
  92. data/app/controllers/help_kit/admin/landing_controller.rb +10 -0
  93. data/app/controllers/help_kit/application_controller.rb +12 -0
  94. data/app/controllers/help_kit/articles_controller.rb +70 -0
  95. data/app/controllers/help_kit/landing_controller.rb +11 -0
  96. data/app/helpers/help_kit/application_helper.rb +4 -0
  97. data/app/helpers/help_kit/article_helper.rb +36 -0
  98. data/app/helpers/help_kit/category_helper.rb +9 -0
  99. data/app/helpers/help_kit/nested_set_helper.rb +35 -0
  100. data/app/helpers/help_kit/split_view_helper.rb +11 -0
  101. data/app/models/help_kit/article.rb +31 -0
  102. data/app/models/help_kit/article_tag.rb +6 -0
  103. data/app/models/help_kit/category.rb +19 -0
  104. data/app/models/help_kit/tag.rb +4 -0
  105. data/app/views/help_kit/_categories_panel.html.slim +8 -0
  106. data/app/views/help_kit/_nav.html.slim +12 -0
  107. data/app/views/help_kit/admin/_nav.html.slim +5 -0
  108. data/app/views/help_kit/admin/categories/_form.html.slim +10 -0
  109. data/app/views/help_kit/admin/categories/edit.html.slim +7 -0
  110. data/app/views/help_kit/admin/categories/index.html.slim +9 -0
  111. data/app/views/help_kit/admin/categories/new.html.slim +3 -0
  112. data/app/views/help_kit/admin/landing/land.html.slim +17 -0
  113. data/app/views/help_kit/articles/_article.html.slim +6 -0
  114. data/app/views/help_kit/articles/_form.html.slim +22 -0
  115. data/app/views/help_kit/articles/edit.html.slim +1 -0
  116. data/app/views/help_kit/articles/index_category.html.slim +44 -0
  117. data/app/views/help_kit/articles/new.html.slim +1 -0
  118. data/app/views/help_kit/articles/not_found.html.slim +4 -0
  119. data/app/views/help_kit/articles/search.html.slim +11 -0
  120. data/app/views/help_kit/articles/show.html.slim +24 -0
  121. data/app/views/help_kit/landing/land.html.slim +16 -0
  122. data/app/views/layouts/help_kit/admin.html.slim +18 -0
  123. data/app/views/layouts/help_kit/application.html.slim +13 -0
  124. data/app/views/layouts/help_kit/minimal.html.slim +19 -0
  125. data/config/cucumber.yml +8 -0
  126. data/config/environment.rb +0 -0
  127. data/config/initializers/simple_form.rb +166 -0
  128. data/config/locales/simple_form.en.yml +31 -0
  129. data/config/routes.rb +21 -0
  130. data/config/spring.rb +1 -0
  131. data/config/tinymce.yml +0 -0
  132. data/db/migrate/20150125225416_create_help_kit_articles.rb +18 -0
  133. data/db/migrate/20150126022104_create_help_kit_categories.rb +15 -0
  134. data/db/migrate/20150127175303_create_help_kit_tags.rb +8 -0
  135. data/db/migrate/20150127175326_create_help_kit_article_tags.rb +9 -0
  136. data/lib/generators/help_kit/install/USAGE +8 -0
  137. data/lib/generators/help_kit/install/install_generator.rb +34 -0
  138. data/lib/generators/help_kit/install/templates/help_kit.rb +13 -0
  139. data/lib/help_kit/configuration.rb +25 -0
  140. data/lib/help_kit/engine.rb +12 -0
  141. data/lib/help_kit/version.rb +3 -0
  142. data/lib/help_kit.rb +19 -0
  143. data/lib/tasks/cucumber.rake +65 -0
  144. data/lib/tasks/help_kit_tasks.rake +4 -0
  145. data/lib/templates/erb/scaffold/_form.html.erb +13 -0
  146. data/spec/controllers/help_kit/admin/categories_controller_spec.rb +82 -0
  147. data/spec/controllers/help_kit/admin/landing_controller_spec.rb +7 -0
  148. data/spec/controllers/help_kit/articles_controller_spec.rb +89 -0
  149. data/spec/controllers/help_kit/landing_controller_spec.rb +11 -0
  150. data/spec/dummy/README.rdoc +28 -0
  151. data/spec/dummy/Rakefile +6 -0
  152. data/spec/dummy/app/assets/javascripts/application.js +13 -0
  153. data/spec/dummy/app/assets/stylesheets/application.css +15 -0
  154. data/spec/dummy/app/controllers/application_controller.rb +5 -0
  155. data/spec/dummy/app/helpers/application_helper.rb +2 -0
  156. data/spec/dummy/app/views/layouts/application.html.erb +14 -0
  157. data/spec/dummy/bin/bundle +3 -0
  158. data/spec/dummy/bin/rails +4 -0
  159. data/spec/dummy/bin/rake +4 -0
  160. data/spec/dummy/bin/setup +29 -0
  161. data/spec/dummy/config/application.rb +32 -0
  162. data/spec/dummy/config/boot.rb +5 -0
  163. data/spec/dummy/config/database.yml +25 -0
  164. data/spec/dummy/config/environment.rb +5 -0
  165. data/spec/dummy/config/environments/development.rb +41 -0
  166. data/spec/dummy/config/environments/production.rb +79 -0
  167. data/spec/dummy/config/environments/test.rb +42 -0
  168. data/spec/dummy/config/initializers/assets.rb +14 -0
  169. data/spec/dummy/config/initializers/backtrace_silencers.rb +7 -0
  170. data/spec/dummy/config/initializers/cookies_serializer.rb +3 -0
  171. data/spec/dummy/config/initializers/filter_parameter_logging.rb +4 -0
  172. data/spec/dummy/config/initializers/inflections.rb +16 -0
  173. data/spec/dummy/config/initializers/mime_types.rb +4 -0
  174. data/spec/dummy/config/initializers/session_store.rb +3 -0
  175. data/spec/dummy/config/initializers/wrap_parameters.rb +14 -0
  176. data/spec/dummy/config/locales/en.yml +23 -0
  177. data/spec/dummy/config/routes.rb +3 -0
  178. data/spec/dummy/config/secrets.yml +22 -0
  179. data/spec/dummy/config.ru +4 -0
  180. data/spec/dummy/db/development.sqlite3 +0 -0
  181. data/spec/dummy/db/schema.rb +68 -0
  182. data/spec/dummy/db/test.sqlite3 +0 -0
  183. data/spec/dummy/log/development.log +53888 -0
  184. data/spec/dummy/log/test.log +30051 -0
  185. data/spec/dummy/public/404.html +67 -0
  186. data/spec/dummy/public/422.html +67 -0
  187. data/spec/dummy/public/500.html +66 -0
  188. data/spec/dummy/public/favicon.ico +0 -0
  189. data/spec/dummy/tmp/cache/assets/development/sass/0d3bb099e8e0056ccac56c343fb7341c91e9c992/categories.scssc +0 -0
  190. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/animate.cssc +0 -0
  191. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/application.scssc +0 -0
  192. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/article.scssc +0 -0
  193. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/article_compiled.scssc +0 -0
  194. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/editor.scssc +0 -0
  195. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/footer.scssc +0 -0
  196. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/grid-list.scssc +0 -0
  197. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/header.scssc +0 -0
  198. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/landing.scssc +0 -0
  199. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/letters.scssc +0 -0
  200. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/markdown-editor.scssc +0 -0
  201. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/mce.scssc +0 -0
  202. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/page-container.scssc +0 -0
  203. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/panel.scssc +0 -0
  204. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/search.scssc +0 -0
  205. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/select-style.scssc +0 -0
  206. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/split-view.scssc +0 -0
  207. data/spec/dummy/tmp/cache/assets/development/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/syntax.scssc +0 -0
  208. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_convert-units.scssc +0 -0
  209. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_font-source-declaration.scssc +0 -0
  210. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_gradient-positions-parser.scssc +0 -0
  211. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_is-num.scssc +0 -0
  212. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_linear-angle-parser.scssc +0 -0
  213. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_linear-gradient-parser.scssc +0 -0
  214. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_linear-positions-parser.scssc +0 -0
  215. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_linear-side-corner-parser.scssc +0 -0
  216. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_radial-arg-parser.scssc +0 -0
  217. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_radial-gradient-parser.scssc +0 -0
  218. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_radial-positions-parser.scssc +0 -0
  219. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_render-gradients.scssc +0 -0
  220. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_shape-size-stripper.scssc +0 -0
  221. data/spec/dummy/tmp/cache/assets/development/sass/21897887c135c22242c9476c1971de2e0a627603/_str-to-num.scssc +0 -0
  222. data/spec/dummy/tmp/cache/assets/development/sass/244631e88695b211242390bcc493664cef774d81/select2.scssc +0 -0
  223. data/spec/dummy/tmp/cache/assets/development/sass/2e17bfbf712510db989a7a9d948409e0daf0a470/_font-awesome-sprockets.scssc +0 -0
  224. data/spec/dummy/tmp/cache/assets/development/sass/2e17bfbf712510db989a7a9d948409e0daf0a470/font-awesome.scssc +0 -0
  225. data/spec/dummy/tmp/cache/assets/development/sass/4fde2a2066018d97e8118d0177bd15bcb068e75b/_button.scssc +0 -0
  226. data/spec/dummy/tmp/cache/assets/development/sass/4fde2a2066018d97e8118d0177bd15bcb068e75b/_clearfix.scssc +0 -0
  227. data/spec/dummy/tmp/cache/assets/development/sass/4fde2a2066018d97e8118d0177bd15bcb068e75b/_errors.scssc +0 -0
  228. data/spec/dummy/tmp/cache/assets/development/sass/4fde2a2066018d97e8118d0177bd15bcb068e75b/_flashes.scssc +0 -0
  229. data/spec/dummy/tmp/cache/assets/development/sass/4fde2a2066018d97e8118d0177bd15bcb068e75b/_hide-text.scssc +0 -0
  230. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_box-sizing.scssc +0 -0
  231. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_direction-context.scssc +0 -0
  232. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_display-context.scssc +0 -0
  233. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_fill-parent.scssc +0 -0
  234. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_media.scssc +0 -0
  235. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_omega.scssc +0 -0
  236. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_outer-container.scssc +0 -0
  237. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_pad.scssc +0 -0
  238. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_private.scssc +0 -0
  239. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_row.scssc +0 -0
  240. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_shift.scssc +0 -0
  241. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_span-columns.scssc +0 -0
  242. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_to-deprecate.scssc +0 -0
  243. data/spec/dummy/tmp/cache/assets/development/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_visual-grid.scssc +0 -0
  244. data/spec/dummy/tmp/cache/assets/development/sass/5f072aa349cba3af993607d769833b63b75d973f/_neat-helpers.scssc +0 -0
  245. data/spec/dummy/tmp/cache/assets/development/sass/5f072aa349cba3af993607d769833b63b75d973f/_neat.scssc +0 -0
  246. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_assign.scssc +0 -0
  247. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_color-lightness.scssc +0 -0
  248. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_contains.scssc +0 -0
  249. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_is-length.scssc +0 -0
  250. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_is-size.scssc +0 -0
  251. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_modular-scale.scssc +0 -0
  252. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_px-to-em.scssc +0 -0
  253. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_px-to-rem.scssc +0 -0
  254. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_strip-units.scssc +0 -0
  255. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_tint-shade.scssc +0 -0
  256. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_transition-property-name.scssc +0 -0
  257. data/spec/dummy/tmp/cache/assets/development/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_unpack.scssc +0 -0
  258. data/spec/dummy/tmp/cache/assets/development/sass/800ef82c27431a5e8e7dede5cd1112743adf0272/_asset-pipeline.scssc +0 -0
  259. data/spec/dummy/tmp/cache/assets/development/sass/800ef82c27431a5e8e7dede5cd1112743adf0272/_prefixer.scssc +0 -0
  260. data/spec/dummy/tmp/cache/assets/development/sass/800ef82c27431a5e8e7dede5cd1112743adf0272/_px-to-em.scssc +0 -0
  261. data/spec/dummy/tmp/cache/assets/development/sass/856fe6b0529058df9e65517cc7a3b24c088cfaad/animate.scssc +0 -0
  262. data/spec/dummy/tmp/cache/assets/development/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_base.scssc +0 -0
  263. data/spec/dummy/tmp/cache/assets/development/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_buttons.scssc +0 -0
  264. data/spec/dummy/tmp/cache/assets/development/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_forms.scssc +0 -0
  265. data/spec/dummy/tmp/cache/assets/development/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_lists.scssc +0 -0
  266. data/spec/dummy/tmp/cache/assets/development/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_tables.scssc +0 -0
  267. data/spec/dummy/tmp/cache/assets/development/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_typography.scssc +0 -0
  268. data/spec/dummy/tmp/cache/assets/development/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_variables.scssc +0 -0
  269. data/spec/dummy/tmp/cache/assets/development/sass/8f9db07624af1fb4dfc64b147edea1752ccd6654/_mixins.scssc +0 -0
  270. data/spec/dummy/tmp/cache/assets/development/sass/8f9db07624af1fb4dfc64b147edea1752ccd6654/fadeInUp.scssc +0 -0
  271. data/spec/dummy/tmp/cache/assets/development/sass/8f9db07624af1fb4dfc64b147edea1752ccd6654/pulse.scssc +0 -0
  272. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_bordered-pulled.scssc +0 -0
  273. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_core.scssc +0 -0
  274. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_fixed-width.scssc +0 -0
  275. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_icons.scssc +0 -0
  276. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_larger.scssc +0 -0
  277. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_list.scssc +0 -0
  278. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_mixins.scssc +0 -0
  279. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_path.scssc +0 -0
  280. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_rotated-flipped.scssc +0 -0
  281. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_spinning.scssc +0 -0
  282. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_stacked.scssc +0 -0
  283. data/spec/dummy/tmp/cache/assets/development/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_variables.scssc +0 -0
  284. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_clearfix.scssc +0 -0
  285. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_directional-values.scssc +0 -0
  286. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_ellipsis.scssc +0 -0
  287. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_font-family.scssc +0 -0
  288. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_hide-text.scssc +0 -0
  289. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_html5-input-types.scssc +0 -0
  290. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_position.scssc +0 -0
  291. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_prefixer.scssc +0 -0
  292. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_retina-image.scssc +0 -0
  293. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_size.scssc +0 -0
  294. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_timing-functions.scssc +0 -0
  295. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_triangle.scssc +0 -0
  296. data/spec/dummy/tmp/cache/assets/development/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_word-wrap.scssc +0 -0
  297. data/spec/dummy/tmp/cache/assets/development/sass/bb516d13fd357410818971f9df2770c51e6cd834/_bourbon-deprecated-upcoming.scssc +0 -0
  298. data/spec/dummy/tmp/cache/assets/development/sass/bb516d13fd357410818971f9df2770c51e6cd834/_bourbon.scssc +0 -0
  299. data/spec/dummy/tmp/cache/assets/development/sass/e59ef1973131d8342e52dc165d6e4d0bdaa69ace/_disable-warnings.scssc +0 -0
  300. data/spec/dummy/tmp/cache/assets/development/sass/e59ef1973131d8342e52dc165d6e4d0bdaa69ace/_grid.scssc +0 -0
  301. data/spec/dummy/tmp/cache/assets/development/sass/e59ef1973131d8342e52dc165d6e4d0bdaa69ace/_visual-grid.scssc +0 -0
  302. data/spec/dummy/tmp/cache/assets/development/sass/ee9bebb508864c86a7d2ff5dda1e1d579851f483/_new-breakpoint.scssc +0 -0
  303. data/spec/dummy/tmp/cache/assets/development/sass/ee9bebb508864c86a7d2ff5dda1e1d579851f483/_private.scssc +0 -0
  304. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_animation.scssc +0 -0
  305. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_appearance.scssc +0 -0
  306. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_backface-visibility.scssc +0 -0
  307. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_background-image.scssc +0 -0
  308. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_background.scssc +0 -0
  309. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_border-image.scssc +0 -0
  310. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_border-radius.scssc +0 -0
  311. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_box-sizing.scssc +0 -0
  312. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_calc.scssc +0 -0
  313. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_columns.scssc +0 -0
  314. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_filter.scssc +0 -0
  315. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_flex-box.scssc +0 -0
  316. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_font-face.scssc +0 -0
  317. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_font-feature-settings.scssc +0 -0
  318. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_hidpi-media-query.scssc +0 -0
  319. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_hyphens.scssc +0 -0
  320. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_image-rendering.scssc +0 -0
  321. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_keyframes.scssc +0 -0
  322. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_linear-gradient.scssc +0 -0
  323. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_perspective.scssc +0 -0
  324. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_placeholder.scssc +0 -0
  325. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_radial-gradient.scssc +0 -0
  326. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_selection.scssc +0 -0
  327. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_text-decoration.scssc +0 -0
  328. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_transform.scssc +0 -0
  329. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_transition.scssc +0 -0
  330. data/spec/dummy/tmp/cache/assets/development/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_user-select.scssc +0 -0
  331. data/spec/dummy/tmp/cache/assets/development/sprockets/019aeb3134fdd78de698ede9adfbfbdc +0 -0
  332. data/spec/dummy/tmp/cache/assets/development/sprockets/03101dacc7eccff540d7f72fb4be638f +0 -0
  333. data/spec/dummy/tmp/cache/assets/development/sprockets/0843c4389b6013a5f137b654692c134d +0 -0
  334. data/spec/dummy/tmp/cache/assets/development/sprockets/0a034e389f9e386eed13d467b63eca9b +0 -0
  335. data/spec/dummy/tmp/cache/assets/development/sprockets/132fac315f2cd452773eeb9b16f0c252 +0 -0
  336. data/spec/dummy/tmp/cache/assets/development/sprockets/147a279fafc653659d4dbb629bfd87fa +0 -0
  337. data/spec/dummy/tmp/cache/assets/development/sprockets/184771a4bb5b4018f686d13599c76a1b +0 -0
  338. data/spec/dummy/tmp/cache/assets/development/sprockets/23ab5f71ceee14962894e140418de7c8 +0 -0
  339. data/spec/dummy/tmp/cache/assets/development/sprockets/271428fa9680546a677df7e4bcbde105 +0 -0
  340. data/spec/dummy/tmp/cache/assets/development/sprockets/2a01c0a73383e8a3af902df0223002df +0 -0
  341. data/spec/dummy/tmp/cache/assets/development/sprockets/2a8068367c493612b87f56b532784e4a +0 -0
  342. data/spec/dummy/tmp/cache/assets/development/sprockets/2dfa93f86f6fee26011ddaaffeb07134 +0 -0
  343. data/spec/dummy/tmp/cache/assets/development/sprockets/2ffdde0bdc703f1ede876a2d3a19d0c2 +0 -0
  344. data/spec/dummy/tmp/cache/assets/development/sprockets/30c612db75d611a11eb7b985fbbee407 +0 -0
  345. data/spec/dummy/tmp/cache/assets/development/sprockets/33042f7146d2e1bc3d0e0c9825028fea +0 -0
  346. data/spec/dummy/tmp/cache/assets/development/sprockets/34358387582f33147e74bd1add1ef28d +0 -0
  347. data/spec/dummy/tmp/cache/assets/development/sprockets/3c8761be81616e52c223148f63707110 +0 -0
  348. data/spec/dummy/tmp/cache/assets/development/sprockets/3d3249ad83b434dab3b1cef3f529fac1 +0 -0
  349. data/spec/dummy/tmp/cache/assets/development/sprockets/3eb9e9c1f817e957c408e61b6274fe7b +0 -0
  350. data/spec/dummy/tmp/cache/assets/development/sprockets/4016d0f2e2f7e95f143a7e40ef14aa05 +0 -0
  351. data/spec/dummy/tmp/cache/assets/development/sprockets/41c9080eac325030cbffdabd727b453b +0 -0
  352. data/spec/dummy/tmp/cache/assets/development/sprockets/42ccf00a802600f6d8301c0877891a20 +0 -0
  353. data/spec/dummy/tmp/cache/assets/development/sprockets/42e8b34cb06ce5db17f8d345b332e82c +0 -0
  354. data/spec/dummy/tmp/cache/assets/development/sprockets/4417519ab3db751c162c1c5e7b8cfe6c +0 -0
  355. data/spec/dummy/tmp/cache/assets/development/sprockets/46756daeca4990181368563e56567798 +0 -0
  356. data/spec/dummy/tmp/cache/assets/development/sprockets/474e9b79f043250454c330139ca7720f +0 -0
  357. data/spec/dummy/tmp/cache/assets/development/sprockets/476fb3a0575bcb1c383ad3da96d669e6 +0 -0
  358. data/spec/dummy/tmp/cache/assets/development/sprockets/48edc54aa0279f48d542e74d9d89385f +0 -0
  359. data/spec/dummy/tmp/cache/assets/development/sprockets/4b5e98e5f4ee4155c498aeb2e78fd7ad +0 -0
  360. data/spec/dummy/tmp/cache/assets/development/sprockets/4b8ea67669c90c509d44f3fe30166e8f +0 -0
  361. data/spec/dummy/tmp/cache/assets/development/sprockets/52036693d79c59051871d1937493d038 +0 -0
  362. data/spec/dummy/tmp/cache/assets/development/sprockets/5a8880919ea2b091871d7aaf2fbba790 +0 -0
  363. data/spec/dummy/tmp/cache/assets/development/sprockets/616a688fb83ce1b7e95fb37c4a10c55e +0 -0
  364. data/spec/dummy/tmp/cache/assets/development/sprockets/63b79bd2b49acba39e87e5419f5ffbee +0 -0
  365. data/spec/dummy/tmp/cache/assets/development/sprockets/64ecd5e12ba375f943811887a960a5a6 +0 -0
  366. data/spec/dummy/tmp/cache/assets/development/sprockets/657a32e9c34778ff17c610836446e7de +0 -0
  367. data/spec/dummy/tmp/cache/assets/development/sprockets/67a7bc75232f8ca67e8f37bfdff465fb +0 -0
  368. data/spec/dummy/tmp/cache/assets/development/sprockets/693a5efc9bd166e00a2a496da6bdaa72 +0 -0
  369. data/spec/dummy/tmp/cache/assets/development/sprockets/696e357a65aa75d4a11a28ee05c05f74 +0 -0
  370. data/spec/dummy/tmp/cache/assets/development/sprockets/6e46ff592b0879679cf68ea349ef7445 +0 -0
  371. data/spec/dummy/tmp/cache/assets/development/sprockets/6e94dd36b26d1cae7804c84cafcab5f1 +0 -0
  372. data/spec/dummy/tmp/cache/assets/development/sprockets/6e984869c4433f9f747d062449542d29 +0 -0
  373. data/spec/dummy/tmp/cache/assets/development/sprockets/6f82cc626c6a6de929b2215d1a7ce98d +0 -0
  374. data/spec/dummy/tmp/cache/assets/development/sprockets/6f9cafe827f3b8be5d361a831deaa4f5 +0 -0
  375. data/spec/dummy/tmp/cache/assets/development/sprockets/73bf227c1520737290f1fa0f7221eaa4 +0 -0
  376. data/spec/dummy/tmp/cache/assets/development/sprockets/7458e7120fb79da0706ef33577ca0df9 +0 -0
  377. data/spec/dummy/tmp/cache/assets/development/sprockets/753cd25f4ff4721c3ec0da73aab8c2c7 +0 -0
  378. data/spec/dummy/tmp/cache/assets/development/sprockets/77ba2da37cc9d507cb5de9a78ff996a5 +0 -0
  379. data/spec/dummy/tmp/cache/assets/development/sprockets/7dd998c8cf01206d6d2b2ae0573caa1a +0 -0
  380. data/spec/dummy/tmp/cache/assets/development/sprockets/821724e68622ca85cbd026e1448ea0c1 +0 -0
  381. data/spec/dummy/tmp/cache/assets/development/sprockets/86e8dd132bf93da9aebbe888137351b1 +0 -0
  382. data/spec/dummy/tmp/cache/assets/development/sprockets/87a2d008eb2142f7f721cfb9bab54059 +0 -0
  383. data/spec/dummy/tmp/cache/assets/development/sprockets/8c0df32e074c495e4ebe39870f17c57d +0 -0
  384. data/spec/dummy/tmp/cache/assets/development/sprockets/8e9170ff4a2be091fa213edae95756fa +0 -0
  385. data/spec/dummy/tmp/cache/assets/development/sprockets/8f2b30fa187391691df48564d657b627 +0 -0
  386. data/spec/dummy/tmp/cache/assets/development/sprockets/91133e15d88a7a0b850ca8d0b7573ea7 +0 -0
  387. data/spec/dummy/tmp/cache/assets/development/sprockets/92a5f6368e4390b41127ea66d943de7a +0 -0
  388. data/spec/dummy/tmp/cache/assets/development/sprockets/947d965b51971837cc4e6e9b44a11433 +0 -0
  389. data/spec/dummy/tmp/cache/assets/development/sprockets/97dad88000aa26c14116c65a658cd215 +0 -0
  390. data/spec/dummy/tmp/cache/assets/development/sprockets/97facb749457ae635640f9639dc589c6 +0 -0
  391. data/spec/dummy/tmp/cache/assets/development/sprockets/9d499737fd316127bf92c456cb1d760e +0 -0
  392. data/spec/dummy/tmp/cache/assets/development/sprockets/9f901d29334fc2b815bf10639fcc8bb4 +0 -0
  393. data/spec/dummy/tmp/cache/assets/development/sprockets/9fc050356bfaab94b793b2ceb6affd4e +0 -0
  394. data/spec/dummy/tmp/cache/assets/development/sprockets/ac3cbb82e36a366b69c942cb88280fba +0 -0
  395. data/spec/dummy/tmp/cache/assets/development/sprockets/ad721a7cf7d8274a7855503db2cbfca9 +0 -0
  396. data/spec/dummy/tmp/cache/assets/development/sprockets/b2106f09f4d7c6c3d1db360734710a77 +0 -0
  397. data/spec/dummy/tmp/cache/assets/development/sprockets/b307359cf1391d4878940a127fc0b997 +0 -0
  398. data/spec/dummy/tmp/cache/assets/development/sprockets/b806db361593cfa374bdcba73ae166ad +0 -0
  399. data/spec/dummy/tmp/cache/assets/development/sprockets/b8968c5bc08cd3eba486f2273b3065ca +0 -0
  400. data/spec/dummy/tmp/cache/assets/development/sprockets/b9367f070bcc853b554a8935a680dc9b +0 -0
  401. data/spec/dummy/tmp/cache/assets/development/sprockets/bbf1a0e5594ec85aaddd166c15d1ce0b +0 -0
  402. data/spec/dummy/tmp/cache/assets/development/sprockets/bd7b50d32b72f25de513ac8c81d4bfe3 +0 -0
  403. data/spec/dummy/tmp/cache/assets/development/sprockets/bfaaed33c2fe23615b6578c5ab0748a5 +0 -0
  404. data/spec/dummy/tmp/cache/assets/development/sprockets/c025f89c8a7b6376e5905b5549d389dc +0 -0
  405. data/spec/dummy/tmp/cache/assets/development/sprockets/c58679b7d874d70ad057b535e683dcf7 +0 -0
  406. data/spec/dummy/tmp/cache/assets/development/sprockets/c7275b0849d6d311942825352a53d7c4 +0 -0
  407. data/spec/dummy/tmp/cache/assets/development/sprockets/caf69a39dec4d229d1bdaad625487b5e +0 -0
  408. data/spec/dummy/tmp/cache/assets/development/sprockets/cbb9c9bbdc42a4008f6654a18170c347 +0 -0
  409. data/spec/dummy/tmp/cache/assets/development/sprockets/d7255f25985ae92f393128a739909d41 +0 -0
  410. data/spec/dummy/tmp/cache/assets/development/sprockets/d8fa391c2c8b5f04a475e4f121255a78 +0 -0
  411. data/spec/dummy/tmp/cache/assets/development/sprockets/d91f091f2783fa5b235d916f37dbe712 +0 -0
  412. data/spec/dummy/tmp/cache/assets/development/sprockets/dbd0051783820dad8df9d0140e5a8c5e +0 -0
  413. data/spec/dummy/tmp/cache/assets/development/sprockets/defb2ad7c8de02b212dab567250f3dc3 +0 -0
  414. data/spec/dummy/tmp/cache/assets/development/sprockets/e124a21cd8277a401fc323f56c9d0a94 +0 -0
  415. data/spec/dummy/tmp/cache/assets/development/sprockets/e2f0bc2cea1d910d81a875a0f928eeb7 +0 -0
  416. data/spec/dummy/tmp/cache/assets/development/sprockets/e4bcefdc5beecfc84ca87347f19f272e +0 -0
  417. data/spec/dummy/tmp/cache/assets/development/sprockets/e788e0e691556b12715eb6004a300baa +0 -0
  418. data/spec/dummy/tmp/cache/assets/development/sprockets/eb2fe377661545628b0015a0f67db610 +0 -0
  419. data/spec/dummy/tmp/cache/assets/development/sprockets/eeac0c5fc852f3de4cbcb8f4895836cc +0 -0
  420. data/spec/dummy/tmp/cache/assets/development/sprockets/ef51f7ec3bf08ea734dafa2a026a72d7 +0 -0
  421. data/spec/dummy/tmp/cache/assets/development/sprockets/f0f11a45021a52d9a987c3b35a71dafb +0 -0
  422. data/spec/dummy/tmp/cache/assets/development/sprockets/f1ecd46774cb4e5411b90c2880ae015b +0 -0
  423. data/spec/dummy/tmp/cache/assets/development/sprockets/f3540fd995f1201663e6e38a9cd5682a +0 -0
  424. data/spec/dummy/tmp/cache/assets/development/sprockets/f38575ec37bc7fb441a20eb9fed55302 +0 -0
  425. data/spec/dummy/tmp/cache/assets/development/sprockets/f39bc74ba945424222a09f0df3943958 +0 -0
  426. data/spec/dummy/tmp/cache/assets/development/sprockets/f7d27ceb184b291e77a8d5fa663d0ee0 +0 -0
  427. data/spec/dummy/tmp/cache/assets/development/sprockets/f857d672c0da6a74749cffb5b18dc673 +0 -0
  428. data/spec/dummy/tmp/cache/assets/development/sprockets/f903dbacbb12ae7cc80dfb5530894fc1 +0 -0
  429. data/spec/dummy/tmp/cache/assets/development/sprockets/f90aeb884f9f222145bc08b08d9c04e2 +0 -0
  430. data/spec/dummy/tmp/cache/assets/development/sprockets/fb5a75810bdc7f107cfcc321793d4774 +0 -0
  431. data/spec/dummy/tmp/cache/assets/test/sass/0d3bb099e8e0056ccac56c343fb7341c91e9c992/categories.scssc +0 -0
  432. data/spec/dummy/tmp/cache/assets/test/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/application.scssc +0 -0
  433. data/spec/dummy/tmp/cache/assets/test/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/article.scssc +0 -0
  434. data/spec/dummy/tmp/cache/assets/test/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/footer.scssc +0 -0
  435. data/spec/dummy/tmp/cache/assets/test/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/letters.scssc +0 -0
  436. data/spec/dummy/tmp/cache/assets/test/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/mce.scssc +0 -0
  437. data/spec/dummy/tmp/cache/assets/test/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/page-container.scssc +0 -0
  438. data/spec/dummy/tmp/cache/assets/test/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/panel.scssc +0 -0
  439. data/spec/dummy/tmp/cache/assets/test/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/select-style.scssc +0 -0
  440. data/spec/dummy/tmp/cache/assets/test/sass/11f412754660a6bb45a0dbc44b48d29f3848c9d4/split-view.scssc +0 -0
  441. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_convert-units.scssc +0 -0
  442. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_font-source-declaration.scssc +0 -0
  443. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_gradient-positions-parser.scssc +0 -0
  444. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_is-num.scssc +0 -0
  445. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_linear-angle-parser.scssc +0 -0
  446. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_linear-gradient-parser.scssc +0 -0
  447. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_linear-positions-parser.scssc +0 -0
  448. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_linear-side-corner-parser.scssc +0 -0
  449. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_radial-arg-parser.scssc +0 -0
  450. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_radial-gradient-parser.scssc +0 -0
  451. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_radial-positions-parser.scssc +0 -0
  452. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_render-gradients.scssc +0 -0
  453. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_shape-size-stripper.scssc +0 -0
  454. data/spec/dummy/tmp/cache/assets/test/sass/21897887c135c22242c9476c1971de2e0a627603/_str-to-num.scssc +0 -0
  455. data/spec/dummy/tmp/cache/assets/test/sass/244631e88695b211242390bcc493664cef774d81/select2.scssc +0 -0
  456. data/spec/dummy/tmp/cache/assets/test/sass/2e17bfbf712510db989a7a9d948409e0daf0a470/_font-awesome-sprockets.scssc +0 -0
  457. data/spec/dummy/tmp/cache/assets/test/sass/2e17bfbf712510db989a7a9d948409e0daf0a470/font-awesome.scssc +0 -0
  458. data/spec/dummy/tmp/cache/assets/test/sass/4fde2a2066018d97e8118d0177bd15bcb068e75b/_button.scssc +0 -0
  459. data/spec/dummy/tmp/cache/assets/test/sass/4fde2a2066018d97e8118d0177bd15bcb068e75b/_clearfix.scssc +0 -0
  460. data/spec/dummy/tmp/cache/assets/test/sass/4fde2a2066018d97e8118d0177bd15bcb068e75b/_errors.scssc +0 -0
  461. data/spec/dummy/tmp/cache/assets/test/sass/4fde2a2066018d97e8118d0177bd15bcb068e75b/_flashes.scssc +0 -0
  462. data/spec/dummy/tmp/cache/assets/test/sass/4fde2a2066018d97e8118d0177bd15bcb068e75b/_hide-text.scssc +0 -0
  463. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_box-sizing.scssc +0 -0
  464. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_direction-context.scssc +0 -0
  465. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_display-context.scssc +0 -0
  466. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_fill-parent.scssc +0 -0
  467. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_media.scssc +0 -0
  468. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_omega.scssc +0 -0
  469. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_outer-container.scssc +0 -0
  470. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_pad.scssc +0 -0
  471. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_private.scssc +0 -0
  472. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_row.scssc +0 -0
  473. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_shift.scssc +0 -0
  474. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_span-columns.scssc +0 -0
  475. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_to-deprecate.scssc +0 -0
  476. data/spec/dummy/tmp/cache/assets/test/sass/514fcf3422fd03a7dcba00abf68f4edf84785b89/_visual-grid.scssc +0 -0
  477. data/spec/dummy/tmp/cache/assets/test/sass/5f072aa349cba3af993607d769833b63b75d973f/_neat-helpers.scssc +0 -0
  478. data/spec/dummy/tmp/cache/assets/test/sass/5f072aa349cba3af993607d769833b63b75d973f/_neat.scssc +0 -0
  479. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_assign.scssc +0 -0
  480. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_color-lightness.scssc +0 -0
  481. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_contains.scssc +0 -0
  482. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_is-length.scssc +0 -0
  483. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_is-size.scssc +0 -0
  484. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_modular-scale.scssc +0 -0
  485. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_px-to-em.scssc +0 -0
  486. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_px-to-rem.scssc +0 -0
  487. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_strip-units.scssc +0 -0
  488. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_tint-shade.scssc +0 -0
  489. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_transition-property-name.scssc +0 -0
  490. data/spec/dummy/tmp/cache/assets/test/sass/795a8637b0fab77d1eeb31cac8603efe448ff850/_unpack.scssc +0 -0
  491. data/spec/dummy/tmp/cache/assets/test/sass/800ef82c27431a5e8e7dede5cd1112743adf0272/_asset-pipeline.scssc +0 -0
  492. data/spec/dummy/tmp/cache/assets/test/sass/800ef82c27431a5e8e7dede5cd1112743adf0272/_prefixer.scssc +0 -0
  493. data/spec/dummy/tmp/cache/assets/test/sass/800ef82c27431a5e8e7dede5cd1112743adf0272/_px-to-em.scssc +0 -0
  494. data/spec/dummy/tmp/cache/assets/test/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_base.scssc +0 -0
  495. data/spec/dummy/tmp/cache/assets/test/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_buttons.scssc +0 -0
  496. data/spec/dummy/tmp/cache/assets/test/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_forms.scssc +0 -0
  497. data/spec/dummy/tmp/cache/assets/test/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_lists.scssc +0 -0
  498. data/spec/dummy/tmp/cache/assets/test/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_tables.scssc +0 -0
  499. data/spec/dummy/tmp/cache/assets/test/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_typography.scssc +0 -0
  500. data/spec/dummy/tmp/cache/assets/test/sass/8a03b442b42d5298f476bcae4beccb785e81343f/_variables.scssc +0 -0
  501. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_bordered-pulled.scssc +0 -0
  502. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_core.scssc +0 -0
  503. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_fixed-width.scssc +0 -0
  504. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_icons.scssc +0 -0
  505. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_larger.scssc +0 -0
  506. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_list.scssc +0 -0
  507. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_mixins.scssc +0 -0
  508. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_path.scssc +0 -0
  509. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_rotated-flipped.scssc +0 -0
  510. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_spinning.scssc +0 -0
  511. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_stacked.scssc +0 -0
  512. data/spec/dummy/tmp/cache/assets/test/sass/9f24542060cf2dfd48886897cfdc1abe885d0c10/_variables.scssc +0 -0
  513. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_clearfix.scssc +0 -0
  514. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_directional-values.scssc +0 -0
  515. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_ellipsis.scssc +0 -0
  516. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_font-family.scssc +0 -0
  517. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_hide-text.scssc +0 -0
  518. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_html5-input-types.scssc +0 -0
  519. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_position.scssc +0 -0
  520. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_prefixer.scssc +0 -0
  521. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_retina-image.scssc +0 -0
  522. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_size.scssc +0 -0
  523. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_timing-functions.scssc +0 -0
  524. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_triangle.scssc +0 -0
  525. data/spec/dummy/tmp/cache/assets/test/sass/a97971d9b0ed03519f99fa46b9b937f53d5a178f/_word-wrap.scssc +0 -0
  526. data/spec/dummy/tmp/cache/assets/test/sass/bb516d13fd357410818971f9df2770c51e6cd834/_bourbon-deprecated-upcoming.scssc +0 -0
  527. data/spec/dummy/tmp/cache/assets/test/sass/bb516d13fd357410818971f9df2770c51e6cd834/_bourbon.scssc +0 -0
  528. data/spec/dummy/tmp/cache/assets/test/sass/e59ef1973131d8342e52dc165d6e4d0bdaa69ace/_disable-warnings.scssc +0 -0
  529. data/spec/dummy/tmp/cache/assets/test/sass/e59ef1973131d8342e52dc165d6e4d0bdaa69ace/_grid.scssc +0 -0
  530. data/spec/dummy/tmp/cache/assets/test/sass/e59ef1973131d8342e52dc165d6e4d0bdaa69ace/_visual-grid.scssc +0 -0
  531. data/spec/dummy/tmp/cache/assets/test/sass/ee9bebb508864c86a7d2ff5dda1e1d579851f483/_new-breakpoint.scssc +0 -0
  532. data/spec/dummy/tmp/cache/assets/test/sass/ee9bebb508864c86a7d2ff5dda1e1d579851f483/_private.scssc +0 -0
  533. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_animation.scssc +0 -0
  534. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_appearance.scssc +0 -0
  535. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_backface-visibility.scssc +0 -0
  536. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_background-image.scssc +0 -0
  537. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_background.scssc +0 -0
  538. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_border-image.scssc +0 -0
  539. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_border-radius.scssc +0 -0
  540. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_box-sizing.scssc +0 -0
  541. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_calc.scssc +0 -0
  542. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_columns.scssc +0 -0
  543. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_filter.scssc +0 -0
  544. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_flex-box.scssc +0 -0
  545. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_font-face.scssc +0 -0
  546. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_font-feature-settings.scssc +0 -0
  547. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_hidpi-media-query.scssc +0 -0
  548. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_hyphens.scssc +0 -0
  549. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_image-rendering.scssc +0 -0
  550. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_keyframes.scssc +0 -0
  551. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_linear-gradient.scssc +0 -0
  552. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_perspective.scssc +0 -0
  553. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_placeholder.scssc +0 -0
  554. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_radial-gradient.scssc +0 -0
  555. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_selection.scssc +0 -0
  556. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_text-decoration.scssc +0 -0
  557. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_transform.scssc +0 -0
  558. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_transition.scssc +0 -0
  559. data/spec/dummy/tmp/cache/assets/test/sass/f9e370bb6ca7276c3516d941194f792c7f739271/_user-select.scssc +0 -0
  560. data/spec/dummy/tmp/cache/assets/test/sprockets/0843c4389b6013a5f137b654692c134d +0 -0
  561. data/spec/dummy/tmp/cache/assets/test/sprockets/0a034e389f9e386eed13d467b63eca9b +0 -0
  562. data/spec/dummy/tmp/cache/assets/test/sprockets/132fac315f2cd452773eeb9b16f0c252 +0 -0
  563. data/spec/dummy/tmp/cache/assets/test/sprockets/147a279fafc653659d4dbb629bfd87fa +0 -0
  564. data/spec/dummy/tmp/cache/assets/test/sprockets/184771a4bb5b4018f686d13599c76a1b +0 -0
  565. data/spec/dummy/tmp/cache/assets/test/sprockets/2dfa93f86f6fee26011ddaaffeb07134 +0 -0
  566. data/spec/dummy/tmp/cache/assets/test/sprockets/34358387582f33147e74bd1add1ef28d +0 -0
  567. data/spec/dummy/tmp/cache/assets/test/sprockets/3c8761be81616e52c223148f63707110 +0 -0
  568. data/spec/dummy/tmp/cache/assets/test/sprockets/41c9080eac325030cbffdabd727b453b +0 -0
  569. data/spec/dummy/tmp/cache/assets/test/sprockets/42e8b34cb06ce5db17f8d345b332e82c +0 -0
  570. data/spec/dummy/tmp/cache/assets/test/sprockets/46756daeca4990181368563e56567798 +0 -0
  571. data/spec/dummy/tmp/cache/assets/test/sprockets/474e9b79f043250454c330139ca7720f +0 -0
  572. data/spec/dummy/tmp/cache/assets/test/sprockets/476fb3a0575bcb1c383ad3da96d669e6 +0 -0
  573. data/spec/dummy/tmp/cache/assets/test/sprockets/4b5e98e5f4ee4155c498aeb2e78fd7ad +0 -0
  574. data/spec/dummy/tmp/cache/assets/test/sprockets/63b79bd2b49acba39e87e5419f5ffbee +0 -0
  575. data/spec/dummy/tmp/cache/assets/test/sprockets/693a5efc9bd166e00a2a496da6bdaa72 +0 -0
  576. data/spec/dummy/tmp/cache/assets/test/sprockets/696e357a65aa75d4a11a28ee05c05f74 +0 -0
  577. data/spec/dummy/tmp/cache/assets/test/sprockets/6e984869c4433f9f747d062449542d29 +0 -0
  578. data/spec/dummy/tmp/cache/assets/test/sprockets/6f9cafe827f3b8be5d361a831deaa4f5 +0 -0
  579. data/spec/dummy/tmp/cache/assets/test/sprockets/73bf227c1520737290f1fa0f7221eaa4 +0 -0
  580. data/spec/dummy/tmp/cache/assets/test/sprockets/821724e68622ca85cbd026e1448ea0c1 +0 -0
  581. data/spec/dummy/tmp/cache/assets/test/sprockets/87a2d008eb2142f7f721cfb9bab54059 +0 -0
  582. data/spec/dummy/tmp/cache/assets/test/sprockets/8c0df32e074c495e4ebe39870f17c57d +0 -0
  583. data/spec/dummy/tmp/cache/assets/test/sprockets/8e9170ff4a2be091fa213edae95756fa +0 -0
  584. data/spec/dummy/tmp/cache/assets/test/sprockets/91133e15d88a7a0b850ca8d0b7573ea7 +0 -0
  585. data/spec/dummy/tmp/cache/assets/test/sprockets/947d965b51971837cc4e6e9b44a11433 +0 -0
  586. data/spec/dummy/tmp/cache/assets/test/sprockets/9d499737fd316127bf92c456cb1d760e +0 -0
  587. data/spec/dummy/tmp/cache/assets/test/sprockets/9f901d29334fc2b815bf10639fcc8bb4 +0 -0
  588. data/spec/dummy/tmp/cache/assets/test/sprockets/9fc050356bfaab94b793b2ceb6affd4e +0 -0
  589. data/spec/dummy/tmp/cache/assets/test/sprockets/ac3cbb82e36a366b69c942cb88280fba +0 -0
  590. data/spec/dummy/tmp/cache/assets/test/sprockets/ad721a7cf7d8274a7855503db2cbfca9 +0 -0
  591. data/spec/dummy/tmp/cache/assets/test/sprockets/b9367f070bcc853b554a8935a680dc9b +0 -0
  592. data/spec/dummy/tmp/cache/assets/test/sprockets/c025f89c8a7b6376e5905b5549d389dc +0 -0
  593. data/spec/dummy/tmp/cache/assets/test/sprockets/c7275b0849d6d311942825352a53d7c4 +0 -0
  594. data/spec/dummy/tmp/cache/assets/test/sprockets/d8fa391c2c8b5f04a475e4f121255a78 +0 -0
  595. data/spec/dummy/tmp/cache/assets/test/sprockets/d91f091f2783fa5b235d916f37dbe712 +0 -0
  596. data/spec/dummy/tmp/cache/assets/test/sprockets/dbd0051783820dad8df9d0140e5a8c5e +0 -0
  597. data/spec/dummy/tmp/cache/assets/test/sprockets/e124a21cd8277a401fc323f56c9d0a94 +0 -0
  598. data/spec/dummy/tmp/cache/assets/test/sprockets/eb2fe377661545628b0015a0f67db610 +0 -0
  599. data/spec/dummy/tmp/cache/assets/test/sprockets/f3540fd995f1201663e6e38a9cd5682a +0 -0
  600. data/spec/dummy/tmp/cache/assets/test/sprockets/f7d27ceb184b291e77a8d5fa663d0ee0 +0 -0
  601. data/spec/dummy/tmp/cache/assets/test/sprockets/f857d672c0da6a74749cffb5b18dc673 +0 -0
  602. data/spec/dummy/tmp/cache/assets/test/sprockets/f90aeb884f9f222145bc08b08d9c04e2 +0 -0
  603. data/spec/dummy/tmp/capybara/capybara-20150126164506760775298.html +2 -0
  604. data/spec/dummy/tmp/capybara/capybara-201501271212482063180924.html +1 -0
  605. data/spec/dummy/tmp/capybara/capybara-201501271213524043859031.html +1 -0
  606. data/spec/dummy/tmp/capybara/capybara-201501271217225622505228.html +1 -0
  607. data/spec/dummy/tmp/capybara/capybara-201501271219548736265136.html +1 -0
  608. data/spec/dummy/tmp/capybara/capybara-201501271220297247712363.html +1 -0
  609. data/spec/dummy/tmp/capybara/capybara-201501271220532745339320.html +1 -0
  610. data/spec/dummy/tmp/capybara/capybara-201501271221316412934865.html +1 -0
  611. data/spec/dummy/tmp/capybara/capybara-201501271222098265153993.html +1 -0
  612. data/spec/dummy/tmp/capybara/capybara-201501271222332347668678.html +1 -0
  613. data/spec/dummy/tmp/capybara/capybara-201501271223329585780502.html +1 -0
  614. data/spec/dummy/tmp/capybara/capybara-201501271329157404458893.html +1 -0
  615. data/spec/dummy/tmp/capybara/capybara-201501271332473860211019.html +1 -0
  616. data/spec/dummy/tmp/capybara/capybara-201501271334547112310492.html +1 -0
  617. data/spec/dummy/tmp/capybara/capybara-201501271340576729359278.html +1 -0
  618. data/spec/dummy/tmp/capybara/capybara-201501271342591927483065.html +1 -0
  619. data/spec/dummy/tmp/capybara/capybara-201501271346136636817803.html +1 -0
  620. data/spec/dummy/tmp/capybara/capybara-201501271346249295393797.html +1 -0
  621. data/spec/dummy/tmp/capybara/capybara-201501271347314783885267.html +1 -0
  622. data/spec/dummy/tmp/capybara/capybara-201501271348319863984909.html +1 -0
  623. data/spec/dummy/tmp/capybara/capybara-201501271350435746117038.html +1 -0
  624. data/spec/dummy/tmp/capybara/capybara-20150127140052208134302.html +1 -0
  625. data/spec/dummy/tmp/capybara/capybara-201501271406518104784536.html +1 -0
  626. data/spec/dummy/tmp/capybara/capybara-20150127140724517955483.html +1 -0
  627. data/spec/dummy/tmp/capybara/capybara-201501271407467603289738.html +1 -0
  628. data/spec/dummy/tmp/capybara/capybara-201501271412015880625109.html +1 -0
  629. data/spec/dummy/tmp/capybara/capybara-201501271420288441945087.html +1 -0
  630. data/spec/dummy/tmp/capybara/capybara-201501271424439001594302.html +1 -0
  631. data/spec/dummy/tmp/capybara/capybara-201501271424564851797999.html +1 -0
  632. data/spec/dummy/tmp/capybara/capybara-201501271430349419147954.html +1 -0
  633. data/spec/dummy/tmp/capybara/capybara-201501271432169369130501.html +1 -0
  634. data/spec/dummy/tmp/capybara/capybara-201501271432452709138447.html +1 -0
  635. data/spec/dummy/tmp/capybara/capybara-201501271433532287682099.html +1 -0
  636. data/spec/dummy/tmp/capybara/capybara-201501271514573709466747.html +2 -0
  637. data/spec/dummy/tmp/capybara/capybara-201501271515088403665689.html +2 -0
  638. data/spec/dummy/tmp/capybara/capybara-201501271515581007542563.html +2 -0
  639. data/spec/dummy/tmp/capybara/capybara-201501271518429565532378.html +2 -0
  640. data/spec/dummy/tmp/capybara/capybara-20150127152023347260119.html +1 -0
  641. data/spec/dummy/tmp/capybara/capybara-201501271608504251753093.html +1 -0
  642. data/spec/dummy/tmp/capybara/capybara-201501271624329534683898.html +2 -0
  643. data/spec/dummy/tmp/capybara/capybara-201501271626054828098505.html +1 -0
  644. data/spec/dummy/tmp/capybara/capybara-201501271627052511661559.html +1 -0
  645. data/spec/dummy/tmp/capybara/capybara-201501271627428230320009.html +1 -0
  646. data/spec/dummy/tmp/capybara/capybara-201501271627545490990228.html +1 -0
  647. data/spec/dummy/tmp/capybara/capybara-201501271628166962350069.html +1 -0
  648. data/spec/dummy/tmp/capybara/capybara-201501271628404766549784.html +1 -0
  649. data/spec/dummy/tmp/capybara/capybara-201501271629274758930285.html +1 -0
  650. data/spec/dummy/tmp/capybara/capybara-201501271634412861708527.html +1 -0
  651. data/spec/dummy/tmp/capybara/capybara-201501271635189282533728.html +1 -0
  652. data/spec/dummy/tmp/capybara/capybara-201501271639351468397505.html +1 -0
  653. data/spec/dummy/tmp/capybara/capybara-201501271640263912745428.html +1 -0
  654. data/spec/dummy/tmp/capybara/capybara-201501271640585727189974.html +1 -0
  655. data/spec/dummy/tmp/capybara/capybara-201501271642169685570528.html +5 -0
  656. data/spec/dummy/tmp/capybara/capybara-201501271649263038391681.html +5 -0
  657. data/spec/dummy/tmp/capybara/capybara-201501271649406585929583.html +1 -0
  658. data/spec/dummy/tmp/capybara/capybara-201501271649599071412038.html +2 -0
  659. data/spec/dummy/tmp/capybara/capybara-201501271650363855806928.html +2 -0
  660. data/spec/dummy/tmp/capybara/capybara-201501271651043757861314.html +2 -0
  661. data/spec/dummy/tmp/capybara/capybara-201501271654541688181627.html +1 -0
  662. data/spec/dummy/tmp/capybara/capybara-201501271655229509441843.html +1 -0
  663. data/spec/dummy/tmp/capybara/capybara-201501300945362149131496.html +1 -0
  664. data/spec/dummy/tmp/capybara/capybara-201501300945362349913356.html +17 -0
  665. data/spec/dummy/tmp/capybara/capybara-20150130094712607242119.html +17 -0
  666. data/spec/dummy/tmp/capybara/capybara-201501300947393413088336.html +17 -0
  667. data/spec/dummy/tmp/capybara/capybara-20150130094740936055170.html +1 -0
  668. data/spec/dummy/tmp/capybara/capybara-201501300951543332801260.html +17 -0
  669. data/spec/dummy/tmp/capybara/capybara-201501300951552326413785.html +1 -0
  670. data/spec/dummy/tmp/capybara/capybara-201501300952078257780458.html +17 -0
  671. data/spec/dummy/tmp/capybara/capybara-201501300952083041619734.html +1 -0
  672. data/spec/dummy/tmp/capybara/capybara-201501300952387419607265.html +1 -0
  673. data/spec/dummy/tmp/capybara/capybara-201501301002575030967861.html +1 -0
  674. data/spec/dummy/tmp/capybara/capybara-201501301109137079791278.html +1 -0
  675. data/spec/dummy/tmp/capybara/capybara-201501301110119463371193.html +1 -0
  676. data/spec/dummy/tmp/capybara/capybara-20150130111036726346160.html +1 -0
  677. data/spec/dummy/tmp/capybara/capybara-201501301119066916241981.html +1 -0
  678. data/spec/dummy/tmp/capybara/capybara-201501301119506668417581.html +1 -0
  679. data/spec/dummy/tmp/capybara/capybara-201501301147159868861914.html +1 -0
  680. data/spec/dummy/tmp/capybara/capybara-201501301149052086945362.html +1 -0
  681. data/spec/dummy/tmp/capybara/capybara-20150130114941592911285.html +1 -0
  682. data/spec/dummy/tmp/capybara/capybara-201501301150241080296894.html +1 -0
  683. data/spec/dummy/tmp/capybara/capybara-201501301152594941163140.html +1 -0
  684. data/spec/dummy/tmp/capybara/capybara-201501301153491474571300.html +1 -0
  685. data/spec/factories/help_kit_article_tags.rb +7 -0
  686. data/spec/factories/help_kit_articles.rb +19 -0
  687. data/spec/factories/help_kit_categories.rb +9 -0
  688. data/spec/factories/help_kit_tags.rb +5 -0
  689. data/spec/lib/help_kit/configuration_spec.rb +39 -0
  690. data/spec/models/help_kit/article_spec.rb +50 -0
  691. data/spec/models/help_kit/article_tag_spec.rb +6 -0
  692. data/spec/models/help_kit/category_spec.rb +21 -0
  693. data/spec/models/help_kit/tag_spec.rb +6 -0
  694. data/spec/rails_helper.rb +29 -0
  695. data/spec/spec_helper.rb +85 -0
  696. data/spec/views/help_kit/articles/index_category.html.slim_spec.rb +23 -0
  697. data/spec/views/help_kit/articles/show.html.slim_spec.rb +12 -0
  698. metadata +1644 -0
@@ -0,0 +1,3554 @@
1
+ "no use strict";
2
+ ;(function(window) {
3
+ if (typeof window.window != "undefined" && window.document) {
4
+ return;
5
+ }
6
+
7
+ window.console = function() {
8
+ var msgs = Array.prototype.slice.call(arguments, 0);
9
+ postMessage({type: "log", data: msgs});
10
+ };
11
+ window.console.error =
12
+ window.console.warn =
13
+ window.console.log =
14
+ window.console.trace = window.console;
15
+
16
+ window.window = window;
17
+ window.ace = window;
18
+
19
+ window.onerror = function(message, file, line, col, err) {
20
+ postMessage({type: "error", data: {
21
+ message: message,
22
+ file: file,
23
+ line: line,
24
+ col: col,
25
+ stack: err.stack
26
+ }});
27
+ };
28
+
29
+ window.normalizeModule = function(parentId, moduleName) {
30
+ // normalize plugin requires
31
+ if (moduleName.indexOf("!") !== -1) {
32
+ var chunks = moduleName.split("!");
33
+ return window.normalizeModule(parentId, chunks[0]) + "!" + window.normalizeModule(parentId, chunks[1]);
34
+ }
35
+ // normalize relative requires
36
+ if (moduleName.charAt(0) == ".") {
37
+ var base = parentId.split("/").slice(0, -1).join("/");
38
+ moduleName = (base ? base + "/" : "") + moduleName;
39
+
40
+ while(moduleName.indexOf(".") !== -1 && previous != moduleName) {
41
+ var previous = moduleName;
42
+ moduleName = moduleName.replace(/^\.\//, "").replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
43
+ }
44
+ }
45
+
46
+ return moduleName;
47
+ };
48
+
49
+ window.require = function(parentId, id) {
50
+ if (!id) {
51
+ id = parentId;
52
+ parentId = null;
53
+ }
54
+ if (!id.charAt)
55
+ throw new Error("worker.js require() accepts only (parentId, id) as arguments");
56
+
57
+ id = window.normalizeModule(parentId, id);
58
+
59
+ var module = window.require.modules[id];
60
+ if (module) {
61
+ if (!module.initialized) {
62
+ module.initialized = true;
63
+ module.exports = module.factory().exports;
64
+ }
65
+ return module.exports;
66
+ }
67
+
68
+ var chunks = id.split("/");
69
+ if (!window.require.tlns)
70
+ return console.log("unable to load " + id);
71
+ chunks[0] = window.require.tlns[chunks[0]] || chunks[0];
72
+ var path = chunks.join("/") + ".js";
73
+
74
+ window.require.id = id;
75
+ importScripts(path);
76
+ return window.require(parentId, id);
77
+ };
78
+ window.require.modules = {};
79
+ window.require.tlns = {};
80
+
81
+ window.define = function(id, deps, factory) {
82
+ if (arguments.length == 2) {
83
+ factory = deps;
84
+ if (typeof id != "string") {
85
+ deps = id;
86
+ id = window.require.id;
87
+ }
88
+ } else if (arguments.length == 1) {
89
+ factory = id;
90
+ deps = [];
91
+ id = window.require.id;
92
+ }
93
+
94
+ if (typeof factory != "function") {
95
+ window.require.modules[id] = {
96
+ exports: factory,
97
+ initialized: true
98
+ };
99
+ return;
100
+ }
101
+
102
+ if (!deps.length)
103
+ // If there is no dependencies, we inject 'require', 'exports' and
104
+ // 'module' as dependencies, to provide CommonJS compatibility.
105
+ deps = ['require', 'exports', 'module'];
106
+
107
+ var req = function(childId) {
108
+ return window.require(id, childId);
109
+ };
110
+
111
+ window.require.modules[id] = {
112
+ exports: {},
113
+ factory: function() {
114
+ var module = this;
115
+ var returnExports = factory.apply(this, deps.map(function(dep) {
116
+ switch(dep) {
117
+ // Because 'require', 'exports' and 'module' aren't actual
118
+ // dependencies, we must handle them seperately.
119
+ case 'require': return req;
120
+ case 'exports': return module.exports;
121
+ case 'module': return module;
122
+ // But for all other dependencies, we can just go ahead and
123
+ // require them.
124
+ default: return req(dep);
125
+ }
126
+ }));
127
+ if (returnExports)
128
+ module.exports = returnExports;
129
+ return module;
130
+ }
131
+ };
132
+ };
133
+ window.define.amd = {};
134
+
135
+ window.initBaseUrls = function initBaseUrls(topLevelNamespaces) {
136
+ require.tlns = topLevelNamespaces;
137
+ };
138
+
139
+ window.initSender = function initSender() {
140
+
141
+ var EventEmitter = window.require("ace/lib/event_emitter").EventEmitter;
142
+ var oop = window.require("ace/lib/oop");
143
+
144
+ var Sender = function() {};
145
+
146
+ (function() {
147
+
148
+ oop.implement(this, EventEmitter);
149
+
150
+ this.callback = function(data, callbackId) {
151
+ postMessage({
152
+ type: "call",
153
+ id: callbackId,
154
+ data: data
155
+ });
156
+ };
157
+
158
+ this.emit = function(name, data) {
159
+ postMessage({
160
+ type: "event",
161
+ name: name,
162
+ data: data
163
+ });
164
+ };
165
+
166
+ }).call(Sender.prototype);
167
+
168
+ return new Sender();
169
+ };
170
+
171
+ var main = window.main = null;
172
+ var sender = window.sender = null;
173
+
174
+ window.onmessage = function(e) {
175
+ var msg = e.data;
176
+ if (msg.command) {
177
+ if (main[msg.command])
178
+ main[msg.command].apply(main, msg.args);
179
+ else
180
+ throw new Error("Unknown command:" + msg.command);
181
+ }
182
+ else if (msg.init) {
183
+ initBaseUrls(msg.tlns);
184
+ require("ace/lib/es5-shim");
185
+ sender = window.sender = initSender();
186
+ var clazz = require(msg.module)[msg.classname];
187
+ main = window.main = new clazz(sender);
188
+ }
189
+ else if (msg.event && sender) {
190
+ sender._signal(msg.event, msg.data);
191
+ }
192
+ };
193
+ })(this);
194
+
195
+ define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
196
+ "use strict";
197
+
198
+ exports.inherits = function(ctor, superCtor) {
199
+ ctor.super_ = superCtor;
200
+ ctor.prototype = Object.create(superCtor.prototype, {
201
+ constructor: {
202
+ value: ctor,
203
+ enumerable: false,
204
+ writable: true,
205
+ configurable: true
206
+ }
207
+ });
208
+ };
209
+
210
+ exports.mixin = function(obj, mixin) {
211
+ for (var key in mixin) {
212
+ obj[key] = mixin[key];
213
+ }
214
+ return obj;
215
+ };
216
+
217
+ exports.implement = function(proto, mixin) {
218
+ exports.mixin(proto, mixin);
219
+ };
220
+
221
+ });
222
+
223
+ define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
224
+ "use strict";
225
+
226
+ var EventEmitter = {};
227
+ var stopPropagation = function() { this.propagationStopped = true; };
228
+ var preventDefault = function() { this.defaultPrevented = true; };
229
+
230
+ EventEmitter._emit =
231
+ EventEmitter._dispatchEvent = function(eventName, e) {
232
+ this._eventRegistry || (this._eventRegistry = {});
233
+ this._defaultHandlers || (this._defaultHandlers = {});
234
+
235
+ var listeners = this._eventRegistry[eventName] || [];
236
+ var defaultHandler = this._defaultHandlers[eventName];
237
+ if (!listeners.length && !defaultHandler)
238
+ return;
239
+
240
+ if (typeof e != "object" || !e)
241
+ e = {};
242
+
243
+ if (!e.type)
244
+ e.type = eventName;
245
+ if (!e.stopPropagation)
246
+ e.stopPropagation = stopPropagation;
247
+ if (!e.preventDefault)
248
+ e.preventDefault = preventDefault;
249
+
250
+ listeners = listeners.slice();
251
+ for (var i=0; i<listeners.length; i++) {
252
+ listeners[i](e, this);
253
+ if (e.propagationStopped)
254
+ break;
255
+ }
256
+
257
+ if (defaultHandler && !e.defaultPrevented)
258
+ return defaultHandler(e, this);
259
+ };
260
+
261
+
262
+ EventEmitter._signal = function(eventName, e) {
263
+ var listeners = (this._eventRegistry || {})[eventName];
264
+ if (!listeners)
265
+ return;
266
+ listeners = listeners.slice();
267
+ for (var i=0; i<listeners.length; i++)
268
+ listeners[i](e, this);
269
+ };
270
+
271
+ EventEmitter.once = function(eventName, callback) {
272
+ var _self = this;
273
+ callback && this.addEventListener(eventName, function newCallback() {
274
+ _self.removeEventListener(eventName, newCallback);
275
+ callback.apply(null, arguments);
276
+ });
277
+ };
278
+
279
+
280
+ EventEmitter.setDefaultHandler = function(eventName, callback) {
281
+ var handlers = this._defaultHandlers
282
+ if (!handlers)
283
+ handlers = this._defaultHandlers = {_disabled_: {}};
284
+
285
+ if (handlers[eventName]) {
286
+ var old = handlers[eventName];
287
+ var disabled = handlers._disabled_[eventName];
288
+ if (!disabled)
289
+ handlers._disabled_[eventName] = disabled = [];
290
+ disabled.push(old);
291
+ var i = disabled.indexOf(callback);
292
+ if (i != -1)
293
+ disabled.splice(i, 1);
294
+ }
295
+ handlers[eventName] = callback;
296
+ };
297
+ EventEmitter.removeDefaultHandler = function(eventName, callback) {
298
+ var handlers = this._defaultHandlers
299
+ if (!handlers)
300
+ return;
301
+ var disabled = handlers._disabled_[eventName];
302
+
303
+ if (handlers[eventName] == callback) {
304
+ var old = handlers[eventName];
305
+ if (disabled)
306
+ this.setDefaultHandler(eventName, disabled.pop());
307
+ } else if (disabled) {
308
+ var i = disabled.indexOf(callback);
309
+ if (i != -1)
310
+ disabled.splice(i, 1);
311
+ }
312
+ };
313
+
314
+ EventEmitter.on =
315
+ EventEmitter.addEventListener = function(eventName, callback, capturing) {
316
+ this._eventRegistry = this._eventRegistry || {};
317
+
318
+ var listeners = this._eventRegistry[eventName];
319
+ if (!listeners)
320
+ listeners = this._eventRegistry[eventName] = [];
321
+
322
+ if (listeners.indexOf(callback) == -1)
323
+ listeners[capturing ? "unshift" : "push"](callback);
324
+ return callback;
325
+ };
326
+
327
+ EventEmitter.off =
328
+ EventEmitter.removeListener =
329
+ EventEmitter.removeEventListener = function(eventName, callback) {
330
+ this._eventRegistry = this._eventRegistry || {};
331
+
332
+ var listeners = this._eventRegistry[eventName];
333
+ if (!listeners)
334
+ return;
335
+
336
+ var index = listeners.indexOf(callback);
337
+ if (index !== -1)
338
+ listeners.splice(index, 1);
339
+ };
340
+
341
+ EventEmitter.removeAllListeners = function(eventName) {
342
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
343
+ };
344
+
345
+ exports.EventEmitter = EventEmitter;
346
+
347
+ });
348
+
349
+ define("ace/range",["require","exports","module"], function(require, exports, module) {
350
+ "use strict";
351
+ var comparePoints = function(p1, p2) {
352
+ return p1.row - p2.row || p1.column - p2.column;
353
+ };
354
+ var Range = function(startRow, startColumn, endRow, endColumn) {
355
+ this.start = {
356
+ row: startRow,
357
+ column: startColumn
358
+ };
359
+
360
+ this.end = {
361
+ row: endRow,
362
+ column: endColumn
363
+ };
364
+ };
365
+
366
+ (function() {
367
+ this.isEqual = function(range) {
368
+ return this.start.row === range.start.row &&
369
+ this.end.row === range.end.row &&
370
+ this.start.column === range.start.column &&
371
+ this.end.column === range.end.column;
372
+ };
373
+ this.toString = function() {
374
+ return ("Range: [" + this.start.row + "/" + this.start.column +
375
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
376
+ };
377
+
378
+ this.contains = function(row, column) {
379
+ return this.compare(row, column) == 0;
380
+ };
381
+ this.compareRange = function(range) {
382
+ var cmp,
383
+ end = range.end,
384
+ start = range.start;
385
+
386
+ cmp = this.compare(end.row, end.column);
387
+ if (cmp == 1) {
388
+ cmp = this.compare(start.row, start.column);
389
+ if (cmp == 1) {
390
+ return 2;
391
+ } else if (cmp == 0) {
392
+ return 1;
393
+ } else {
394
+ return 0;
395
+ }
396
+ } else if (cmp == -1) {
397
+ return -2;
398
+ } else {
399
+ cmp = this.compare(start.row, start.column);
400
+ if (cmp == -1) {
401
+ return -1;
402
+ } else if (cmp == 1) {
403
+ return 42;
404
+ } else {
405
+ return 0;
406
+ }
407
+ }
408
+ };
409
+ this.comparePoint = function(p) {
410
+ return this.compare(p.row, p.column);
411
+ };
412
+ this.containsRange = function(range) {
413
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
414
+ };
415
+ this.intersects = function(range) {
416
+ var cmp = this.compareRange(range);
417
+ return (cmp == -1 || cmp == 0 || cmp == 1);
418
+ };
419
+ this.isEnd = function(row, column) {
420
+ return this.end.row == row && this.end.column == column;
421
+ };
422
+ this.isStart = function(row, column) {
423
+ return this.start.row == row && this.start.column == column;
424
+ };
425
+ this.setStart = function(row, column) {
426
+ if (typeof row == "object") {
427
+ this.start.column = row.column;
428
+ this.start.row = row.row;
429
+ } else {
430
+ this.start.row = row;
431
+ this.start.column = column;
432
+ }
433
+ };
434
+ this.setEnd = function(row, column) {
435
+ if (typeof row == "object") {
436
+ this.end.column = row.column;
437
+ this.end.row = row.row;
438
+ } else {
439
+ this.end.row = row;
440
+ this.end.column = column;
441
+ }
442
+ };
443
+ this.inside = function(row, column) {
444
+ if (this.compare(row, column) == 0) {
445
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
446
+ return false;
447
+ } else {
448
+ return true;
449
+ }
450
+ }
451
+ return false;
452
+ };
453
+ this.insideStart = function(row, column) {
454
+ if (this.compare(row, column) == 0) {
455
+ if (this.isEnd(row, column)) {
456
+ return false;
457
+ } else {
458
+ return true;
459
+ }
460
+ }
461
+ return false;
462
+ };
463
+ this.insideEnd = function(row, column) {
464
+ if (this.compare(row, column) == 0) {
465
+ if (this.isStart(row, column)) {
466
+ return false;
467
+ } else {
468
+ return true;
469
+ }
470
+ }
471
+ return false;
472
+ };
473
+ this.compare = function(row, column) {
474
+ if (!this.isMultiLine()) {
475
+ if (row === this.start.row) {
476
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
477
+ };
478
+ }
479
+
480
+ if (row < this.start.row)
481
+ return -1;
482
+
483
+ if (row > this.end.row)
484
+ return 1;
485
+
486
+ if (this.start.row === row)
487
+ return column >= this.start.column ? 0 : -1;
488
+
489
+ if (this.end.row === row)
490
+ return column <= this.end.column ? 0 : 1;
491
+
492
+ return 0;
493
+ };
494
+ this.compareStart = function(row, column) {
495
+ if (this.start.row == row && this.start.column == column) {
496
+ return -1;
497
+ } else {
498
+ return this.compare(row, column);
499
+ }
500
+ };
501
+ this.compareEnd = function(row, column) {
502
+ if (this.end.row == row && this.end.column == column) {
503
+ return 1;
504
+ } else {
505
+ return this.compare(row, column);
506
+ }
507
+ };
508
+ this.compareInside = function(row, column) {
509
+ if (this.end.row == row && this.end.column == column) {
510
+ return 1;
511
+ } else if (this.start.row == row && this.start.column == column) {
512
+ return -1;
513
+ } else {
514
+ return this.compare(row, column);
515
+ }
516
+ };
517
+ this.clipRows = function(firstRow, lastRow) {
518
+ if (this.end.row > lastRow)
519
+ var end = {row: lastRow + 1, column: 0};
520
+ else if (this.end.row < firstRow)
521
+ var end = {row: firstRow, column: 0};
522
+
523
+ if (this.start.row > lastRow)
524
+ var start = {row: lastRow + 1, column: 0};
525
+ else if (this.start.row < firstRow)
526
+ var start = {row: firstRow, column: 0};
527
+
528
+ return Range.fromPoints(start || this.start, end || this.end);
529
+ };
530
+ this.extend = function(row, column) {
531
+ var cmp = this.compare(row, column);
532
+
533
+ if (cmp == 0)
534
+ return this;
535
+ else if (cmp == -1)
536
+ var start = {row: row, column: column};
537
+ else
538
+ var end = {row: row, column: column};
539
+
540
+ return Range.fromPoints(start || this.start, end || this.end);
541
+ };
542
+
543
+ this.isEmpty = function() {
544
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
545
+ };
546
+ this.isMultiLine = function() {
547
+ return (this.start.row !== this.end.row);
548
+ };
549
+ this.clone = function() {
550
+ return Range.fromPoints(this.start, this.end);
551
+ };
552
+ this.collapseRows = function() {
553
+ if (this.end.column == 0)
554
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
555
+ else
556
+ return new Range(this.start.row, 0, this.end.row, 0)
557
+ };
558
+ this.toScreenRange = function(session) {
559
+ var screenPosStart = session.documentToScreenPosition(this.start);
560
+ var screenPosEnd = session.documentToScreenPosition(this.end);
561
+
562
+ return new Range(
563
+ screenPosStart.row, screenPosStart.column,
564
+ screenPosEnd.row, screenPosEnd.column
565
+ );
566
+ };
567
+ this.moveBy = function(row, column) {
568
+ this.start.row += row;
569
+ this.start.column += column;
570
+ this.end.row += row;
571
+ this.end.column += column;
572
+ };
573
+
574
+ }).call(Range.prototype);
575
+ Range.fromPoints = function(start, end) {
576
+ return new Range(start.row, start.column, end.row, end.column);
577
+ };
578
+ Range.comparePoints = comparePoints;
579
+
580
+ Range.comparePoints = function(p1, p2) {
581
+ return p1.row - p2.row || p1.column - p2.column;
582
+ };
583
+
584
+
585
+ exports.Range = Range;
586
+ });
587
+
588
+ define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
589
+ "use strict";
590
+
591
+ var oop = require("./lib/oop");
592
+ var EventEmitter = require("./lib/event_emitter").EventEmitter;
593
+
594
+ var Anchor = exports.Anchor = function(doc, row, column) {
595
+ this.$onChange = this.onChange.bind(this);
596
+ this.attach(doc);
597
+
598
+ if (typeof column == "undefined")
599
+ this.setPosition(row.row, row.column);
600
+ else
601
+ this.setPosition(row, column);
602
+ };
603
+
604
+ (function() {
605
+
606
+ oop.implement(this, EventEmitter);
607
+ this.getPosition = function() {
608
+ return this.$clipPositionToDocument(this.row, this.column);
609
+ };
610
+ this.getDocument = function() {
611
+ return this.document;
612
+ };
613
+ this.$insertRight = false;
614
+ this.onChange = function(e) {
615
+ var delta = e.data;
616
+ var range = delta.range;
617
+
618
+ if (range.start.row == range.end.row && range.start.row != this.row)
619
+ return;
620
+
621
+ if (range.start.row > this.row)
622
+ return;
623
+
624
+ if (range.start.row == this.row && range.start.column > this.column)
625
+ return;
626
+
627
+ var row = this.row;
628
+ var column = this.column;
629
+ var start = range.start;
630
+ var end = range.end;
631
+
632
+ if (delta.action === "insertText") {
633
+ if (start.row === row && start.column <= column) {
634
+ if (start.column === column && this.$insertRight) {
635
+ } else if (start.row === end.row) {
636
+ column += end.column - start.column;
637
+ } else {
638
+ column -= start.column;
639
+ row += end.row - start.row;
640
+ }
641
+ } else if (start.row !== end.row && start.row < row) {
642
+ row += end.row - start.row;
643
+ }
644
+ } else if (delta.action === "insertLines") {
645
+ if (start.row === row && column === 0 && this.$insertRight) {
646
+ }
647
+ else if (start.row <= row) {
648
+ row += end.row - start.row;
649
+ }
650
+ } else if (delta.action === "removeText") {
651
+ if (start.row === row && start.column < column) {
652
+ if (end.column >= column)
653
+ column = start.column;
654
+ else
655
+ column = Math.max(0, column - (end.column - start.column));
656
+
657
+ } else if (start.row !== end.row && start.row < row) {
658
+ if (end.row === row)
659
+ column = Math.max(0, column - end.column) + start.column;
660
+ row -= (end.row - start.row);
661
+ } else if (end.row === row) {
662
+ row -= end.row - start.row;
663
+ column = Math.max(0, column - end.column) + start.column;
664
+ }
665
+ } else if (delta.action == "removeLines") {
666
+ if (start.row <= row) {
667
+ if (end.row <= row)
668
+ row -= end.row - start.row;
669
+ else {
670
+ row = start.row;
671
+ column = 0;
672
+ }
673
+ }
674
+ }
675
+
676
+ this.setPosition(row, column, true);
677
+ };
678
+ this.setPosition = function(row, column, noClip) {
679
+ var pos;
680
+ if (noClip) {
681
+ pos = {
682
+ row: row,
683
+ column: column
684
+ };
685
+ } else {
686
+ pos = this.$clipPositionToDocument(row, column);
687
+ }
688
+
689
+ if (this.row == pos.row && this.column == pos.column)
690
+ return;
691
+
692
+ var old = {
693
+ row: this.row,
694
+ column: this.column
695
+ };
696
+
697
+ this.row = pos.row;
698
+ this.column = pos.column;
699
+ this._signal("change", {
700
+ old: old,
701
+ value: pos
702
+ });
703
+ };
704
+ this.detach = function() {
705
+ this.document.removeEventListener("change", this.$onChange);
706
+ };
707
+ this.attach = function(doc) {
708
+ this.document = doc || this.document;
709
+ this.document.on("change", this.$onChange);
710
+ };
711
+ this.$clipPositionToDocument = function(row, column) {
712
+ var pos = {};
713
+
714
+ if (row >= this.document.getLength()) {
715
+ pos.row = Math.max(0, this.document.getLength() - 1);
716
+ pos.column = this.document.getLine(pos.row).length;
717
+ }
718
+ else if (row < 0) {
719
+ pos.row = 0;
720
+ pos.column = 0;
721
+ }
722
+ else {
723
+ pos.row = row;
724
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
725
+ }
726
+
727
+ if (column < 0)
728
+ pos.column = 0;
729
+
730
+ return pos;
731
+ };
732
+
733
+ }).call(Anchor.prototype);
734
+
735
+ });
736
+
737
+ define("ace/document",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
738
+ "use strict";
739
+
740
+ var oop = require("./lib/oop");
741
+ var EventEmitter = require("./lib/event_emitter").EventEmitter;
742
+ var Range = require("./range").Range;
743
+ var Anchor = require("./anchor").Anchor;
744
+
745
+ var Document = function(text) {
746
+ this.$lines = [];
747
+ if (text.length === 0) {
748
+ this.$lines = [""];
749
+ } else if (Array.isArray(text)) {
750
+ this._insertLines(0, text);
751
+ } else {
752
+ this.insert({row: 0, column:0}, text);
753
+ }
754
+ };
755
+
756
+ (function() {
757
+
758
+ oop.implement(this, EventEmitter);
759
+ this.setValue = function(text) {
760
+ var len = this.getLength();
761
+ this.remove(new Range(0, 0, len, this.getLine(len-1).length));
762
+ this.insert({row: 0, column:0}, text);
763
+ };
764
+ this.getValue = function() {
765
+ return this.getAllLines().join(this.getNewLineCharacter());
766
+ };
767
+ this.createAnchor = function(row, column) {
768
+ return new Anchor(this, row, column);
769
+ };
770
+ if ("aaa".split(/a/).length === 0)
771
+ this.$split = function(text) {
772
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
773
+ };
774
+ else
775
+ this.$split = function(text) {
776
+ return text.split(/\r\n|\r|\n/);
777
+ };
778
+
779
+
780
+ this.$detectNewLine = function(text) {
781
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
782
+ this.$autoNewLine = match ? match[1] : "\n";
783
+ this._signal("changeNewLineMode");
784
+ };
785
+ this.getNewLineCharacter = function() {
786
+ switch (this.$newLineMode) {
787
+ case "windows":
788
+ return "\r\n";
789
+ case "unix":
790
+ return "\n";
791
+ default:
792
+ return this.$autoNewLine || "\n";
793
+ }
794
+ };
795
+
796
+ this.$autoNewLine = "";
797
+ this.$newLineMode = "auto";
798
+ this.setNewLineMode = function(newLineMode) {
799
+ if (this.$newLineMode === newLineMode)
800
+ return;
801
+
802
+ this.$newLineMode = newLineMode;
803
+ this._signal("changeNewLineMode");
804
+ };
805
+ this.getNewLineMode = function() {
806
+ return this.$newLineMode;
807
+ };
808
+ this.isNewLine = function(text) {
809
+ return (text == "\r\n" || text == "\r" || text == "\n");
810
+ };
811
+ this.getLine = function(row) {
812
+ return this.$lines[row] || "";
813
+ };
814
+ this.getLines = function(firstRow, lastRow) {
815
+ return this.$lines.slice(firstRow, lastRow + 1);
816
+ };
817
+ this.getAllLines = function() {
818
+ return this.getLines(0, this.getLength());
819
+ };
820
+ this.getLength = function() {
821
+ return this.$lines.length;
822
+ };
823
+ this.getTextRange = function(range) {
824
+ if (range.start.row == range.end.row) {
825
+ return this.getLine(range.start.row)
826
+ .substring(range.start.column, range.end.column);
827
+ }
828
+ var lines = this.getLines(range.start.row, range.end.row);
829
+ lines[0] = (lines[0] || "").substring(range.start.column);
830
+ var l = lines.length - 1;
831
+ if (range.end.row - range.start.row == l)
832
+ lines[l] = lines[l].substring(0, range.end.column);
833
+ return lines.join(this.getNewLineCharacter());
834
+ };
835
+
836
+ this.$clipPosition = function(position) {
837
+ var length = this.getLength();
838
+ if (position.row >= length) {
839
+ position.row = Math.max(0, length - 1);
840
+ position.column = this.getLine(length-1).length;
841
+ } else if (position.row < 0)
842
+ position.row = 0;
843
+ return position;
844
+ };
845
+ this.insert = function(position, text) {
846
+ if (!text || text.length === 0)
847
+ return position;
848
+
849
+ position = this.$clipPosition(position);
850
+ if (this.getLength() <= 1)
851
+ this.$detectNewLine(text);
852
+
853
+ var lines = this.$split(text);
854
+ var firstLine = lines.splice(0, 1)[0];
855
+ var lastLine = lines.length == 0 ? null : lines.splice(lines.length - 1, 1)[0];
856
+
857
+ position = this.insertInLine(position, firstLine);
858
+ if (lastLine !== null) {
859
+ position = this.insertNewLine(position); // terminate first line
860
+ position = this._insertLines(position.row, lines);
861
+ position = this.insertInLine(position, lastLine || "");
862
+ }
863
+ return position;
864
+ };
865
+ this.insertLines = function(row, lines) {
866
+ if (row >= this.getLength())
867
+ return this.insert({row: row, column: 0}, "\n" + lines.join("\n"));
868
+ return this._insertLines(Math.max(row, 0), lines);
869
+ };
870
+ this._insertLines = function(row, lines) {
871
+ if (lines.length == 0)
872
+ return {row: row, column: 0};
873
+ while (lines.length > 0xF000) {
874
+ var end = this._insertLines(row, lines.slice(0, 0xF000));
875
+ lines = lines.slice(0xF000);
876
+ row = end.row;
877
+ }
878
+
879
+ var args = [row, 0];
880
+ args.push.apply(args, lines);
881
+ this.$lines.splice.apply(this.$lines, args);
882
+
883
+ var range = new Range(row, 0, row + lines.length, 0);
884
+ var delta = {
885
+ action: "insertLines",
886
+ range: range,
887
+ lines: lines
888
+ };
889
+ this._signal("change", { data: delta });
890
+ return range.end;
891
+ };
892
+ this.insertNewLine = function(position) {
893
+ position = this.$clipPosition(position);
894
+ var line = this.$lines[position.row] || "";
895
+
896
+ this.$lines[position.row] = line.substring(0, position.column);
897
+ this.$lines.splice(position.row + 1, 0, line.substring(position.column, line.length));
898
+
899
+ var end = {
900
+ row : position.row + 1,
901
+ column : 0
902
+ };
903
+
904
+ var delta = {
905
+ action: "insertText",
906
+ range: Range.fromPoints(position, end),
907
+ text: this.getNewLineCharacter()
908
+ };
909
+ this._signal("change", { data: delta });
910
+
911
+ return end;
912
+ };
913
+ this.insertInLine = function(position, text) {
914
+ if (text.length == 0)
915
+ return position;
916
+
917
+ var line = this.$lines[position.row] || "";
918
+
919
+ this.$lines[position.row] = line.substring(0, position.column) + text
920
+ + line.substring(position.column);
921
+
922
+ var end = {
923
+ row : position.row,
924
+ column : position.column + text.length
925
+ };
926
+
927
+ var delta = {
928
+ action: "insertText",
929
+ range: Range.fromPoints(position, end),
930
+ text: text
931
+ };
932
+ this._signal("change", { data: delta });
933
+
934
+ return end;
935
+ };
936
+ this.remove = function(range) {
937
+ if (!(range instanceof Range))
938
+ range = Range.fromPoints(range.start, range.end);
939
+ range.start = this.$clipPosition(range.start);
940
+ range.end = this.$clipPosition(range.end);
941
+
942
+ if (range.isEmpty())
943
+ return range.start;
944
+
945
+ var firstRow = range.start.row;
946
+ var lastRow = range.end.row;
947
+
948
+ if (range.isMultiLine()) {
949
+ var firstFullRow = range.start.column == 0 ? firstRow : firstRow + 1;
950
+ var lastFullRow = lastRow - 1;
951
+
952
+ if (range.end.column > 0)
953
+ this.removeInLine(lastRow, 0, range.end.column);
954
+
955
+ if (lastFullRow >= firstFullRow)
956
+ this._removeLines(firstFullRow, lastFullRow);
957
+
958
+ if (firstFullRow != firstRow) {
959
+ this.removeInLine(firstRow, range.start.column, this.getLine(firstRow).length);
960
+ this.removeNewLine(range.start.row);
961
+ }
962
+ }
963
+ else {
964
+ this.removeInLine(firstRow, range.start.column, range.end.column);
965
+ }
966
+ return range.start;
967
+ };
968
+ this.removeInLine = function(row, startColumn, endColumn) {
969
+ if (startColumn == endColumn)
970
+ return;
971
+
972
+ var range = new Range(row, startColumn, row, endColumn);
973
+ var line = this.getLine(row);
974
+ var removed = line.substring(startColumn, endColumn);
975
+ var newLine = line.substring(0, startColumn) + line.substring(endColumn, line.length);
976
+ this.$lines.splice(row, 1, newLine);
977
+
978
+ var delta = {
979
+ action: "removeText",
980
+ range: range,
981
+ text: removed
982
+ };
983
+ this._signal("change", { data: delta });
984
+ return range.start;
985
+ };
986
+ this.removeLines = function(firstRow, lastRow) {
987
+ if (firstRow < 0 || lastRow >= this.getLength())
988
+ return this.remove(new Range(firstRow, 0, lastRow + 1, 0));
989
+ return this._removeLines(firstRow, lastRow);
990
+ };
991
+
992
+ this._removeLines = function(firstRow, lastRow) {
993
+ var range = new Range(firstRow, 0, lastRow + 1, 0);
994
+ var removed = this.$lines.splice(firstRow, lastRow - firstRow + 1);
995
+
996
+ var delta = {
997
+ action: "removeLines",
998
+ range: range,
999
+ nl: this.getNewLineCharacter(),
1000
+ lines: removed
1001
+ };
1002
+ this._signal("change", { data: delta });
1003
+ return removed;
1004
+ };
1005
+ this.removeNewLine = function(row) {
1006
+ var firstLine = this.getLine(row);
1007
+ var secondLine = this.getLine(row+1);
1008
+
1009
+ var range = new Range(row, firstLine.length, row+1, 0);
1010
+ var line = firstLine + secondLine;
1011
+
1012
+ this.$lines.splice(row, 2, line);
1013
+
1014
+ var delta = {
1015
+ action: "removeText",
1016
+ range: range,
1017
+ text: this.getNewLineCharacter()
1018
+ };
1019
+ this._signal("change", { data: delta });
1020
+ };
1021
+ this.replace = function(range, text) {
1022
+ if (!(range instanceof Range))
1023
+ range = Range.fromPoints(range.start, range.end);
1024
+ if (text.length == 0 && range.isEmpty())
1025
+ return range.start;
1026
+ if (text == this.getTextRange(range))
1027
+ return range.end;
1028
+
1029
+ this.remove(range);
1030
+ if (text) {
1031
+ var end = this.insert(range.start, text);
1032
+ }
1033
+ else {
1034
+ end = range.start;
1035
+ }
1036
+
1037
+ return end;
1038
+ };
1039
+ this.applyDeltas = function(deltas) {
1040
+ for (var i=0; i<deltas.length; i++) {
1041
+ var delta = deltas[i];
1042
+ var range = Range.fromPoints(delta.range.start, delta.range.end);
1043
+
1044
+ if (delta.action == "insertLines")
1045
+ this.insertLines(range.start.row, delta.lines);
1046
+ else if (delta.action == "insertText")
1047
+ this.insert(range.start, delta.text);
1048
+ else if (delta.action == "removeLines")
1049
+ this._removeLines(range.start.row, range.end.row - 1);
1050
+ else if (delta.action == "removeText")
1051
+ this.remove(range);
1052
+ }
1053
+ };
1054
+ this.revertDeltas = function(deltas) {
1055
+ for (var i=deltas.length-1; i>=0; i--) {
1056
+ var delta = deltas[i];
1057
+
1058
+ var range = Range.fromPoints(delta.range.start, delta.range.end);
1059
+
1060
+ if (delta.action == "insertLines")
1061
+ this._removeLines(range.start.row, range.end.row - 1);
1062
+ else if (delta.action == "insertText")
1063
+ this.remove(range);
1064
+ else if (delta.action == "removeLines")
1065
+ this._insertLines(range.start.row, delta.lines);
1066
+ else if (delta.action == "removeText")
1067
+ this.insert(range.start, delta.text);
1068
+ }
1069
+ };
1070
+ this.indexToPosition = function(index, startRow) {
1071
+ var lines = this.$lines || this.getAllLines();
1072
+ var newlineLength = this.getNewLineCharacter().length;
1073
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
1074
+ index -= lines[i].length + newlineLength;
1075
+ if (index < 0)
1076
+ return {row: i, column: index + lines[i].length + newlineLength};
1077
+ }
1078
+ return {row: l-1, column: lines[l-1].length};
1079
+ };
1080
+ this.positionToIndex = function(pos, startRow) {
1081
+ var lines = this.$lines || this.getAllLines();
1082
+ var newlineLength = this.getNewLineCharacter().length;
1083
+ var index = 0;
1084
+ var row = Math.min(pos.row, lines.length);
1085
+ for (var i = startRow || 0; i < row; ++i)
1086
+ index += lines[i].length + newlineLength;
1087
+
1088
+ return index + pos.column;
1089
+ };
1090
+
1091
+ }).call(Document.prototype);
1092
+
1093
+ exports.Document = Document;
1094
+ });
1095
+
1096
+ define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
1097
+ "use strict";
1098
+
1099
+ exports.last = function(a) {
1100
+ return a[a.length - 1];
1101
+ };
1102
+
1103
+ exports.stringReverse = function(string) {
1104
+ return string.split("").reverse().join("");
1105
+ };
1106
+
1107
+ exports.stringRepeat = function (string, count) {
1108
+ var result = '';
1109
+ while (count > 0) {
1110
+ if (count & 1)
1111
+ result += string;
1112
+
1113
+ if (count >>= 1)
1114
+ string += string;
1115
+ }
1116
+ return result;
1117
+ };
1118
+
1119
+ var trimBeginRegexp = /^\s\s*/;
1120
+ var trimEndRegexp = /\s\s*$/;
1121
+
1122
+ exports.stringTrimLeft = function (string) {
1123
+ return string.replace(trimBeginRegexp, '');
1124
+ };
1125
+
1126
+ exports.stringTrimRight = function (string) {
1127
+ return string.replace(trimEndRegexp, '');
1128
+ };
1129
+
1130
+ exports.copyObject = function(obj) {
1131
+ var copy = {};
1132
+ for (var key in obj) {
1133
+ copy[key] = obj[key];
1134
+ }
1135
+ return copy;
1136
+ };
1137
+
1138
+ exports.copyArray = function(array){
1139
+ var copy = [];
1140
+ for (var i=0, l=array.length; i<l; i++) {
1141
+ if (array[i] && typeof array[i] == "object")
1142
+ copy[i] = this.copyObject( array[i] );
1143
+ else
1144
+ copy[i] = array[i];
1145
+ }
1146
+ return copy;
1147
+ };
1148
+
1149
+ exports.deepCopy = function (obj) {
1150
+ if (typeof obj !== "object" || !obj)
1151
+ return obj;
1152
+ var cons = obj.constructor;
1153
+ if (cons === RegExp)
1154
+ return obj;
1155
+
1156
+ var copy = cons();
1157
+ for (var key in obj) {
1158
+ if (typeof obj[key] === "object") {
1159
+ copy[key] = exports.deepCopy(obj[key]);
1160
+ } else {
1161
+ copy[key] = obj[key];
1162
+ }
1163
+ }
1164
+ return copy;
1165
+ };
1166
+
1167
+ exports.arrayToMap = function(arr) {
1168
+ var map = {};
1169
+ for (var i=0; i<arr.length; i++) {
1170
+ map[arr[i]] = 1;
1171
+ }
1172
+ return map;
1173
+
1174
+ };
1175
+
1176
+ exports.createMap = function(props) {
1177
+ var map = Object.create(null);
1178
+ for (var i in props) {
1179
+ map[i] = props[i];
1180
+ }
1181
+ return map;
1182
+ };
1183
+ exports.arrayRemove = function(array, value) {
1184
+ for (var i = 0; i <= array.length; i++) {
1185
+ if (value === array[i]) {
1186
+ array.splice(i, 1);
1187
+ }
1188
+ }
1189
+ };
1190
+
1191
+ exports.escapeRegExp = function(str) {
1192
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
1193
+ };
1194
+
1195
+ exports.escapeHTML = function(str) {
1196
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
1197
+ };
1198
+
1199
+ exports.getMatchOffsets = function(string, regExp) {
1200
+ var matches = [];
1201
+
1202
+ string.replace(regExp, function(str) {
1203
+ matches.push({
1204
+ offset: arguments[arguments.length-2],
1205
+ length: str.length
1206
+ });
1207
+ });
1208
+
1209
+ return matches;
1210
+ };
1211
+ exports.deferredCall = function(fcn) {
1212
+ var timer = null;
1213
+ var callback = function() {
1214
+ timer = null;
1215
+ fcn();
1216
+ };
1217
+
1218
+ var deferred = function(timeout) {
1219
+ deferred.cancel();
1220
+ timer = setTimeout(callback, timeout || 0);
1221
+ return deferred;
1222
+ };
1223
+
1224
+ deferred.schedule = deferred;
1225
+
1226
+ deferred.call = function() {
1227
+ this.cancel();
1228
+ fcn();
1229
+ return deferred;
1230
+ };
1231
+
1232
+ deferred.cancel = function() {
1233
+ clearTimeout(timer);
1234
+ timer = null;
1235
+ return deferred;
1236
+ };
1237
+
1238
+ deferred.isPending = function() {
1239
+ return timer;
1240
+ };
1241
+
1242
+ return deferred;
1243
+ };
1244
+
1245
+
1246
+ exports.delayedCall = function(fcn, defaultTimeout) {
1247
+ var timer = null;
1248
+ var callback = function() {
1249
+ timer = null;
1250
+ fcn();
1251
+ };
1252
+
1253
+ var _self = function(timeout) {
1254
+ if (timer == null)
1255
+ timer = setTimeout(callback, timeout || defaultTimeout);
1256
+ };
1257
+
1258
+ _self.delay = function(timeout) {
1259
+ timer && clearTimeout(timer);
1260
+ timer = setTimeout(callback, timeout || defaultTimeout);
1261
+ };
1262
+ _self.schedule = _self;
1263
+
1264
+ _self.call = function() {
1265
+ this.cancel();
1266
+ fcn();
1267
+ };
1268
+
1269
+ _self.cancel = function() {
1270
+ timer && clearTimeout(timer);
1271
+ timer = null;
1272
+ };
1273
+
1274
+ _self.isPending = function() {
1275
+ return timer;
1276
+ };
1277
+
1278
+ return _self;
1279
+ };
1280
+ });
1281
+
1282
+ define("ace/worker/mirror",["require","exports","module","ace/document","ace/lib/lang"], function(require, exports, module) {
1283
+ "use strict";
1284
+
1285
+ var Document = require("../document").Document;
1286
+ var lang = require("../lib/lang");
1287
+
1288
+ var Mirror = exports.Mirror = function(sender) {
1289
+ this.sender = sender;
1290
+ var doc = this.doc = new Document("");
1291
+
1292
+ var deferredUpdate = this.deferredUpdate = lang.delayedCall(this.onUpdate.bind(this));
1293
+
1294
+ var _self = this;
1295
+ sender.on("change", function(e) {
1296
+ doc.applyDeltas(e.data);
1297
+ if (_self.$timeout)
1298
+ return deferredUpdate.schedule(_self.$timeout);
1299
+ _self.onUpdate();
1300
+ });
1301
+ };
1302
+
1303
+ (function() {
1304
+
1305
+ this.$timeout = 500;
1306
+
1307
+ this.setTimeout = function(timeout) {
1308
+ this.$timeout = timeout;
1309
+ };
1310
+
1311
+ this.setValue = function(value) {
1312
+ this.doc.setValue(value);
1313
+ this.deferredUpdate.schedule(this.$timeout);
1314
+ };
1315
+
1316
+ this.getValue = function(callbackId) {
1317
+ this.sender.callback(this.doc.getValue(), callbackId);
1318
+ };
1319
+
1320
+ this.onUpdate = function() {
1321
+ };
1322
+
1323
+ this.isPending = function() {
1324
+ return this.deferredUpdate.isPending();
1325
+ };
1326
+
1327
+ }).call(Mirror.prototype);
1328
+
1329
+ });
1330
+
1331
+ define("ace/mode/lua/luaparse",["require","exports","module"], function(require, exports, module) {
1332
+
1333
+ (function (root, name, factory) {
1334
+ factory(exports)
1335
+ }(this, 'luaparse', function (exports) {
1336
+ 'use strict';
1337
+
1338
+ exports.version = '0.1.4';
1339
+
1340
+ var input, options, length;
1341
+ var defaultOptions = exports.defaultOptions = {
1342
+ wait: false
1343
+ , comments: true
1344
+ , scope: false
1345
+ , locations: false
1346
+ , ranges: false
1347
+ };
1348
+
1349
+ var EOF = 1, StringLiteral = 2, Keyword = 4, Identifier = 8
1350
+ , NumericLiteral = 16, Punctuator = 32, BooleanLiteral = 64
1351
+ , NilLiteral = 128, VarargLiteral = 256;
1352
+
1353
+ exports.tokenTypes = { EOF: EOF, StringLiteral: StringLiteral
1354
+ , Keyword: Keyword, Identifier: Identifier, NumericLiteral: NumericLiteral
1355
+ , Punctuator: Punctuator, BooleanLiteral: BooleanLiteral
1356
+ , NilLiteral: NilLiteral, VarargLiteral: VarargLiteral
1357
+ };
1358
+
1359
+ var errors = exports.errors = {
1360
+ unexpected: 'Unexpected %1 \'%2\' near \'%3\''
1361
+ , expected: '\'%1\' expected near \'%2\''
1362
+ , expectedToken: '%1 expected near \'%2\''
1363
+ , unfinishedString: 'unfinished string near \'%1\''
1364
+ , malformedNumber: 'malformed number near \'%1\''
1365
+ };
1366
+
1367
+ var ast = exports.ast = {
1368
+ labelStatement: function(label) {
1369
+ return {
1370
+ type: 'LabelStatement'
1371
+ , label: label
1372
+ };
1373
+ }
1374
+
1375
+ , breakStatement: function() {
1376
+ return {
1377
+ type: 'BreakStatement'
1378
+ };
1379
+ }
1380
+
1381
+ , gotoStatement: function(label) {
1382
+ return {
1383
+ type: 'GotoStatement'
1384
+ , label: label
1385
+ };
1386
+ }
1387
+
1388
+ , returnStatement: function(args) {
1389
+ return {
1390
+ type: 'ReturnStatement'
1391
+ , 'arguments': args
1392
+ };
1393
+ }
1394
+
1395
+ , ifStatement: function(clauses) {
1396
+ return {
1397
+ type: 'IfStatement'
1398
+ , clauses: clauses
1399
+ };
1400
+ }
1401
+ , ifClause: function(condition, body) {
1402
+ return {
1403
+ type: 'IfClause'
1404
+ , condition: condition
1405
+ , body: body
1406
+ };
1407
+ }
1408
+ , elseifClause: function(condition, body) {
1409
+ return {
1410
+ type: 'ElseifClause'
1411
+ , condition: condition
1412
+ , body: body
1413
+ };
1414
+ }
1415
+ , elseClause: function(body) {
1416
+ return {
1417
+ type: 'ElseClause'
1418
+ , body: body
1419
+ };
1420
+ }
1421
+
1422
+ , whileStatement: function(condition, body) {
1423
+ return {
1424
+ type: 'WhileStatement'
1425
+ , condition: condition
1426
+ , body: body
1427
+ };
1428
+ }
1429
+
1430
+ , doStatement: function(body) {
1431
+ return {
1432
+ type: 'DoStatement'
1433
+ , body: body
1434
+ };
1435
+ }
1436
+
1437
+ , repeatStatement: function(condition, body) {
1438
+ return {
1439
+ type: 'RepeatStatement'
1440
+ , condition: condition
1441
+ , body: body
1442
+ };
1443
+ }
1444
+
1445
+ , localStatement: function(variables, init) {
1446
+ return {
1447
+ type: 'LocalStatement'
1448
+ , variables: variables
1449
+ , init: init
1450
+ };
1451
+ }
1452
+
1453
+ , assignmentStatement: function(variables, init) {
1454
+ return {
1455
+ type: 'AssignmentStatement'
1456
+ , variables: variables
1457
+ , init: init
1458
+ };
1459
+ }
1460
+
1461
+ , callStatement: function(expression) {
1462
+ return {
1463
+ type: 'CallStatement'
1464
+ , expression: expression
1465
+ };
1466
+ }
1467
+
1468
+ , functionStatement: function(identifier, parameters, isLocal, body) {
1469
+ return {
1470
+ type: 'FunctionDeclaration'
1471
+ , identifier: identifier
1472
+ , isLocal: isLocal
1473
+ , parameters: parameters
1474
+ , body: body
1475
+ };
1476
+ }
1477
+
1478
+ , forNumericStatement: function(variable, start, end, step, body) {
1479
+ return {
1480
+ type: 'ForNumericStatement'
1481
+ , variable: variable
1482
+ , start: start
1483
+ , end: end
1484
+ , step: step
1485
+ , body: body
1486
+ };
1487
+ }
1488
+
1489
+ , forGenericStatement: function(variables, iterators, body) {
1490
+ return {
1491
+ type: 'ForGenericStatement'
1492
+ , variables: variables
1493
+ , iterators: iterators
1494
+ , body: body
1495
+ };
1496
+ }
1497
+
1498
+ , chunk: function(body) {
1499
+ return {
1500
+ type: 'Chunk'
1501
+ , body: body
1502
+ };
1503
+ }
1504
+
1505
+ , identifier: function(name) {
1506
+ return {
1507
+ type: 'Identifier'
1508
+ , name: name
1509
+ };
1510
+ }
1511
+
1512
+ , literal: function(type, value, raw) {
1513
+ type = (type === StringLiteral) ? 'StringLiteral'
1514
+ : (type === NumericLiteral) ? 'NumericLiteral'
1515
+ : (type === BooleanLiteral) ? 'BooleanLiteral'
1516
+ : (type === NilLiteral) ? 'NilLiteral'
1517
+ : 'VarargLiteral';
1518
+
1519
+ return {
1520
+ type: type
1521
+ , value: value
1522
+ , raw: raw
1523
+ };
1524
+ }
1525
+
1526
+ , tableKey: function(key, value) {
1527
+ return {
1528
+ type: 'TableKey'
1529
+ , key: key
1530
+ , value: value
1531
+ };
1532
+ }
1533
+ , tableKeyString: function(key, value) {
1534
+ return {
1535
+ type: 'TableKeyString'
1536
+ , key: key
1537
+ , value: value
1538
+ };
1539
+ }
1540
+ , tableValue: function(value) {
1541
+ return {
1542
+ type: 'TableValue'
1543
+ , value: value
1544
+ };
1545
+ }
1546
+
1547
+
1548
+ , tableConstructorExpression: function(fields) {
1549
+ return {
1550
+ type: 'TableConstructorExpression'
1551
+ , fields: fields
1552
+ };
1553
+ }
1554
+ , binaryExpression: function(operator, left, right) {
1555
+ var type = ('and' === operator || 'or' === operator) ?
1556
+ 'LogicalExpression' :
1557
+ 'BinaryExpression';
1558
+
1559
+ return {
1560
+ type: type
1561
+ , operator: operator
1562
+ , left: left
1563
+ , right: right
1564
+ };
1565
+ }
1566
+ , unaryExpression: function(operator, argument) {
1567
+ return {
1568
+ type: 'UnaryExpression'
1569
+ , operator: operator
1570
+ , argument: argument
1571
+ };
1572
+ }
1573
+ , memberExpression: function(base, indexer, identifier) {
1574
+ return {
1575
+ type: 'MemberExpression'
1576
+ , indexer: indexer
1577
+ , identifier: identifier
1578
+ , base: base
1579
+ };
1580
+ }
1581
+
1582
+ , indexExpression: function(base, index) {
1583
+ return {
1584
+ type: 'IndexExpression'
1585
+ , base: base
1586
+ , index: index
1587
+ };
1588
+ }
1589
+
1590
+ , callExpression: function(base, args) {
1591
+ return {
1592
+ type: 'CallExpression'
1593
+ , base: base
1594
+ , 'arguments': args
1595
+ };
1596
+ }
1597
+
1598
+ , tableCallExpression: function(base, args) {
1599
+ return {
1600
+ type: 'TableCallExpression'
1601
+ , base: base
1602
+ , 'arguments': args
1603
+ };
1604
+ }
1605
+
1606
+ , stringCallExpression: function(base, argument) {
1607
+ return {
1608
+ type: 'StringCallExpression'
1609
+ , base: base
1610
+ , argument: argument
1611
+ };
1612
+ }
1613
+
1614
+ , comment: function(value, raw) {
1615
+ return {
1616
+ type: 'Comment'
1617
+ , value: value
1618
+ , raw: raw
1619
+ };
1620
+ }
1621
+ };
1622
+
1623
+ function finishNode(node) {
1624
+ if (trackLocations) {
1625
+ var location = locations.pop();
1626
+ location.complete();
1627
+ if (options.locations) node.loc = location.loc;
1628
+ if (options.ranges) node.range = location.range;
1629
+ }
1630
+ return node;
1631
+ }
1632
+
1633
+ var slice = Array.prototype.slice
1634
+ , toString = Object.prototype.toString
1635
+ , indexOf = function indexOf(array, element) {
1636
+ for (var i = 0, length = array.length; i < length; i++) {
1637
+ if (array[i] === element) return i;
1638
+ }
1639
+ return -1;
1640
+ };
1641
+
1642
+ function indexOfObject(array, property, element) {
1643
+ for (var i = 0, length = array.length; i < length; i++) {
1644
+ if (array[i][property] === element) return i;
1645
+ }
1646
+ return -1;
1647
+ }
1648
+
1649
+ function sprintf(format) {
1650
+ var args = slice.call(arguments, 1);
1651
+ format = format.replace(/%(\d)/g, function (match, index) {
1652
+ return '' + args[index - 1] || '';
1653
+ });
1654
+ return format;
1655
+ }
1656
+
1657
+ function extend() {
1658
+ var args = slice.call(arguments)
1659
+ , dest = {}
1660
+ , src, prop;
1661
+
1662
+ for (var i = 0, length = args.length; i < length; i++) {
1663
+ src = args[i];
1664
+ for (prop in src) if (src.hasOwnProperty(prop)) {
1665
+ dest[prop] = src[prop];
1666
+ }
1667
+ }
1668
+ return dest;
1669
+ }
1670
+
1671
+ function raise(token) {
1672
+ var message = sprintf.apply(null, slice.call(arguments, 1))
1673
+ , error, col;
1674
+
1675
+ if ('undefined' !== typeof token.line) {
1676
+ col = token.range[0] - token.lineStart;
1677
+ error = new SyntaxError(sprintf('[%1:%2] %3', token.line, col, message));
1678
+ error.line = token.line;
1679
+ error.index = token.range[0];
1680
+ error.column = col;
1681
+ } else {
1682
+ col = index - lineStart + 1;
1683
+ error = new SyntaxError(sprintf('[%1:%2] %3', line, col, message));
1684
+ error.index = index;
1685
+ error.line = line;
1686
+ error.column = col;
1687
+ }
1688
+ throw error;
1689
+ }
1690
+
1691
+ function raiseUnexpectedToken(type, token) {
1692
+ raise(token, errors.expectedToken, type, token.value);
1693
+ }
1694
+
1695
+ function unexpected(found, near) {
1696
+ if ('undefined' === typeof near) near = lookahead.value;
1697
+ if ('undefined' !== typeof found.type) {
1698
+ var type;
1699
+ switch (found.type) {
1700
+ case StringLiteral: type = 'string'; break;
1701
+ case Keyword: type = 'keyword'; break;
1702
+ case Identifier: type = 'identifier'; break;
1703
+ case NumericLiteral: type = 'number'; break;
1704
+ case Punctuator: type = 'symbol'; break;
1705
+ case BooleanLiteral: type = 'boolean'; break;
1706
+ case NilLiteral:
1707
+ return raise(found, errors.unexpected, 'symbol', 'nil', near);
1708
+ }
1709
+ return raise(found, errors.unexpected, type, found.value, near);
1710
+ }
1711
+ return raise(found, errors.unexpected, 'symbol', found, near);
1712
+ }
1713
+
1714
+ var index
1715
+ , token
1716
+ , previousToken
1717
+ , lookahead
1718
+ , comments
1719
+ , tokenStart
1720
+ , line
1721
+ , lineStart;
1722
+
1723
+ exports.lex = lex;
1724
+
1725
+ function lex() {
1726
+ skipWhiteSpace();
1727
+ while (45 === input.charCodeAt(index) &&
1728
+ 45 === input.charCodeAt(index + 1)) {
1729
+ scanComment();
1730
+ skipWhiteSpace();
1731
+ }
1732
+ if (index >= length) return {
1733
+ type : EOF
1734
+ , value: '<eof>'
1735
+ , line: line
1736
+ , lineStart: lineStart
1737
+ , range: [index, index]
1738
+ };
1739
+
1740
+ var charCode = input.charCodeAt(index)
1741
+ , next = input.charCodeAt(index + 1);
1742
+ tokenStart = index;
1743
+ if (isIdentifierStart(charCode)) return scanIdentifierOrKeyword();
1744
+
1745
+ switch (charCode) {
1746
+ case 39: case 34: // '"
1747
+ return scanStringLiteral();
1748
+ case 48: case 49: case 50: case 51: case 52: case 53:
1749
+ case 54: case 55: case 56: case 57:
1750
+ return scanNumericLiteral();
1751
+
1752
+ case 46: // .
1753
+ if (isDecDigit(next)) return scanNumericLiteral();
1754
+ if (46 === next) {
1755
+ if (46 === input.charCodeAt(index + 2)) return scanVarargLiteral();
1756
+ return scanPunctuator('..');
1757
+ }
1758
+ return scanPunctuator('.');
1759
+
1760
+ case 61: // =
1761
+ if (61 === next) return scanPunctuator('==');
1762
+ return scanPunctuator('=');
1763
+
1764
+ case 62: // >
1765
+ if (61 === next) return scanPunctuator('>=');
1766
+ return scanPunctuator('>');
1767
+
1768
+ case 60: // <
1769
+ if (61 === next) return scanPunctuator('<=');
1770
+ return scanPunctuator('<');
1771
+
1772
+ case 126: // ~
1773
+ if (61 === next) return scanPunctuator('~=');
1774
+ return raise({}, errors.expected, '=', '~');
1775
+
1776
+ case 58: // :
1777
+ if (58 === next) return scanPunctuator('::');
1778
+ return scanPunctuator(':');
1779
+
1780
+ case 91: // [
1781
+ if (91 === next || 61 === next) return scanLongStringLiteral();
1782
+ return scanPunctuator('[');
1783
+ case 42: case 47: case 94: case 37: case 44: case 123: case 125:
1784
+ case 93: case 40: case 41: case 59: case 35: case 45: case 43:
1785
+ return scanPunctuator(input.charAt(index));
1786
+ }
1787
+
1788
+ return unexpected(input.charAt(index));
1789
+ }
1790
+
1791
+ function skipWhiteSpace() {
1792
+ while (index < length) {
1793
+ var charCode = input.charCodeAt(index);
1794
+ if (isWhiteSpace(charCode)) {
1795
+ index++;
1796
+ } else if (isLineTerminator(charCode)) {
1797
+ line++;
1798
+ lineStart = ++index;
1799
+ } else {
1800
+ break;
1801
+ }
1802
+ }
1803
+ }
1804
+
1805
+ function scanIdentifierOrKeyword() {
1806
+ var value, type;
1807
+ while (isIdentifierPart(input.charCodeAt(++index)));
1808
+ value = input.slice(tokenStart, index);
1809
+ if (isKeyword(value)) {
1810
+ type = Keyword;
1811
+ } else if ('true' === value || 'false' === value) {
1812
+ type = BooleanLiteral;
1813
+ value = ('true' === value);
1814
+ } else if ('nil' === value) {
1815
+ type = NilLiteral;
1816
+ value = null;
1817
+ } else {
1818
+ type = Identifier;
1819
+ }
1820
+
1821
+ return {
1822
+ type: type
1823
+ , value: value
1824
+ , line: line
1825
+ , lineStart: lineStart
1826
+ , range: [tokenStart, index]
1827
+ };
1828
+ }
1829
+
1830
+ function scanPunctuator(value) {
1831
+ index += value.length;
1832
+ return {
1833
+ type: Punctuator
1834
+ , value: value
1835
+ , line: line
1836
+ , lineStart: lineStart
1837
+ , range: [tokenStart, index]
1838
+ };
1839
+ }
1840
+
1841
+ function scanVarargLiteral() {
1842
+ index += 3;
1843
+ return {
1844
+ type: VarargLiteral
1845
+ , value: '...'
1846
+ , line: line
1847
+ , lineStart: lineStart
1848
+ , range: [tokenStart, index]
1849
+ };
1850
+ }
1851
+
1852
+ function scanStringLiteral() {
1853
+ var delimiter = input.charCodeAt(index++)
1854
+ , stringStart = index
1855
+ , string = ''
1856
+ , charCode;
1857
+
1858
+ while (index < length) {
1859
+ charCode = input.charCodeAt(index++);
1860
+ if (delimiter === charCode) break;
1861
+ if (92 === charCode) { // \
1862
+ string += input.slice(stringStart, index - 1) + readEscapeSequence();
1863
+ stringStart = index;
1864
+ }
1865
+ else if (index >= length || isLineTerminator(charCode)) {
1866
+ string += input.slice(stringStart, index - 1);
1867
+ raise({}, errors.unfinishedString, string + String.fromCharCode(charCode));
1868
+ }
1869
+ }
1870
+ string += input.slice(stringStart, index - 1);
1871
+
1872
+ return {
1873
+ type: StringLiteral
1874
+ , value: string
1875
+ , line: line
1876
+ , lineStart: lineStart
1877
+ , range: [tokenStart, index]
1878
+ };
1879
+ }
1880
+
1881
+ function scanLongStringLiteral() {
1882
+ var string = readLongString();
1883
+ if (false === string) raise(token, errors.expected, '[', token.value);
1884
+
1885
+ return {
1886
+ type: StringLiteral
1887
+ , value: string
1888
+ , line: line
1889
+ , lineStart: lineStart
1890
+ , range: [tokenStart, index]
1891
+ };
1892
+ }
1893
+
1894
+ function scanNumericLiteral() {
1895
+ var character = input.charAt(index)
1896
+ , next = input.charAt(index + 1);
1897
+
1898
+ var value = ('0' === character && 'xX'.indexOf(next || null) >= 0) ?
1899
+ readHexLiteral() : readDecLiteral();
1900
+
1901
+ return {
1902
+ type: NumericLiteral
1903
+ , value: value
1904
+ , line: line
1905
+ , lineStart: lineStart
1906
+ , range: [tokenStart, index]
1907
+ };
1908
+ }
1909
+
1910
+ function readHexLiteral() {
1911
+ var fraction = 0 // defaults to 0 as it gets summed
1912
+ , binaryExponent = 1 // defaults to 1 as it gets multiplied
1913
+ , binarySign = 1 // positive
1914
+ , digit, fractionStart, exponentStart, digitStart;
1915
+
1916
+ digitStart = index += 2; // Skip 0x part
1917
+ if (!isHexDigit(input.charCodeAt(index)))
1918
+ raise({}, errors.malformedNumber, input.slice(tokenStart, index));
1919
+
1920
+ while (isHexDigit(input.charCodeAt(index))) index++;
1921
+ digit = parseInt(input.slice(digitStart, index), 16);
1922
+ if ('.' === input.charAt(index)) {
1923
+ fractionStart = ++index;
1924
+
1925
+ while (isHexDigit(input.charCodeAt(index))) index++;
1926
+ fraction = input.slice(fractionStart, index);
1927
+ fraction = (fractionStart === index) ? 0
1928
+ : parseInt(fraction, 16) / Math.pow(16, index - fractionStart);
1929
+ }
1930
+ if ('pP'.indexOf(input.charAt(index) || null) >= 0) {
1931
+ index++;
1932
+ if ('+-'.indexOf(input.charAt(index) || null) >= 0)
1933
+ binarySign = ('+' === input.charAt(index++)) ? 1 : -1;
1934
+
1935
+ exponentStart = index;
1936
+ if (!isDecDigit(input.charCodeAt(index)))
1937
+ raise({}, errors.malformedNumber, input.slice(tokenStart, index));
1938
+
1939
+ while (isDecDigit(input.charCodeAt(index))) index++;
1940
+ binaryExponent = input.slice(exponentStart, index);
1941
+ binaryExponent = Math.pow(2, binaryExponent * binarySign);
1942
+ }
1943
+
1944
+ return (digit + fraction) * binaryExponent;
1945
+ }
1946
+
1947
+ function readDecLiteral() {
1948
+ while (isDecDigit(input.charCodeAt(index))) index++;
1949
+ if ('.' === input.charAt(index)) {
1950
+ index++;
1951
+ while (isDecDigit(input.charCodeAt(index))) index++;
1952
+ }
1953
+ if ('eE'.indexOf(input.charAt(index) || null) >= 0) {
1954
+ index++;
1955
+ if ('+-'.indexOf(input.charAt(index) || null) >= 0) index++;
1956
+ if (!isDecDigit(input.charCodeAt(index)))
1957
+ raise({}, errors.malformedNumber, input.slice(tokenStart, index));
1958
+
1959
+ while (isDecDigit(input.charCodeAt(index))) index++;
1960
+ }
1961
+
1962
+ return parseFloat(input.slice(tokenStart, index));
1963
+ }
1964
+
1965
+ function readEscapeSequence() {
1966
+ var sequenceStart = index;
1967
+ switch (input.charAt(index)) {
1968
+ case 'n': index++; return '\n';
1969
+ case 'r': index++; return '\r';
1970
+ case 't': index++; return '\t';
1971
+ case 'v': index++; return '\x0B';
1972
+ case 'b': index++; return '\b';
1973
+ case 'f': index++; return '\f';
1974
+ case 'z': index++; skipWhiteSpace(); return '';
1975
+ case 'x':
1976
+ if (isHexDigit(input.charCodeAt(index + 1)) &&
1977
+ isHexDigit(input.charCodeAt(index + 2))) {
1978
+ index += 3;
1979
+ return '\\' + input.slice(sequenceStart, index);
1980
+ }
1981
+ return '\\' + input.charAt(index++);
1982
+ default:
1983
+ if (isDecDigit(input.charCodeAt(index))) {
1984
+ while (isDecDigit(input.charCodeAt(++index)));
1985
+ return '\\' + input.slice(sequenceStart, index);
1986
+ }
1987
+ return input.charAt(index++);
1988
+ }
1989
+ }
1990
+
1991
+ function scanComment() {
1992
+ tokenStart = index;
1993
+ index += 2; // --
1994
+
1995
+ var character = input.charAt(index)
1996
+ , content = ''
1997
+ , isLong = false
1998
+ , commentStart = index
1999
+ , lineStartComment = lineStart
2000
+ , lineComment = line;
2001
+
2002
+ if ('[' === character) {
2003
+ content = readLongString();
2004
+ if (false === content) content = character;
2005
+ else isLong = true;
2006
+ }
2007
+ if (!isLong) {
2008
+ while (index < length) {
2009
+ if (isLineTerminator(input.charCodeAt(index))) break;
2010
+ index++;
2011
+ }
2012
+ if (options.comments) content = input.slice(commentStart, index);
2013
+ }
2014
+
2015
+ if (options.comments) {
2016
+ var node = ast.comment(content, input.slice(tokenStart, index));
2017
+ if (options.locations) {
2018
+ node.loc = {
2019
+ start: { line: lineComment, column: tokenStart - lineStartComment }
2020
+ , end: { line: line, column: index - lineStart }
2021
+ };
2022
+ }
2023
+ if (options.ranges) {
2024
+ node.range = [tokenStart, index];
2025
+ }
2026
+ comments.push(node);
2027
+ }
2028
+ }
2029
+
2030
+ function readLongString() {
2031
+ var level = 0
2032
+ , content = ''
2033
+ , terminator = false
2034
+ , character, stringStart;
2035
+
2036
+ index++; // [
2037
+ while ('=' === input.charAt(index + level)) level++;
2038
+ if ('[' !== input.charAt(index + level)) return false;
2039
+
2040
+ index += level + 1;
2041
+ if (isLineTerminator(input.charCodeAt(index))) {
2042
+ line++;
2043
+ lineStart = index++;
2044
+ }
2045
+
2046
+ stringStart = index;
2047
+ while (index < length) {
2048
+ character = input.charAt(index++);
2049
+ if (isLineTerminator(character.charCodeAt(0))) {
2050
+ line++;
2051
+ lineStart = index;
2052
+ }
2053
+ if (']' === character) {
2054
+ terminator = true;
2055
+ for (var i = 0; i < level; i++) {
2056
+ if ('=' !== input.charAt(index + i)) terminator = false;
2057
+ }
2058
+ if (']' !== input.charAt(index + level)) terminator = false;
2059
+ }
2060
+ if (terminator) break;
2061
+ }
2062
+ content += input.slice(stringStart, index - 1);
2063
+ index += level + 1;
2064
+
2065
+ return content;
2066
+ }
2067
+
2068
+ function next() {
2069
+ previousToken = token;
2070
+ token = lookahead;
2071
+ lookahead = lex();
2072
+ }
2073
+
2074
+ function consume(value) {
2075
+ if (value === token.value) {
2076
+ next();
2077
+ return true;
2078
+ }
2079
+ return false;
2080
+ }
2081
+
2082
+ function expect(value) {
2083
+ if (value === token.value) next();
2084
+ else raise(token, errors.expected, value, token.value);
2085
+ }
2086
+
2087
+ function isWhiteSpace(charCode) {
2088
+ return 9 === charCode || 32 === charCode || 0xB === charCode || 0xC === charCode;
2089
+ }
2090
+
2091
+ function isLineTerminator(charCode) {
2092
+ return 10 === charCode || 13 === charCode;
2093
+ }
2094
+
2095
+ function isDecDigit(charCode) {
2096
+ return charCode >= 48 && charCode <= 57;
2097
+ }
2098
+
2099
+ function isHexDigit(charCode) {
2100
+ return (charCode >= 48 && charCode <= 57) || (charCode >= 97 && charCode <= 102) || (charCode >= 65 && charCode <= 70);
2101
+ }
2102
+
2103
+ function isIdentifierStart(charCode) {
2104
+ return (charCode >= 65 && charCode <= 90) || (charCode >= 97 && charCode <= 122) || 95 === charCode;
2105
+ }
2106
+
2107
+ function isIdentifierPart(charCode) {
2108
+ return (charCode >= 65 && charCode <= 90) || (charCode >= 97 && charCode <= 122) || 95 === charCode || (charCode >= 48 && charCode <= 57);
2109
+ }
2110
+
2111
+ function isKeyword(id) {
2112
+ switch (id.length) {
2113
+ case 2:
2114
+ return 'do' === id || 'if' === id || 'in' === id || 'or' === id;
2115
+ case 3:
2116
+ return 'and' === id || 'end' === id || 'for' === id || 'not' === id;
2117
+ case 4:
2118
+ return 'else' === id || 'goto' === id || 'then' === id;
2119
+ case 5:
2120
+ return 'break' === id || 'local' === id || 'until' === id || 'while' === id;
2121
+ case 6:
2122
+ return 'elseif' === id || 'repeat' === id || 'return' === id;
2123
+ case 8:
2124
+ return 'function' === id;
2125
+ }
2126
+ return false;
2127
+ }
2128
+
2129
+ function isUnary(token) {
2130
+ if (Punctuator === token.type) return '#-'.indexOf(token.value) >= 0;
2131
+ if (Keyword === token.type) return 'not' === token.value;
2132
+ return false;
2133
+ }
2134
+ function isCallExpression(expression) {
2135
+ switch (expression.type) {
2136
+ case 'CallExpression':
2137
+ case 'TableCallExpression':
2138
+ case 'StringCallExpression':
2139
+ return true;
2140
+ }
2141
+ return false;
2142
+ }
2143
+
2144
+ function isBlockFollow(token) {
2145
+ if (EOF === token.type) return true;
2146
+ if (Keyword !== token.type) return false;
2147
+ switch (token.value) {
2148
+ case 'else': case 'elseif':
2149
+ case 'end': case 'until':
2150
+ return true;
2151
+ default:
2152
+ return false;
2153
+ }
2154
+ }
2155
+ var scopes
2156
+ , scopeDepth
2157
+ , globals;
2158
+ function createScope() {
2159
+ scopes.push(Array.apply(null, scopes[scopeDepth++]));
2160
+ }
2161
+ function exitScope() {
2162
+ scopes.pop();
2163
+ scopeDepth--;
2164
+ }
2165
+ function scopeIdentifierName(name) {
2166
+ if (-1 !== indexOf(scopes[scopeDepth], name)) return;
2167
+ scopes[scopeDepth].push(name);
2168
+ }
2169
+ function scopeIdentifier(node) {
2170
+ scopeIdentifierName(node.name);
2171
+ attachScope(node, true);
2172
+ }
2173
+ function attachScope(node, isLocal) {
2174
+ if (!isLocal && -1 === indexOfObject(globals, 'name', node.name))
2175
+ globals.push(node);
2176
+
2177
+ node.isLocal = isLocal;
2178
+ }
2179
+ function scopeHasName(name) {
2180
+ return (-1 !== indexOf(scopes[scopeDepth], name));
2181
+ }
2182
+
2183
+ var locations = []
2184
+ , trackLocations;
2185
+
2186
+ function createLocationMarker() {
2187
+ return new Marker(token);
2188
+ }
2189
+
2190
+ function Marker(token) {
2191
+ if (options.locations) {
2192
+ this.loc = {
2193
+ start: {
2194
+ line: token.line
2195
+ , column: token.range[0] - token.lineStart
2196
+ }
2197
+ , end: {
2198
+ line: 0
2199
+ , column: 0
2200
+ }
2201
+ };
2202
+ }
2203
+ if (options.ranges) this.range = [token.range[0], 0];
2204
+ }
2205
+ Marker.prototype.complete = function() {
2206
+ if (options.locations) {
2207
+ this.loc.end.line = previousToken.line;
2208
+ this.loc.end.column = previousToken.range[1] - previousToken.lineStart;
2209
+ }
2210
+ if (options.ranges) {
2211
+ this.range[1] = previousToken.range[1];
2212
+ }
2213
+ };
2214
+ function markLocation() {
2215
+ if (trackLocations) locations.push(createLocationMarker());
2216
+ }
2217
+ function pushLocation(marker) {
2218
+ if (trackLocations) locations.push(marker);
2219
+ }
2220
+
2221
+ function parseChunk() {
2222
+ next();
2223
+ markLocation();
2224
+ var body = parseBlock();
2225
+ if (EOF !== token.type) unexpected(token);
2226
+ if (trackLocations && !body.length) previousToken = token;
2227
+ return finishNode(ast.chunk(body));
2228
+ }
2229
+
2230
+ function parseBlock(terminator) {
2231
+ var block = []
2232
+ , statement;
2233
+ if (options.scope) createScope();
2234
+
2235
+ while (!isBlockFollow(token)) {
2236
+ if ('return' === token.value) {
2237
+ block.push(parseStatement());
2238
+ break;
2239
+ }
2240
+ statement = parseStatement();
2241
+ if (statement) block.push(statement);
2242
+ }
2243
+
2244
+ if (options.scope) exitScope();
2245
+ return block;
2246
+ }
2247
+
2248
+ function parseStatement() {
2249
+ markLocation();
2250
+ if (Keyword === token.type) {
2251
+ switch (token.value) {
2252
+ case 'local': next(); return parseLocalStatement();
2253
+ case 'if': next(); return parseIfStatement();
2254
+ case 'return': next(); return parseReturnStatement();
2255
+ case 'function': next();
2256
+ var name = parseFunctionName();
2257
+ return parseFunctionDeclaration(name);
2258
+ case 'while': next(); return parseWhileStatement();
2259
+ case 'for': next(); return parseForStatement();
2260
+ case 'repeat': next(); return parseRepeatStatement();
2261
+ case 'break': next(); return parseBreakStatement();
2262
+ case 'do': next(); return parseDoStatement();
2263
+ case 'goto': next(); return parseGotoStatement();
2264
+ }
2265
+ }
2266
+
2267
+ if (Punctuator === token.type) {
2268
+ if (consume('::')) return parseLabelStatement();
2269
+ }
2270
+ if (trackLocations) locations.pop();
2271
+ if (consume(';')) return;
2272
+
2273
+ return parseAssignmentOrCallStatement();
2274
+ }
2275
+
2276
+ function parseLabelStatement() {
2277
+ var name = token.value
2278
+ , label = parseIdentifier();
2279
+
2280
+ if (options.scope) {
2281
+ scopeIdentifierName('::' + name + '::');
2282
+ attachScope(label, true);
2283
+ }
2284
+
2285
+ expect('::');
2286
+ return finishNode(ast.labelStatement(label));
2287
+ }
2288
+
2289
+ function parseBreakStatement() {
2290
+ return finishNode(ast.breakStatement());
2291
+ }
2292
+
2293
+ function parseGotoStatement() {
2294
+ var name = token.value
2295
+ , label = parseIdentifier();
2296
+
2297
+ if (options.scope) label.isLabel = scopeHasName('::' + name + '::');
2298
+ return finishNode(ast.gotoStatement(label));
2299
+ }
2300
+
2301
+ function parseDoStatement() {
2302
+ var body = parseBlock();
2303
+ expect('end');
2304
+ return finishNode(ast.doStatement(body));
2305
+ }
2306
+
2307
+ function parseWhileStatement() {
2308
+ var condition = parseExpectedExpression();
2309
+ expect('do');
2310
+ var body = parseBlock();
2311
+ expect('end');
2312
+ return finishNode(ast.whileStatement(condition, body));
2313
+ }
2314
+
2315
+ function parseRepeatStatement() {
2316
+ var body = parseBlock();
2317
+ expect('until');
2318
+ var condition = parseExpectedExpression();
2319
+ return finishNode(ast.repeatStatement(condition, body));
2320
+ }
2321
+
2322
+ function parseReturnStatement() {
2323
+ var expressions = [];
2324
+
2325
+ if ('end' !== token.value) {
2326
+ var expression = parseExpression();
2327
+ if (null != expression) expressions.push(expression);
2328
+ while (consume(',')) {
2329
+ expression = parseExpectedExpression();
2330
+ expressions.push(expression);
2331
+ }
2332
+ consume(';'); // grammar tells us ; is optional here.
2333
+ }
2334
+ return finishNode(ast.returnStatement(expressions));
2335
+ }
2336
+
2337
+ function parseIfStatement() {
2338
+ var clauses = []
2339
+ , condition
2340
+ , body
2341
+ , marker;
2342
+ if (trackLocations) {
2343
+ marker = locations[locations.length - 1];
2344
+ locations.push(marker);
2345
+ }
2346
+ condition = parseExpectedExpression();
2347
+ expect('then');
2348
+ body = parseBlock();
2349
+ clauses.push(finishNode(ast.ifClause(condition, body)));
2350
+
2351
+ if (trackLocations) marker = createLocationMarker();
2352
+ while (consume('elseif')) {
2353
+ pushLocation(marker);
2354
+ condition = parseExpectedExpression();
2355
+ expect('then');
2356
+ body = parseBlock();
2357
+ clauses.push(finishNode(ast.elseifClause(condition, body)));
2358
+ if (trackLocations) marker = createLocationMarker();
2359
+ }
2360
+
2361
+ if (consume('else')) {
2362
+ if (trackLocations) {
2363
+ marker = new Marker(previousToken);
2364
+ locations.push(marker);
2365
+ }
2366
+ body = parseBlock();
2367
+ clauses.push(finishNode(ast.elseClause(body)));
2368
+ }
2369
+
2370
+ expect('end');
2371
+ return finishNode(ast.ifStatement(clauses));
2372
+ }
2373
+
2374
+ function parseForStatement() {
2375
+ var variable = parseIdentifier()
2376
+ , body;
2377
+ if (options.scope) scopeIdentifier(variable);
2378
+ if (consume('=')) {
2379
+ var start = parseExpectedExpression();
2380
+ expect(',');
2381
+ var end = parseExpectedExpression();
2382
+ var step = consume(',') ? parseExpectedExpression() : null;
2383
+
2384
+ expect('do');
2385
+ body = parseBlock();
2386
+ expect('end');
2387
+
2388
+ return finishNode(ast.forNumericStatement(variable, start, end, step, body));
2389
+ }
2390
+ else {
2391
+ var variables = [variable];
2392
+ while (consume(',')) {
2393
+ variable = parseIdentifier();
2394
+ if (options.scope) scopeIdentifier(variable);
2395
+ variables.push(variable);
2396
+ }
2397
+ expect('in');
2398
+ var iterators = [];
2399
+ do {
2400
+ var expression = parseExpectedExpression();
2401
+ iterators.push(expression);
2402
+ } while (consume(','));
2403
+
2404
+ expect('do');
2405
+ body = parseBlock();
2406
+ expect('end');
2407
+
2408
+ return finishNode(ast.forGenericStatement(variables, iterators, body));
2409
+ }
2410
+ }
2411
+
2412
+ function parseLocalStatement() {
2413
+ var name;
2414
+
2415
+ if (Identifier === token.type) {
2416
+ var variables = []
2417
+ , init = [];
2418
+
2419
+ do {
2420
+ name = parseIdentifier();
2421
+
2422
+ variables.push(name);
2423
+ } while (consume(','));
2424
+
2425
+ if (consume('=')) {
2426
+ do {
2427
+ var expression = parseExpectedExpression();
2428
+ init.push(expression);
2429
+ } while (consume(','));
2430
+ }
2431
+ if (options.scope) {
2432
+ for (var i = 0, l = variables.length; i < l; i++) {
2433
+ scopeIdentifier(variables[i]);
2434
+ }
2435
+ }
2436
+
2437
+ return finishNode(ast.localStatement(variables, init));
2438
+ }
2439
+ if (consume('function')) {
2440
+ name = parseIdentifier();
2441
+ if (options.scope) scopeIdentifier(name);
2442
+ return parseFunctionDeclaration(name, true);
2443
+ } else {
2444
+ raiseUnexpectedToken('<name>', token);
2445
+ }
2446
+ }
2447
+
2448
+ function parseAssignmentOrCallStatement() {
2449
+ var previous = token
2450
+ , expression, marker;
2451
+
2452
+ if (trackLocations) marker = createLocationMarker();
2453
+ expression = parsePrefixExpression();
2454
+
2455
+ if (null == expression) return unexpected(token);
2456
+ if (',='.indexOf(token.value) >= 0) {
2457
+ var variables = [expression]
2458
+ , init = []
2459
+ , exp;
2460
+
2461
+ while (consume(',')) {
2462
+ exp = parsePrefixExpression();
2463
+ if (null == exp) raiseUnexpectedToken('<expression>', token);
2464
+ variables.push(exp);
2465
+ }
2466
+ expect('=');
2467
+ do {
2468
+ exp = parseExpectedExpression();
2469
+ init.push(exp);
2470
+ } while (consume(','));
2471
+
2472
+ pushLocation(marker);
2473
+ return finishNode(ast.assignmentStatement(variables, init));
2474
+ }
2475
+ if (isCallExpression(expression)) {
2476
+ pushLocation(marker);
2477
+ return finishNode(ast.callStatement(expression));
2478
+ }
2479
+ return unexpected(previous);
2480
+ }
2481
+
2482
+ function parseIdentifier() {
2483
+ markLocation();
2484
+ var identifier = token.value;
2485
+ if (Identifier !== token.type) raiseUnexpectedToken('<name>', token);
2486
+ next();
2487
+ return finishNode(ast.identifier(identifier));
2488
+ }
2489
+
2490
+ function parseFunctionDeclaration(name, isLocal) {
2491
+ var parameters = [];
2492
+ expect('(');
2493
+ if (!consume(')')) {
2494
+ while (true) {
2495
+ if (Identifier === token.type) {
2496
+ var parameter = parseIdentifier();
2497
+ if (options.scope) scopeIdentifier(parameter);
2498
+
2499
+ parameters.push(parameter);
2500
+
2501
+ if (consume(',')) continue;
2502
+ else if (consume(')')) break;
2503
+ }
2504
+ else if (VarargLiteral === token.type) {
2505
+ parameters.push(parsePrimaryExpression());
2506
+ expect(')');
2507
+ break;
2508
+ } else {
2509
+ raiseUnexpectedToken('<name> or \'...\'', token);
2510
+ }
2511
+ }
2512
+ }
2513
+
2514
+ var body = parseBlock();
2515
+ expect('end');
2516
+
2517
+ isLocal = isLocal || false;
2518
+ return finishNode(ast.functionStatement(name, parameters, isLocal, body));
2519
+ }
2520
+
2521
+ function parseFunctionName() {
2522
+ var base, name, marker;
2523
+
2524
+ if (trackLocations) marker = createLocationMarker();
2525
+ base = parseIdentifier();
2526
+
2527
+ if (options.scope) attachScope(base, false);
2528
+
2529
+ while (consume('.')) {
2530
+ pushLocation(marker);
2531
+ name = parseIdentifier();
2532
+ if (options.scope) attachScope(name, false);
2533
+ base = finishNode(ast.memberExpression(base, '.', name));
2534
+ }
2535
+
2536
+ if (consume(':')) {
2537
+ pushLocation(marker);
2538
+ name = parseIdentifier();
2539
+ if (options.scope) attachScope(name, false);
2540
+ base = finishNode(ast.memberExpression(base, ':', name));
2541
+ }
2542
+
2543
+ return base;
2544
+ }
2545
+
2546
+ function parseTableConstructor() {
2547
+ var fields = []
2548
+ , key, value;
2549
+
2550
+ while (true) {
2551
+ markLocation();
2552
+ if (Punctuator === token.type && consume('[')) {
2553
+ key = parseExpectedExpression();
2554
+ expect(']');
2555
+ expect('=');
2556
+ value = parseExpectedExpression();
2557
+ fields.push(finishNode(ast.tableKey(key, value)));
2558
+ } else if (Identifier === token.type) {
2559
+ key = parseExpectedExpression();
2560
+ if (consume('=')) {
2561
+ value = parseExpectedExpression();
2562
+ fields.push(finishNode(ast.tableKeyString(key, value)));
2563
+ } else {
2564
+ fields.push(finishNode(ast.tableValue(key)));
2565
+ }
2566
+ } else {
2567
+ if (null == (value = parseExpression())) {
2568
+ locations.pop();
2569
+ break;
2570
+ }
2571
+ fields.push(finishNode(ast.tableValue(value)));
2572
+ }
2573
+ if (',;'.indexOf(token.value) >= 0) {
2574
+ next();
2575
+ continue;
2576
+ }
2577
+ if ('}' === token.value) break;
2578
+ }
2579
+ expect('}');
2580
+ return finishNode(ast.tableConstructorExpression(fields));
2581
+ }
2582
+
2583
+ function parseExpression() {
2584
+ var expression = parseSubExpression(0);
2585
+ return expression;
2586
+ }
2587
+
2588
+ function parseExpectedExpression() {
2589
+ var expression = parseExpression();
2590
+ if (null == expression) raiseUnexpectedToken('<expression>', token);
2591
+ else return expression;
2592
+ }
2593
+
2594
+ function binaryPrecedence(operator) {
2595
+ var charCode = operator.charCodeAt(0)
2596
+ , length = operator.length;
2597
+
2598
+ if (1 === length) {
2599
+ switch (charCode) {
2600
+ case 94: return 10; // ^
2601
+ case 42: case 47: case 37: return 7; // * / %
2602
+ case 43: case 45: return 6; // + -
2603
+ case 60: case 62: return 3; // < >
2604
+ }
2605
+ } else if (2 === length) {
2606
+ switch (charCode) {
2607
+ case 46: return 5; // ..
2608
+ case 60: case 62: case 61: case 126: return 3; // <= >= == ~=
2609
+ case 111: return 1; // or
2610
+ }
2611
+ } else if (97 === charCode && 'and' === operator) return 2;
2612
+ return 0;
2613
+ }
2614
+
2615
+ function parseSubExpression(minPrecedence) {
2616
+ var operator = token.value
2617
+ , expression, marker;
2618
+
2619
+ if (trackLocations) marker = createLocationMarker();
2620
+ if (isUnary(token)) {
2621
+ markLocation();
2622
+ next();
2623
+ var argument = parseSubExpression(8);
2624
+ if (argument == null) raiseUnexpectedToken('<expression>', token);
2625
+ expression = finishNode(ast.unaryExpression(operator, argument));
2626
+ }
2627
+ if (null == expression) {
2628
+ expression = parsePrimaryExpression();
2629
+ if (null == expression) {
2630
+ expression = parsePrefixExpression();
2631
+ }
2632
+ }
2633
+ if (null == expression) return null;
2634
+
2635
+ var precedence;
2636
+ while (true) {
2637
+ operator = token.value;
2638
+
2639
+ precedence = (Punctuator === token.type || Keyword === token.type) ?
2640
+ binaryPrecedence(operator) : 0;
2641
+
2642
+ if (precedence === 0 || precedence <= minPrecedence) break;
2643
+ if ('^' === operator || '..' === operator) precedence--;
2644
+ next();
2645
+ var right = parseSubExpression(precedence);
2646
+ if (null == right) raiseUnexpectedToken('<expression>', token);
2647
+ if (trackLocations) locations.push(marker);
2648
+ expression = finishNode(ast.binaryExpression(operator, expression, right));
2649
+
2650
+ }
2651
+ return expression;
2652
+ }
2653
+
2654
+ function parsePrefixExpression() {
2655
+ var base, name, marker
2656
+ , isLocal;
2657
+
2658
+ if (trackLocations) marker = createLocationMarker();
2659
+ if (Identifier === token.type) {
2660
+ name = token.value;
2661
+ base = parseIdentifier();
2662
+ if (options.scope) attachScope(base, isLocal = scopeHasName(name));
2663
+ } else if (consume('(')) {
2664
+ base = parseExpectedExpression();
2665
+ expect(')');
2666
+ if (options.scope) isLocal = base.isLocal;
2667
+ } else {
2668
+ return null;
2669
+ }
2670
+ var expression, identifier;
2671
+ while (true) {
2672
+ if (Punctuator === token.type) {
2673
+ switch (token.value) {
2674
+ case '[':
2675
+ pushLocation(marker);
2676
+ next();
2677
+ expression = parseExpectedExpression();
2678
+ base = finishNode(ast.indexExpression(base, expression));
2679
+ expect(']');
2680
+ break;
2681
+ case '.':
2682
+ pushLocation(marker);
2683
+ next();
2684
+ identifier = parseIdentifier();
2685
+ if (options.scope) attachScope(identifier, isLocal);
2686
+ base = finishNode(ast.memberExpression(base, '.', identifier));
2687
+ break;
2688
+ case ':':
2689
+ pushLocation(marker);
2690
+ next();
2691
+ identifier = parseIdentifier();
2692
+ if (options.scope) attachScope(identifier, isLocal);
2693
+ base = finishNode(ast.memberExpression(base, ':', identifier));
2694
+ pushLocation(marker);
2695
+ base = parseCallExpression(base);
2696
+ break;
2697
+ case '(': case '{': // args
2698
+ pushLocation(marker);
2699
+ base = parseCallExpression(base);
2700
+ break;
2701
+ default:
2702
+ return base;
2703
+ }
2704
+ } else if (StringLiteral === token.type) {
2705
+ pushLocation(marker);
2706
+ base = parseCallExpression(base);
2707
+ } else {
2708
+ break;
2709
+ }
2710
+ }
2711
+
2712
+ return base;
2713
+ }
2714
+
2715
+ function parseCallExpression(base) {
2716
+ if (Punctuator === token.type) {
2717
+ switch (token.value) {
2718
+ case '(':
2719
+ next();
2720
+ var expressions = [];
2721
+ var expression = parseExpression();
2722
+ if (null != expression) expressions.push(expression);
2723
+ while (consume(',')) {
2724
+ expression = parseExpectedExpression();
2725
+ expressions.push(expression);
2726
+ }
2727
+
2728
+ expect(')');
2729
+ return finishNode(ast.callExpression(base, expressions));
2730
+
2731
+ case '{':
2732
+ markLocation();
2733
+ next();
2734
+ var table = parseTableConstructor();
2735
+ return finishNode(ast.tableCallExpression(base, table));
2736
+ }
2737
+ } else if (StringLiteral === token.type) {
2738
+ return finishNode(ast.stringCallExpression(base, parsePrimaryExpression()));
2739
+ }
2740
+
2741
+ raiseUnexpectedToken('function arguments', token);
2742
+ }
2743
+
2744
+ function parsePrimaryExpression() {
2745
+ var literals = StringLiteral | NumericLiteral | BooleanLiteral | NilLiteral | VarargLiteral
2746
+ , value = token.value
2747
+ , type = token.type
2748
+ , marker;
2749
+
2750
+ if (trackLocations) marker = createLocationMarker();
2751
+
2752
+ if (type & literals) {
2753
+ pushLocation(marker);
2754
+ var raw = input.slice(token.range[0], token.range[1]);
2755
+ next();
2756
+ return finishNode(ast.literal(type, value, raw));
2757
+ } else if (Keyword === type && 'function' === value) {
2758
+ pushLocation(marker);
2759
+ next();
2760
+ return parseFunctionDeclaration(null);
2761
+ } else if (consume('{')) {
2762
+ pushLocation(marker);
2763
+ return parseTableConstructor();
2764
+ }
2765
+ }
2766
+
2767
+ exports.parse = parse;
2768
+
2769
+ function parse(_input, _options) {
2770
+ if ('undefined' === typeof _options && 'object' === typeof _input) {
2771
+ _options = _input;
2772
+ _input = undefined;
2773
+ }
2774
+ if (!_options) _options = {};
2775
+
2776
+ input = _input || '';
2777
+ options = extend(defaultOptions, _options);
2778
+ index = 0;
2779
+ line = 1;
2780
+ lineStart = 0;
2781
+ length = input.length;
2782
+ scopes = [[]];
2783
+ scopeDepth = 0;
2784
+ globals = [];
2785
+ locations = [];
2786
+
2787
+ if (options.comments) comments = [];
2788
+ if (!options.wait) return end();
2789
+ return exports;
2790
+ }
2791
+ exports.write = write;
2792
+
2793
+ function write(_input) {
2794
+ input += String(_input);
2795
+ length = input.length;
2796
+ return exports;
2797
+ }
2798
+ exports.end = end;
2799
+
2800
+ function end(_input) {
2801
+ if ('undefined' !== typeof _input) write(_input);
2802
+
2803
+ length = input.length;
2804
+ trackLocations = options.locations || options.ranges;
2805
+ lookahead = lex();
2806
+
2807
+ var chunk = parseChunk();
2808
+ if (options.comments) chunk.comments = comments;
2809
+ if (options.scope) chunk.globals = globals;
2810
+
2811
+ if (locations.length > 0)
2812
+ throw new Error('Location tracking failed. This is most likely a bug in luaparse');
2813
+
2814
+ return chunk;
2815
+ }
2816
+
2817
+ }));
2818
+
2819
+ });
2820
+
2821
+ define("ace/mode/lua_worker",["require","exports","module","ace/lib/oop","ace/worker/mirror","ace/mode/lua/luaparse"], function(require, exports, module) {
2822
+ "use strict";
2823
+
2824
+ var oop = require("../lib/oop");
2825
+ var Mirror = require("../worker/mirror").Mirror;
2826
+ var luaparse = require("../mode/lua/luaparse");
2827
+
2828
+ var Worker = exports.Worker = function(sender) {
2829
+ Mirror.call(this, sender);
2830
+ this.setTimeout(500);
2831
+ };
2832
+
2833
+ oop.inherits(Worker, Mirror);
2834
+
2835
+ (function() {
2836
+
2837
+ this.onUpdate = function() {
2838
+ var value = this.doc.getValue();
2839
+ try {
2840
+ luaparse.parse(value);
2841
+ } catch(e) {
2842
+ if (e instanceof SyntaxError) {
2843
+ this.sender.emit("error", {
2844
+ row: e.line - 1,
2845
+ column: e.column,
2846
+ text: e.message,
2847
+ type: "error"
2848
+ });
2849
+ }
2850
+ return;
2851
+ }
2852
+ this.sender.emit("ok");
2853
+ };
2854
+
2855
+ }).call(Worker.prototype);
2856
+
2857
+ });
2858
+
2859
+ define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
2860
+
2861
+ function Empty() {}
2862
+
2863
+ if (!Function.prototype.bind) {
2864
+ Function.prototype.bind = function bind(that) { // .length is 1
2865
+ var target = this;
2866
+ if (typeof target != "function") {
2867
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
2868
+ }
2869
+ var args = slice.call(arguments, 1); // for normal call
2870
+ var bound = function () {
2871
+
2872
+ if (this instanceof bound) {
2873
+
2874
+ var result = target.apply(
2875
+ this,
2876
+ args.concat(slice.call(arguments))
2877
+ );
2878
+ if (Object(result) === result) {
2879
+ return result;
2880
+ }
2881
+ return this;
2882
+
2883
+ } else {
2884
+ return target.apply(
2885
+ that,
2886
+ args.concat(slice.call(arguments))
2887
+ );
2888
+
2889
+ }
2890
+
2891
+ };
2892
+ if(target.prototype) {
2893
+ Empty.prototype = target.prototype;
2894
+ bound.prototype = new Empty();
2895
+ Empty.prototype = null;
2896
+ }
2897
+ return bound;
2898
+ };
2899
+ }
2900
+ var call = Function.prototype.call;
2901
+ var prototypeOfArray = Array.prototype;
2902
+ var prototypeOfObject = Object.prototype;
2903
+ var slice = prototypeOfArray.slice;
2904
+ var _toString = call.bind(prototypeOfObject.toString);
2905
+ var owns = call.bind(prototypeOfObject.hasOwnProperty);
2906
+ var defineGetter;
2907
+ var defineSetter;
2908
+ var lookupGetter;
2909
+ var lookupSetter;
2910
+ var supportsAccessors;
2911
+ if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
2912
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
2913
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
2914
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
2915
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
2916
+ }
2917
+ if ([1,2].splice(0).length != 2) {
2918
+ if(function() { // test IE < 9 to splice bug - see issue #138
2919
+ function makeArray(l) {
2920
+ var a = new Array(l+2);
2921
+ a[0] = a[1] = 0;
2922
+ return a;
2923
+ }
2924
+ var array = [], lengthBefore;
2925
+
2926
+ array.splice.apply(array, makeArray(20));
2927
+ array.splice.apply(array, makeArray(26));
2928
+
2929
+ lengthBefore = array.length; //46
2930
+ array.splice(5, 0, "XXX"); // add one element
2931
+
2932
+ lengthBefore + 1 == array.length
2933
+
2934
+ if (lengthBefore + 1 == array.length) {
2935
+ return true;// has right splice implementation without bugs
2936
+ }
2937
+ }()) {//IE 6/7
2938
+ var array_splice = Array.prototype.splice;
2939
+ Array.prototype.splice = function(start, deleteCount) {
2940
+ if (!arguments.length) {
2941
+ return [];
2942
+ } else {
2943
+ return array_splice.apply(this, [
2944
+ start === void 0 ? 0 : start,
2945
+ deleteCount === void 0 ? (this.length - start) : deleteCount
2946
+ ].concat(slice.call(arguments, 2)))
2947
+ }
2948
+ };
2949
+ } else {//IE8
2950
+ Array.prototype.splice = function(pos, removeCount){
2951
+ var length = this.length;
2952
+ if (pos > 0) {
2953
+ if (pos > length)
2954
+ pos = length;
2955
+ } else if (pos == void 0) {
2956
+ pos = 0;
2957
+ } else if (pos < 0) {
2958
+ pos = Math.max(length + pos, 0);
2959
+ }
2960
+
2961
+ if (!(pos+removeCount < length))
2962
+ removeCount = length - pos;
2963
+
2964
+ var removed = this.slice(pos, pos+removeCount);
2965
+ var insert = slice.call(arguments, 2);
2966
+ var add = insert.length;
2967
+ if (pos === length) {
2968
+ if (add) {
2969
+ this.push.apply(this, insert);
2970
+ }
2971
+ } else {
2972
+ var remove = Math.min(removeCount, length - pos);
2973
+ var tailOldPos = pos + remove;
2974
+ var tailNewPos = tailOldPos + add - remove;
2975
+ var tailCount = length - tailOldPos;
2976
+ var lengthAfterRemove = length - remove;
2977
+
2978
+ if (tailNewPos < tailOldPos) { // case A
2979
+ for (var i = 0; i < tailCount; ++i) {
2980
+ this[tailNewPos+i] = this[tailOldPos+i];
2981
+ }
2982
+ } else if (tailNewPos > tailOldPos) { // case B
2983
+ for (i = tailCount; i--; ) {
2984
+ this[tailNewPos+i] = this[tailOldPos+i];
2985
+ }
2986
+ } // else, add == remove (nothing to do)
2987
+
2988
+ if (add && pos === lengthAfterRemove) {
2989
+ this.length = lengthAfterRemove; // truncate array
2990
+ this.push.apply(this, insert);
2991
+ } else {
2992
+ this.length = lengthAfterRemove + add; // reserves space
2993
+ for (i = 0; i < add; ++i) {
2994
+ this[pos+i] = insert[i];
2995
+ }
2996
+ }
2997
+ }
2998
+ return removed;
2999
+ };
3000
+ }
3001
+ }
3002
+ if (!Array.isArray) {
3003
+ Array.isArray = function isArray(obj) {
3004
+ return _toString(obj) == "[object Array]";
3005
+ };
3006
+ }
3007
+ var boxedString = Object("a"),
3008
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
3009
+
3010
+ if (!Array.prototype.forEach) {
3011
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
3012
+ var object = toObject(this),
3013
+ self = splitString && _toString(this) == "[object String]" ?
3014
+ this.split("") :
3015
+ object,
3016
+ thisp = arguments[1],
3017
+ i = -1,
3018
+ length = self.length >>> 0;
3019
+ if (_toString(fun) != "[object Function]") {
3020
+ throw new TypeError(); // TODO message
3021
+ }
3022
+
3023
+ while (++i < length) {
3024
+ if (i in self) {
3025
+ fun.call(thisp, self[i], i, object);
3026
+ }
3027
+ }
3028
+ };
3029
+ }
3030
+ if (!Array.prototype.map) {
3031
+ Array.prototype.map = function map(fun /*, thisp*/) {
3032
+ var object = toObject(this),
3033
+ self = splitString && _toString(this) == "[object String]" ?
3034
+ this.split("") :
3035
+ object,
3036
+ length = self.length >>> 0,
3037
+ result = Array(length),
3038
+ thisp = arguments[1];
3039
+ if (_toString(fun) != "[object Function]") {
3040
+ throw new TypeError(fun + " is not a function");
3041
+ }
3042
+
3043
+ for (var i = 0; i < length; i++) {
3044
+ if (i in self)
3045
+ result[i] = fun.call(thisp, self[i], i, object);
3046
+ }
3047
+ return result;
3048
+ };
3049
+ }
3050
+ if (!Array.prototype.filter) {
3051
+ Array.prototype.filter = function filter(fun /*, thisp */) {
3052
+ var object = toObject(this),
3053
+ self = splitString && _toString(this) == "[object String]" ?
3054
+ this.split("") :
3055
+ object,
3056
+ length = self.length >>> 0,
3057
+ result = [],
3058
+ value,
3059
+ thisp = arguments[1];
3060
+ if (_toString(fun) != "[object Function]") {
3061
+ throw new TypeError(fun + " is not a function");
3062
+ }
3063
+
3064
+ for (var i = 0; i < length; i++) {
3065
+ if (i in self) {
3066
+ value = self[i];
3067
+ if (fun.call(thisp, value, i, object)) {
3068
+ result.push(value);
3069
+ }
3070
+ }
3071
+ }
3072
+ return result;
3073
+ };
3074
+ }
3075
+ if (!Array.prototype.every) {
3076
+ Array.prototype.every = function every(fun /*, thisp */) {
3077
+ var object = toObject(this),
3078
+ self = splitString && _toString(this) == "[object String]" ?
3079
+ this.split("") :
3080
+ object,
3081
+ length = self.length >>> 0,
3082
+ thisp = arguments[1];
3083
+ if (_toString(fun) != "[object Function]") {
3084
+ throw new TypeError(fun + " is not a function");
3085
+ }
3086
+
3087
+ for (var i = 0; i < length; i++) {
3088
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
3089
+ return false;
3090
+ }
3091
+ }
3092
+ return true;
3093
+ };
3094
+ }
3095
+ if (!Array.prototype.some) {
3096
+ Array.prototype.some = function some(fun /*, thisp */) {
3097
+ var object = toObject(this),
3098
+ self = splitString && _toString(this) == "[object String]" ?
3099
+ this.split("") :
3100
+ object,
3101
+ length = self.length >>> 0,
3102
+ thisp = arguments[1];
3103
+ if (_toString(fun) != "[object Function]") {
3104
+ throw new TypeError(fun + " is not a function");
3105
+ }
3106
+
3107
+ for (var i = 0; i < length; i++) {
3108
+ if (i in self && fun.call(thisp, self[i], i, object)) {
3109
+ return true;
3110
+ }
3111
+ }
3112
+ return false;
3113
+ };
3114
+ }
3115
+ if (!Array.prototype.reduce) {
3116
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
3117
+ var object = toObject(this),
3118
+ self = splitString && _toString(this) == "[object String]" ?
3119
+ this.split("") :
3120
+ object,
3121
+ length = self.length >>> 0;
3122
+ if (_toString(fun) != "[object Function]") {
3123
+ throw new TypeError(fun + " is not a function");
3124
+ }
3125
+ if (!length && arguments.length == 1) {
3126
+ throw new TypeError("reduce of empty array with no initial value");
3127
+ }
3128
+
3129
+ var i = 0;
3130
+ var result;
3131
+ if (arguments.length >= 2) {
3132
+ result = arguments[1];
3133
+ } else {
3134
+ do {
3135
+ if (i in self) {
3136
+ result = self[i++];
3137
+ break;
3138
+ }
3139
+ if (++i >= length) {
3140
+ throw new TypeError("reduce of empty array with no initial value");
3141
+ }
3142
+ } while (true);
3143
+ }
3144
+
3145
+ for (; i < length; i++) {
3146
+ if (i in self) {
3147
+ result = fun.call(void 0, result, self[i], i, object);
3148
+ }
3149
+ }
3150
+
3151
+ return result;
3152
+ };
3153
+ }
3154
+ if (!Array.prototype.reduceRight) {
3155
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
3156
+ var object = toObject(this),
3157
+ self = splitString && _toString(this) == "[object String]" ?
3158
+ this.split("") :
3159
+ object,
3160
+ length = self.length >>> 0;
3161
+ if (_toString(fun) != "[object Function]") {
3162
+ throw new TypeError(fun + " is not a function");
3163
+ }
3164
+ if (!length && arguments.length == 1) {
3165
+ throw new TypeError("reduceRight of empty array with no initial value");
3166
+ }
3167
+
3168
+ var result, i = length - 1;
3169
+ if (arguments.length >= 2) {
3170
+ result = arguments[1];
3171
+ } else {
3172
+ do {
3173
+ if (i in self) {
3174
+ result = self[i--];
3175
+ break;
3176
+ }
3177
+ if (--i < 0) {
3178
+ throw new TypeError("reduceRight of empty array with no initial value");
3179
+ }
3180
+ } while (true);
3181
+ }
3182
+
3183
+ do {
3184
+ if (i in this) {
3185
+ result = fun.call(void 0, result, self[i], i, object);
3186
+ }
3187
+ } while (i--);
3188
+
3189
+ return result;
3190
+ };
3191
+ }
3192
+ if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
3193
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
3194
+ var self = splitString && _toString(this) == "[object String]" ?
3195
+ this.split("") :
3196
+ toObject(this),
3197
+ length = self.length >>> 0;
3198
+
3199
+ if (!length) {
3200
+ return -1;
3201
+ }
3202
+
3203
+ var i = 0;
3204
+ if (arguments.length > 1) {
3205
+ i = toInteger(arguments[1]);
3206
+ }
3207
+ i = i >= 0 ? i : Math.max(0, length + i);
3208
+ for (; i < length; i++) {
3209
+ if (i in self && self[i] === sought) {
3210
+ return i;
3211
+ }
3212
+ }
3213
+ return -1;
3214
+ };
3215
+ }
3216
+ if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
3217
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
3218
+ var self = splitString && _toString(this) == "[object String]" ?
3219
+ this.split("") :
3220
+ toObject(this),
3221
+ length = self.length >>> 0;
3222
+
3223
+ if (!length) {
3224
+ return -1;
3225
+ }
3226
+ var i = length - 1;
3227
+ if (arguments.length > 1) {
3228
+ i = Math.min(i, toInteger(arguments[1]));
3229
+ }
3230
+ i = i >= 0 ? i : length - Math.abs(i);
3231
+ for (; i >= 0; i--) {
3232
+ if (i in self && sought === self[i]) {
3233
+ return i;
3234
+ }
3235
+ }
3236
+ return -1;
3237
+ };
3238
+ }
3239
+ if (!Object.getPrototypeOf) {
3240
+ Object.getPrototypeOf = function getPrototypeOf(object) {
3241
+ return object.__proto__ || (
3242
+ object.constructor ?
3243
+ object.constructor.prototype :
3244
+ prototypeOfObject
3245
+ );
3246
+ };
3247
+ }
3248
+ if (!Object.getOwnPropertyDescriptor) {
3249
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
3250
+ "non-object: ";
3251
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
3252
+ if ((typeof object != "object" && typeof object != "function") || object === null)
3253
+ throw new TypeError(ERR_NON_OBJECT + object);
3254
+ if (!owns(object, property))
3255
+ return;
3256
+
3257
+ var descriptor, getter, setter;
3258
+ descriptor = { enumerable: true, configurable: true };
3259
+ if (supportsAccessors) {
3260
+ var prototype = object.__proto__;
3261
+ object.__proto__ = prototypeOfObject;
3262
+
3263
+ var getter = lookupGetter(object, property);
3264
+ var setter = lookupSetter(object, property);
3265
+ object.__proto__ = prototype;
3266
+
3267
+ if (getter || setter) {
3268
+ if (getter) descriptor.get = getter;
3269
+ if (setter) descriptor.set = setter;
3270
+ return descriptor;
3271
+ }
3272
+ }
3273
+ descriptor.value = object[property];
3274
+ return descriptor;
3275
+ };
3276
+ }
3277
+ if (!Object.getOwnPropertyNames) {
3278
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
3279
+ return Object.keys(object);
3280
+ };
3281
+ }
3282
+ if (!Object.create) {
3283
+ var createEmpty;
3284
+ if (Object.prototype.__proto__ === null) {
3285
+ createEmpty = function () {
3286
+ return { "__proto__": null };
3287
+ };
3288
+ } else {
3289
+ createEmpty = function () {
3290
+ var empty = {};
3291
+ for (var i in empty)
3292
+ empty[i] = null;
3293
+ empty.constructor =
3294
+ empty.hasOwnProperty =
3295
+ empty.propertyIsEnumerable =
3296
+ empty.isPrototypeOf =
3297
+ empty.toLocaleString =
3298
+ empty.toString =
3299
+ empty.valueOf =
3300
+ empty.__proto__ = null;
3301
+ return empty;
3302
+ }
3303
+ }
3304
+
3305
+ Object.create = function create(prototype, properties) {
3306
+ var object;
3307
+ if (prototype === null) {
3308
+ object = createEmpty();
3309
+ } else {
3310
+ if (typeof prototype != "object")
3311
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
3312
+ var Type = function () {};
3313
+ Type.prototype = prototype;
3314
+ object = new Type();
3315
+ object.__proto__ = prototype;
3316
+ }
3317
+ if (properties !== void 0)
3318
+ Object.defineProperties(object, properties);
3319
+ return object;
3320
+ };
3321
+ }
3322
+
3323
+ function doesDefinePropertyWork(object) {
3324
+ try {
3325
+ Object.defineProperty(object, "sentinel", {});
3326
+ return "sentinel" in object;
3327
+ } catch (exception) {
3328
+ }
3329
+ }
3330
+ if (Object.defineProperty) {
3331
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
3332
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
3333
+ doesDefinePropertyWork(document.createElement("div"));
3334
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
3335
+ var definePropertyFallback = Object.defineProperty;
3336
+ }
3337
+ }
3338
+
3339
+ if (!Object.defineProperty || definePropertyFallback) {
3340
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
3341
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
3342
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
3343
+ "on this javascript engine";
3344
+
3345
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
3346
+ if ((typeof object != "object" && typeof object != "function") || object === null)
3347
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
3348
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
3349
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
3350
+ if (definePropertyFallback) {
3351
+ try {
3352
+ return definePropertyFallback.call(Object, object, property, descriptor);
3353
+ } catch (exception) {
3354
+ }
3355
+ }
3356
+ if (owns(descriptor, "value")) {
3357
+
3358
+ if (supportsAccessors && (lookupGetter(object, property) ||
3359
+ lookupSetter(object, property)))
3360
+ {
3361
+ var prototype = object.__proto__;
3362
+ object.__proto__ = prototypeOfObject;
3363
+ delete object[property];
3364
+ object[property] = descriptor.value;
3365
+ object.__proto__ = prototype;
3366
+ } else {
3367
+ object[property] = descriptor.value;
3368
+ }
3369
+ } else {
3370
+ if (!supportsAccessors)
3371
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
3372
+ if (owns(descriptor, "get"))
3373
+ defineGetter(object, property, descriptor.get);
3374
+ if (owns(descriptor, "set"))
3375
+ defineSetter(object, property, descriptor.set);
3376
+ }
3377
+
3378
+ return object;
3379
+ };
3380
+ }
3381
+ if (!Object.defineProperties) {
3382
+ Object.defineProperties = function defineProperties(object, properties) {
3383
+ for (var property in properties) {
3384
+ if (owns(properties, property))
3385
+ Object.defineProperty(object, property, properties[property]);
3386
+ }
3387
+ return object;
3388
+ };
3389
+ }
3390
+ if (!Object.seal) {
3391
+ Object.seal = function seal(object) {
3392
+ return object;
3393
+ };
3394
+ }
3395
+ if (!Object.freeze) {
3396
+ Object.freeze = function freeze(object) {
3397
+ return object;
3398
+ };
3399
+ }
3400
+ try {
3401
+ Object.freeze(function () {});
3402
+ } catch (exception) {
3403
+ Object.freeze = (function freeze(freezeObject) {
3404
+ return function freeze(object) {
3405
+ if (typeof object == "function") {
3406
+ return object;
3407
+ } else {
3408
+ return freezeObject(object);
3409
+ }
3410
+ };
3411
+ })(Object.freeze);
3412
+ }
3413
+ if (!Object.preventExtensions) {
3414
+ Object.preventExtensions = function preventExtensions(object) {
3415
+ return object;
3416
+ };
3417
+ }
3418
+ if (!Object.isSealed) {
3419
+ Object.isSealed = function isSealed(object) {
3420
+ return false;
3421
+ };
3422
+ }
3423
+ if (!Object.isFrozen) {
3424
+ Object.isFrozen = function isFrozen(object) {
3425
+ return false;
3426
+ };
3427
+ }
3428
+ if (!Object.isExtensible) {
3429
+ Object.isExtensible = function isExtensible(object) {
3430
+ if (Object(object) === object) {
3431
+ throw new TypeError(); // TODO message
3432
+ }
3433
+ var name = '';
3434
+ while (owns(object, name)) {
3435
+ name += '?';
3436
+ }
3437
+ object[name] = true;
3438
+ var returnValue = owns(object, name);
3439
+ delete object[name];
3440
+ return returnValue;
3441
+ };
3442
+ }
3443
+ if (!Object.keys) {
3444
+ var hasDontEnumBug = true,
3445
+ dontEnums = [
3446
+ "toString",
3447
+ "toLocaleString",
3448
+ "valueOf",
3449
+ "hasOwnProperty",
3450
+ "isPrototypeOf",
3451
+ "propertyIsEnumerable",
3452
+ "constructor"
3453
+ ],
3454
+ dontEnumsLength = dontEnums.length;
3455
+
3456
+ for (var key in {"toString": null}) {
3457
+ hasDontEnumBug = false;
3458
+ }
3459
+
3460
+ Object.keys = function keys(object) {
3461
+
3462
+ if (
3463
+ (typeof object != "object" && typeof object != "function") ||
3464
+ object === null
3465
+ ) {
3466
+ throw new TypeError("Object.keys called on a non-object");
3467
+ }
3468
+
3469
+ var keys = [];
3470
+ for (var name in object) {
3471
+ if (owns(object, name)) {
3472
+ keys.push(name);
3473
+ }
3474
+ }
3475
+
3476
+ if (hasDontEnumBug) {
3477
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
3478
+ var dontEnum = dontEnums[i];
3479
+ if (owns(object, dontEnum)) {
3480
+ keys.push(dontEnum);
3481
+ }
3482
+ }
3483
+ }
3484
+ return keys;
3485
+ };
3486
+
3487
+ }
3488
+ if (!Date.now) {
3489
+ Date.now = function now() {
3490
+ return new Date().getTime();
3491
+ };
3492
+ }
3493
+ var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
3494
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
3495
+ "\u2029\uFEFF";
3496
+ if (!String.prototype.trim || ws.trim()) {
3497
+ ws = "[" + ws + "]";
3498
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
3499
+ trimEndRegexp = new RegExp(ws + ws + "*$");
3500
+ String.prototype.trim = function trim() {
3501
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
3502
+ };
3503
+ }
3504
+
3505
+ function toInteger(n) {
3506
+ n = +n;
3507
+ if (n !== n) { // isNaN
3508
+ n = 0;
3509
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
3510
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
3511
+ }
3512
+ return n;
3513
+ }
3514
+
3515
+ function isPrimitive(input) {
3516
+ var type = typeof input;
3517
+ return (
3518
+ input === null ||
3519
+ type === "undefined" ||
3520
+ type === "boolean" ||
3521
+ type === "number" ||
3522
+ type === "string"
3523
+ );
3524
+ }
3525
+
3526
+ function toPrimitive(input) {
3527
+ var val, valueOf, toString;
3528
+ if (isPrimitive(input)) {
3529
+ return input;
3530
+ }
3531
+ valueOf = input.valueOf;
3532
+ if (typeof valueOf === "function") {
3533
+ val = valueOf.call(input);
3534
+ if (isPrimitive(val)) {
3535
+ return val;
3536
+ }
3537
+ }
3538
+ toString = input.toString;
3539
+ if (typeof toString === "function") {
3540
+ val = toString.call(input);
3541
+ if (isPrimitive(val)) {
3542
+ return val;
3543
+ }
3544
+ }
3545
+ throw new TypeError();
3546
+ }
3547
+ var toObject = function (o) {
3548
+ if (o == null) { // this matches both null and undefined
3549
+ throw new TypeError("can't convert "+o+" to object");
3550
+ }
3551
+ return Object(o);
3552
+ };
3553
+
3554
+ });