iqvoc 3.2.11 → 3.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (351) hide show
  1. data/Gemfile +9 -9
  2. data/Gemfile.lock +108 -101
  3. data/{public/images/iqvoc → app/assets/images}/arrow_down.gif +0 -0
  4. data/{public/images/iqvoc → app/assets/images}/arrow_up.gif +0 -0
  5. data/{public/stylesheets/iqvoc → app/assets}/images/back.png +0 -0
  6. data/{public/stylesheets/iqvoc → app/assets}/images/branch.png +0 -0
  7. data/{public/stylesheets/iqvoc → app/assets}/images/categ.png +0 -0
  8. data/{public/stylesheets/iqvoc → app/assets}/images/categ_open.png +0 -0
  9. data/{public/images/iqvoc → app/assets/images}/footer.png +0 -0
  10. data/{public/stylesheets/iqvoc → app/assets}/images/go_there.png +0 -0
  11. data/{public/images/iqvoc → app/assets/images}/header_long.png +0 -0
  12. data/{public/stylesheets/iqvoc → app/assets}/images/iqvoc.png +0 -0
  13. data/{public/stylesheets/iqvoc → app/assets}/images/leaf_end.png +0 -0
  14. data/{public/stylesheets/iqvoc → app/assets}/images/leaf_end_filled.png +0 -0
  15. data/{public/stylesheets/iqvoc → app/assets}/images/leaf_mid.png +0 -0
  16. data/{public/stylesheets/iqvoc → app/assets}/images/leaf_mid_filled.png +0 -0
  17. data/{public/stylesheets/iqvoc → app/assets}/images/leaf_nothing.png +0 -0
  18. data/{public/stylesheets/iqvoc → app/assets}/images/leaf_only.png +0 -0
  19. data/{public/stylesheets/iqvoc → app/assets}/images/leaf_only_filled.png +0 -0
  20. data/{public/stylesheets/iqvoc → app/assets}/images/leaf_top.png +0 -0
  21. data/{public/stylesheets/iqvoc → app/assets}/images/leaf_top_filled.png +0 -0
  22. data/{public/stylesheets/iqvoc → app/assets}/images/nothing.png +0 -0
  23. data/{public/images/iqvoc → app/assets/images}/ok.png +0 -0
  24. data/{public/images/iqvoc → app/assets/images}/rdf_flyer.gif +0 -0
  25. data/{public/images/iqvoc → app/assets/images}/red_arrow.png +0 -0
  26. data/{public/images/iqvoc → app/assets/images}/shadow.png +0 -0
  27. data/{public/images/iqvoc → app/assets/images}/spinner.gif +0 -0
  28. data/{public/images/iqvoc → app/assets/images}/tokenizer_delete.png +0 -0
  29. data/{public/images/iqvoc → app/assets/images}/tokenizer_pencile.png +0 -0
  30. data/{public/images/iqvoc → app/assets/images}/tokenizer_show.png +0 -0
  31. data/{public/stylesheets/iqvoc → app/assets}/images/top_01.png +0 -0
  32. data/{public/stylesheets/iqvoc → app/assets}/images/trunk.png +0 -0
  33. data/{public/images/iqvoc → app/assets/images}/unfinished.png +0 -0
  34. data/app/assets/javascripts/framework.js +7 -0
  35. data/{public/javascripts/iqvoc/entityselect.js → app/assets/javascripts/iqvoc/entityselect.js.erb} +1 -1
  36. data/{public/javascripts/iqvoc/application.js → app/assets/javascripts/iqvoc/iqvoc.js} +118 -1
  37. data/{public → app/assets}/javascripts/iqvoc/langselect.js +0 -0
  38. data/app/assets/javascripts/iqvoc/manifest.js +3 -0
  39. data/{public → app/assets}/javascripts/iqvoc/visualization.js +0 -0
  40. data/app/assets/javascripts/manifest.js +2 -0
  41. data/app/assets/stylesheets/framework.css +4 -0
  42. data/{public/stylesheets/iqvoc/forms.css → app/assets/stylesheets/iqvoc/forms.css.erb} +1 -1
  43. data/app/assets/stylesheets/iqvoc/ie_fixes.css +6 -0
  44. data/{public/stylesheets/iqvoc/iqvoc.css → app/assets/stylesheets/iqvoc/iqvoc.css.erb} +3 -3
  45. data/app/assets/stylesheets/iqvoc/manifest.css +5 -0
  46. data/{public → app/assets}/stylesheets/iqvoc/widgets.css +0 -0
  47. data/app/assets/stylesheets/manifest.css +4 -0
  48. data/app/controllers/collections_controller.rb +10 -4
  49. data/app/controllers/concepts/alphabetical_controller.rb +1 -2
  50. data/app/controllers/concepts/hierarchical_controller.rb +1 -1
  51. data/app/controllers/concepts_controller.rb +7 -6
  52. data/app/helpers/concepts_helper.rb +0 -1
  53. data/app/helpers/dashboard_helper.rb +2 -2
  54. data/app/models/concept/base.rb +6 -7
  55. data/app/models/concept/relation/base.rb +1 -1
  56. data/app/models/labeling/base.rb +1 -1
  57. data/app/models/labeling/skos/base.rb +5 -10
  58. data/app/models/match/base.rb +1 -1
  59. data/app/models/note/base.rb +1 -1
  60. data/app/models/user.rb +1 -0
  61. data/app/views/concepts/_visualization.html.erb +2 -2
  62. data/app/views/concepts/index.iqrdf +6 -2
  63. data/app/views/layouts/application.html.erb +7 -27
  64. data/app/views/partials/_rdf_logo.html.erb +1 -2
  65. data/config/application.rb +12 -3
  66. data/config/database.yml +21 -13
  67. data/config/engine.rb +6 -5
  68. data/config/environments/development.rb +45 -37
  69. data/config/environments/production.rb +45 -34
  70. data/config/environments/test.rb +43 -34
  71. data/config/initializers/iqvoc.rb +4 -8
  72. data/config/initializers/secret_token.rb +30 -0
  73. data/config/initializers/session_store.rb +1 -1
  74. data/config/locales/activerecord.de.yml +85 -111
  75. data/config/locales/activerecord.en.yml +85 -111
  76. data/db/iqvoc_test.sqlite3 +0 -0
  77. data/db/schema.rb +67 -153
  78. data/iqvoc.gemspec +3 -1
  79. data/lib/iqvoc/deep_cloning.rb +5 -5
  80. data/lib/iqvoc/version.rb +1 -1
  81. data/lib/iqvoc/versioning.rb +1 -1
  82. data/lib/iqvoc.rb +0 -6
  83. metadata +103 -369
  84. checksums.yaml +0 -7
  85. data/public/export/104047454295817920610168807659129435311.nt +0 -28
  86. data/public/export/10726.nt +0 -28
  87. data/public/export/10751365034669120987598940220863369604.nt +0 -28
  88. data/public/export/111691466774189666307584118743393932328.nt +0 -28
  89. data/public/export/12325399400132639231204595208154762660.nt +0 -28
  90. data/public/export/15263706163704853684442315777380853572.nt +0 -28
  91. data/public/export/15327.nt +0 -28
  92. data/public/export/15666.nt +0 -28
  93. data/public/export/173626129450223321263719262149444213847.nt +0 -28
  94. data/public/export/18948.nt +0 -28
  95. data/public/export/199578749544886032300136278910417855540.nt +0 -28
  96. data/public/export/213890660005255527251394676521741138403.nt +0 -28
  97. data/public/export/21930.nt +0 -28
  98. data/public/export/24509.nt +0 -28
  99. data/public/export/249458227092013520089223290936103182178.nt +0 -28
  100. data/public/export/271163890329327117562409702966294853312.nt +0 -28
  101. data/public/export/27484.nt +0 -28
  102. data/public/export/287251617830426667971006908766107175810.nt +0 -28
  103. data/public/export/28754.nt +0 -28
  104. data/public/export/29022.nt +0 -28
  105. data/public/export/293720064238755056739270868818770835353.nt +0 -28
  106. data/public/export/29976.nt +0 -28
  107. data/public/export/30643.nt +0 -28
  108. data/public/export/309135899928267675232062298368405782595.nt +0 -28
  109. data/public/export/32054.nt +0 -28
  110. data/public/export/327890543532187929176278243423558506722.nt +0 -28
  111. data/public/export/33055.nt +0 -28
  112. data/public/export/337748600310244218106909976567220577473.nt +0 -28
  113. data/public/export/33936.nt +0 -28
  114. data/public/export/33993.nt +0 -28
  115. data/public/export/34906.nt +0 -28
  116. data/public/export/35365.nt +0 -28
  117. data/public/export/37098.nt +0 -28
  118. data/public/export/37534146541112437090211766955764945845.nt +0 -28
  119. data/public/export/39353594202090916952403280275602550330.nt +0 -28
  120. data/public/export/41272.nt +0 -28
  121. data/public/export/42271.nt +0 -28
  122. data/public/export/44392.nt +0 -28
  123. data/public/export/45675.nt +0 -28
  124. data/public/export/47529.nt +0 -28
  125. data/public/export/48309.nt +0 -28
  126. data/public/export/4956.nt +0 -28
  127. data/public/export/49623.nt +0 -28
  128. data/public/export/50516.nt +0 -28
  129. data/public/export/54880.nt +0 -28
  130. data/public/export/55142.nt +0 -28
  131. data/public/export/55398.nt +0 -28
  132. data/public/export/5754.nt +0 -28
  133. data/public/export/57727.nt +0 -28
  134. data/public/export/58069939020968861674794480549301466954.nt +0 -28
  135. data/public/export/5890.nt +0 -28
  136. data/public/export/62809.nt +0 -28
  137. data/public/export/65156.nt +0 -28
  138. data/public/export/6520.nt +0 -28
  139. data/public/export/863.nt +0 -28
  140. data/public/export/9372.nt +0 -28
  141. data/public/javascripts/iqvoc/excanvas.js +0 -35
  142. data/public/javascripts/iqvoc/iqvoc.js +0 -118
  143. data/public/javascripts/iqvoc/jit_rgraph.js +0 -153
  144. data/public/javascripts/iqvoc/jquery-1.6.2.min.js +0 -18
  145. data/public/javascripts/iqvoc/jquery-treeview/changelog.txt +0 -29
  146. data/public/javascripts/iqvoc/jquery-treeview/demo/async.html +0 -44
  147. data/public/javascripts/iqvoc/jquery-treeview/demo/bg.gif +0 -0
  148. data/public/javascripts/iqvoc/jquery-treeview/demo/demo.js +0 -43
  149. data/public/javascripts/iqvoc/jquery-treeview/demo/images.html +0 -56
  150. data/public/javascripts/iqvoc/jquery-treeview/demo/index.html +0 -340
  151. data/public/javascripts/iqvoc/jquery-treeview/demo/large.html +0 -559
  152. data/public/javascripts/iqvoc/jquery-treeview/demo/prerendered.html +0 -621
  153. data/public/javascripts/iqvoc/jquery-treeview/demo/screen.css +0 -24
  154. data/public/javascripts/iqvoc/jquery-treeview/demo/simple.html +0 -82
  155. data/public/javascripts/iqvoc/jquery-treeview/demo/source.php +0 -87
  156. data/public/javascripts/iqvoc/jquery-treeview/demo/source.phps +0 -87
  157. data/public/javascripts/iqvoc/jquery-treeview/images/ajax-loader.gif +0 -0
  158. data/public/javascripts/iqvoc/jquery-treeview/images/file.gif +0 -0
  159. data/public/javascripts/iqvoc/jquery-treeview/images/folder-closed.gif +0 -0
  160. data/public/javascripts/iqvoc/jquery-treeview/images/folder.gif +0 -0
  161. data/public/javascripts/iqvoc/jquery-treeview/images/minus.gif +0 -0
  162. data/public/javascripts/iqvoc/jquery-treeview/images/plus.gif +0 -0
  163. data/public/javascripts/iqvoc/jquery-treeview/images/treeview-black-line.gif +0 -0
  164. data/public/javascripts/iqvoc/jquery-treeview/images/treeview-black.gif +0 -0
  165. data/public/javascripts/iqvoc/jquery-treeview/images/treeview-default-line.gif +0 -0
  166. data/public/javascripts/iqvoc/jquery-treeview/images/treeview-default.gif +0 -0
  167. data/public/javascripts/iqvoc/jquery-treeview/images/treeview-famfamfam-line.gif +0 -0
  168. data/public/javascripts/iqvoc/jquery-treeview/images/treeview-famfamfam.gif +0 -0
  169. data/public/javascripts/iqvoc/jquery-treeview/images/treeview-gray-line.gif +0 -0
  170. data/public/javascripts/iqvoc/jquery-treeview/images/treeview-gray.gif +0 -0
  171. data/public/javascripts/iqvoc/jquery-treeview/images/treeview-red-line.gif +0 -0
  172. data/public/javascripts/iqvoc/jquery-treeview/images/treeview-red.gif +0 -0
  173. data/public/javascripts/iqvoc/jquery-treeview/jquery.treeview.async.js +0 -82
  174. data/public/javascripts/iqvoc/jquery-treeview/jquery.treeview.css +0 -75
  175. data/public/javascripts/iqvoc/jquery-treeview/jquery.treeview.js +0 -251
  176. data/public/javascripts/iqvoc/jquery-treeview/jquery.treeview.min.js +0 -15
  177. data/public/javascripts/iqvoc/jquery-treeview/jquery.treeview.pack.js +0 -16
  178. data/public/javascripts/iqvoc/jquery-treeview/lib/jquery.cookie.js +0 -92
  179. data/public/javascripts/iqvoc/jquery-treeview/lib/jquery.js +0 -3363
  180. data/public/javascripts/iqvoc/jquery-treeview/todo +0 -8
  181. data/public/javascripts/iqvoc/jquery-ui-1.8.16.custom.js +0 -3269
  182. data/public/javascripts/iqvoc/jquery-ui-1.8.16.custom.min.js +0 -165
  183. data/public/javascripts/iqvoc/jquery-ui.datepicker-de.js +0 -22
  184. data/public/javascripts/iqvoc/json2.js +0 -480
  185. data/public/javascripts/iqvoc/rails.js +0 -132
  186. data/public/javascripts/iqvoc/storage.js +0 -122
  187. data/public/stylesheets/iqvoc/blueprint/ie.css +0 -35
  188. data/public/stylesheets/iqvoc/blueprint/plugins/buttons/icons/cross.png +0 -0
  189. data/public/stylesheets/iqvoc/blueprint/plugins/buttons/icons/key.png +0 -0
  190. data/public/stylesheets/iqvoc/blueprint/plugins/buttons/icons/tick.png +0 -0
  191. data/public/stylesheets/iqvoc/blueprint/plugins/buttons/readme.txt +0 -32
  192. data/public/stylesheets/iqvoc/blueprint/plugins/buttons/screen.css +0 -97
  193. data/public/stylesheets/iqvoc/blueprint/plugins/fancy-type/readme.txt +0 -14
  194. data/public/stylesheets/iqvoc/blueprint/plugins/fancy-type/screen.css +0 -71
  195. data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/doc.png +0 -0
  196. data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/email.png +0 -0
  197. data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/external.png +0 -0
  198. data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/feed.png +0 -0
  199. data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/im.png +0 -0
  200. data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/pdf.png +0 -0
  201. data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/visited.png +0 -0
  202. data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/xls.png +0 -0
  203. data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/readme.txt +0 -18
  204. data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/screen.css +0 -40
  205. data/public/stylesheets/iqvoc/blueprint/plugins/rtl/readme.txt +0 -10
  206. data/public/stylesheets/iqvoc/blueprint/plugins/rtl/screen.css +0 -110
  207. data/public/stylesheets/iqvoc/blueprint/print.css +0 -29
  208. data/public/stylesheets/iqvoc/blueprint/screen.css +0 -258
  209. data/public/stylesheets/iqvoc/blueprint/src/forms.css +0 -65
  210. data/public/stylesheets/iqvoc/blueprint/src/grid.css +0 -280
  211. data/public/stylesheets/iqvoc/blueprint/src/grid.png +0 -0
  212. data/public/stylesheets/iqvoc/blueprint/src/ie.css +0 -76
  213. data/public/stylesheets/iqvoc/blueprint/src/print.css +0 -85
  214. data/public/stylesheets/iqvoc/blueprint/src/reset.css +0 -45
  215. data/public/stylesheets/iqvoc/blueprint/src/typography.css +0 -106
  216. data/public/stylesheets/iqvoc/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
  217. data/public/stylesheets/iqvoc/images/ui-bg_flat_55_fbec88_40x100.png +0 -0
  218. data/public/stylesheets/iqvoc/images/ui-bg_glass_75_d0e5f5_1x400.png +0 -0
  219. data/public/stylesheets/iqvoc/images/ui-bg_glass_85_dfeffc_1x400.png +0 -0
  220. data/public/stylesheets/iqvoc/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
  221. data/public/stylesheets/iqvoc/images/ui-bg_gloss-wave_55_5c9ccc_500x100.png +0 -0
  222. data/public/stylesheets/iqvoc/images/ui-bg_inset-hard_100_f5f8f9_1x100.png +0 -0
  223. data/public/stylesheets/iqvoc/images/ui-bg_inset-hard_100_fcfdfd_1x100.png +0 -0
  224. data/public/stylesheets/iqvoc/images/ui-icons_217bc0_256x240.png +0 -0
  225. data/public/stylesheets/iqvoc/images/ui-icons_2e83ff_256x240.png +0 -0
  226. data/public/stylesheets/iqvoc/images/ui-icons_469bdd_256x240.png +0 -0
  227. data/public/stylesheets/iqvoc/images/ui-icons_6da8d5_256x240.png +0 -0
  228. data/public/stylesheets/iqvoc/images/ui-icons_cd0a0a_256x240.png +0 -0
  229. data/public/stylesheets/iqvoc/images/ui-icons_d8e7f3_256x240.png +0 -0
  230. data/public/stylesheets/iqvoc/images/ui-icons_f9bd01_256x240.png +0 -0
  231. data/public/stylesheets/iqvoc/jquery-ui-1.8.16.custom.css +0 -410
  232. data/public/uploads/import/038dd516e01fe211375441c3af8d90e8.nt +0 -259
  233. data/public/uploads/import/07e71ca0235e798be39acd246114d962.nt +0 -259
  234. data/public/uploads/import/0a4c173bc9db7a5cd469c9454fdfa749.nt +0 -259
  235. data/public/uploads/import/0e8336cb2ef2c8b67767dfe8879d9cfb.nt +0 -259
  236. data/public/uploads/import/0f4eb8cd6390b1c5c5354a22e533ee0e.nt +0 -259
  237. data/public/uploads/import/105400714d68d2207209e23826345e76.nt +0 -259
  238. data/public/uploads/import/1147ab054ce55abf0a5bf93b99220231.nt +0 -259
  239. data/public/uploads/import/14b64b1f2252aba1e89d83f770d14e29.nt +0 -259
  240. data/public/uploads/import/1c6f11c300224248bf919885f8545daf.nt +0 -259
  241. data/public/uploads/import/21d34b65ef0a8156111e845992fd004f.nt +0 -259
  242. data/public/uploads/import/2783fade523132942999836a74228d64.nt +0 -259
  243. data/public/uploads/import/2bc90e07e5c42e5f26a1607756cc0ab3.nt +0 -259
  244. data/public/uploads/import/2e4073a94eeae98095de9f43b5e5774a.nt +0 -259
  245. data/public/uploads/import/32548678e7d47b3e256590d6eef6fb03.nt +0 -259
  246. data/public/uploads/import/330e08c32fde94fb80f656346d1f8383.nt +0 -259
  247. data/public/uploads/import/337790be2663214e66066b1215fdd137.nt +0 -259
  248. data/public/uploads/import/34b77ff970ca71511fb4b224b7dadd1c.nt +0 -259
  249. data/public/uploads/import/38de0d3c9cba92e8a3c312e7e95e7ec1.nt +0 -259
  250. data/public/uploads/import/3981aa91cf22e26fbf6b1312b2bcdcc8.nt +0 -259
  251. data/public/uploads/import/3d01f84539a62ebe6f76124e8cdbbb23.nt +0 -259
  252. data/public/uploads/import/3d05bb72c3751da3830cf53e966283d4.nt +0 -259
  253. data/public/uploads/import/3e1d2f770bfe3c79a367780731536a3a.nt +0 -259
  254. data/public/uploads/import/3e41bd1875dc23401278c73bd12be881.nt +0 -259
  255. data/public/uploads/import/3f3e3dbb09c3df6bfaed261311de3e7d.nt +0 -259
  256. data/public/uploads/import/4297d9970e47be5ced4991a083032eb9.nt +0 -259
  257. data/public/uploads/import/5925186958bd537ad5e79e76e3a1f714.nt +0 -259
  258. data/public/uploads/import/5dc5dcd978db1c59ec074e9137f0109c.nt +0 -259
  259. data/public/uploads/import/5e46663e7e2eb92e5e8846d7c0f8e713.nt +0 -259
  260. data/public/uploads/import/70022a2a7e808000dc3d55529d203480.nt +0 -259
  261. data/public/uploads/import/70b32583acaca5843ac7dbdc2a89de99.nt +0 -259
  262. data/public/uploads/import/8030e54313e2c7231c4c30cd4145d576.nt +0 -259
  263. data/public/uploads/import/8bb6484a9eb0c3266274c08ad8500669.nt +0 -259
  264. data/public/uploads/import/90711ea002f6b7b4e5476e414e185603.nt +0 -259
  265. data/public/uploads/import/918a5fc2c8fcdbaddc2a02588d599dcf.nt +0 -259
  266. data/public/uploads/import/923f9ebccb7b0e9e9fafddc60750b989.nt +0 -259
  267. data/public/uploads/import/933e4e2baee4d91b8f7681fa4d2ad9fa.nt +0 -259
  268. data/public/uploads/import/93f642eacd966c98645345d2ccdf578d.nt +0 -259
  269. data/public/uploads/import/9a3d0f8d1872d4ba5dd281194ddea4a2.nt +0 -259
  270. data/public/uploads/import/9a3f1c9de8e734b7e1d969d07ea57a83.nt +0 -259
  271. data/public/uploads/import/9f91263fee5275ecbf303c7da0a9e84d.nt +0 -259
  272. data/public/uploads/import/9f9d6b4293be8def1b406156a3e2bcd9.nt +0 -259
  273. data/public/uploads/import/a230b36c3666a6b16fec6283e99b221f.nt +0 -259
  274. data/public/uploads/import/a51b35089dc096f0f1f5d5250edb8d5c.nt +0 -259
  275. data/public/uploads/import/a5265a00946627588ecdac317c061c6c.nt +0 -259
  276. data/public/uploads/import/a95b7d93b7483116ff13c894a46b5c1c.nt +0 -259
  277. data/public/uploads/import/b5e47ea582afb81341f7b7084cc17a06.nt +0 -259
  278. data/public/uploads/import/b826bcfad8f18294a425d65482c46033.nt +0 -259
  279. data/public/uploads/import/bcf18c9e4dbe72745f4ec2878a4b1690.nt +0 -259
  280. data/public/uploads/import/c32855cb4b3e8616db2ef3f5f9cb5ca7.nt +0 -259
  281. data/public/uploads/import/c8ee5bc696312468c4354bad6c583321.nt +0 -259
  282. data/public/uploads/import/cfc73574fe398be7ce684fbc17aa1bb7.nt +0 -259
  283. data/public/uploads/import/d2366992f6e9e4377d02fc691fc2d3d3.nt +0 -259
  284. data/public/uploads/import/dc14a0fa30c105a5770da2c960daaf29.nt +0 -259
  285. data/public/uploads/import/e9289f6f920cf44d0e81599410b39090.nt +0 -259
  286. data/public/uploads/import/ed1c212d4f320e414caacda7a7988f83.nt +0 -259
  287. data/public/uploads/import/ed460af60bf4d0884d37a86bb02411e7.nt +0 -259
  288. data/public/uploads/import/f17024adf37be768041307528e848bd6.nt +0 -259
  289. data/public/uploads/import/f2f6025f6de90ee4609c2928a817c51d.nt +0 -259
  290. data/public/uploads/import/f427507b1c208ddf69204ea5414e5d18.nt +0 -259
  291. data/public/uploads/import/ffce91887b3ac5b7319a80926ff310ef.nt +0 -259
  292. data/public/uploads/tmp/1417625624-7926-3861/hobbies.nt +0 -259
  293. data/public/uploads/tmp/1417625658-7975-5171/hobbies.nt +0 -259
  294. data/public/uploads/tmp/1418649743-7886-1510/hobbies.nt +0 -259
  295. data/public/uploads/tmp/1418653029-9019-1572/hobbies.nt +0 -259
  296. data/public/uploads/tmp/1418656093-9614-5971/hobbies.nt +0 -259
  297. data/public/uploads/tmp/1418659992-10218-8665/hobbies.nt +0 -259
  298. data/public/uploads/tmp/1418664440-11199-8740/hobbies.nt +0 -259
  299. data/public/uploads/tmp/1418665022-11430-9919/hobbies.nt +0 -259
  300. data/public/uploads/tmp/1418665225-11485-5805/hobbies.nt +0 -259
  301. data/public/uploads/tmp/1418665744-11777-4958/hobbies.nt +0 -259
  302. data/public/uploads/tmp/1418666103-11837-9818/hobbies.nt +0 -259
  303. data/public/uploads/tmp/1418666157-11880-9002/hobbies.nt +0 -259
  304. data/public/uploads/tmp/1418666292-11920-9076/hobbies.nt +0 -259
  305. data/public/uploads/tmp/1418666482-11968-5799/hobbies.nt +0 -259
  306. data/public/uploads/tmp/1418666589-12006-6137/hobbies.nt +0 -259
  307. data/public/uploads/tmp/1419417707-62741-8601/hobbies.nt +0 -259
  308. data/public/uploads/tmp/1419418501-62977-9798/hobbies.nt +0 -259
  309. data/public/uploads/tmp/1419419091-63178-5200/hobbies.nt +0 -259
  310. data/public/uploads/tmp/1419845421-37940-7338/hobbies.nt +0 -259
  311. data/public/uploads/tmp/1419872019-93309-7785/hobbies.nt +0 -259
  312. data/public/uploads/tmp/1419872459-93489-7475/hobbies.nt +0 -259
  313. data/public/uploads/tmp/1420204292-55473-2339/hobbies.nt +0 -259
  314. data/public/uploads/tmp/1420469113-94913-1977/hobbies.nt +0 -259
  315. data/public/uploads/tmp/1420469218-94957-7818/hobbies.nt +0 -259
  316. data/public/uploads/tmp/1420471310-95437-1840/hobbies.nt +0 -259
  317. data/public/uploads/tmp/1420475764-97681-5693/hobbies.nt +0 -259
  318. data/public/uploads/tmp/1420475937-97729-2119/hobbies.nt +0 -259
  319. data/public/uploads/tmp/1420476857-98058-7891/hobbies.nt +0 -259
  320. data/public/uploads/tmp/1420535851-99018-0174/hobbies.nt +0 -259
  321. data/public/uploads/tmp/1420536204-1785-0172/hobbies.nt +0 -259
  322. data/public/uploads/tmp/1420551687-4559-4581/hobbies.nt +0 -259
  323. data/public/uploads/tmp/1420553228-5060-8398/hobbies.nt +0 -259
  324. data/public/uploads/tmp/1420554138-5330-1218/hobbies.nt +0 -259
  325. data/public/uploads/tmp/1420623682-11549-0730/hobbies.nt +0 -259
  326. data/public/uploads/tmp/1420627830-12489-1669/hobbies.nt +0 -259
  327. data/public/uploads/tmp/1420643849-18200-3932/hobbies.nt +0 -259
  328. data/public/uploads/tmp/1420649772-21728-5542/hobbies.nt +0 -259
  329. data/public/uploads/tmp/1420708117-27095-8292/hobbies.nt +0 -259
  330. data/public/uploads/tmp/1420708387-27223-6774/hobbies.nt +0 -259
  331. data/public/uploads/tmp/1420708470-27267-7475/hobbies.nt +0 -259
  332. data/public/uploads/tmp/1420708517-27294-4695/hobbies.nt +0 -259
  333. data/public/uploads/tmp/1420708539-27319-1354/hobbies.nt +0 -259
  334. data/public/uploads/tmp/1420708586-27334-3786/hobbies.nt +0 -259
  335. data/public/uploads/tmp/1420708992-27418-8019/hobbies.nt +0 -259
  336. data/public/uploads/tmp/1420709221-27495-1252/hobbies.nt +0 -259
  337. data/public/uploads/tmp/1420709888-27667-9904/hobbies.nt +0 -259
  338. data/public/uploads/tmp/1420710092-27729-5735/hobbies.nt +0 -259
  339. data/public/uploads/tmp/1420710448-27814-7190/hobbies.nt +0 -259
  340. data/public/uploads/tmp/1420710886-27909-4558/hobbies.nt +0 -259
  341. data/public/uploads/tmp/1420711474-28046-6914/hobbies.nt +0 -259
  342. data/public/uploads/tmp/1420711601-28081-0714/hobbies.nt +0 -259
  343. data/public/uploads/tmp/1420711904-28153-8591/hobbies.nt +0 -259
  344. data/public/uploads/tmp/1420712160-28240-2054/hobbies.nt +0 -259
  345. data/public/uploads/tmp/1420712349-28303-3685/hobbies.nt +0 -259
  346. data/public/uploads/tmp/1420712756-28475-0893/hobbies.nt +0 -259
  347. data/public/uploads/tmp/1420712995-28567-4743/hobbies.nt +0 -259
  348. data/public/uploads/tmp/1420722946-31448-5312/hobbies.nt +0 -259
  349. data/public/uploads/tmp/1420723021-31498-6069/hobbies.nt +0 -259
  350. data/public/uploads/tmp/1420723172-31541-4390/hobbies.nt +0 -259
  351. data/public/uploads/tmp/1420723249-31574-6508/hobbies.nt +0 -259
@@ -1,28 +0,0 @@
1
- <http://www.example.com/animal> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
2
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
3
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#prefLabel> "Tier"@de .
4
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#prefLabel> "Animal"@en .
5
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#altLabel> "Viehzeug"@de .
6
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/cow> .
7
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/donkey> .
8
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/monkey> .
9
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#definition> "Ein Tier ist kein Mensch."@de .
10
- <http://www.example.com/cow> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
11
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
12
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#prefLabel> "Kuh"@de .
13
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#prefLabel> "Cow"@en .
14
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#altLabel> "Rind"@de .
15
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
16
- <http://www.example.com/donkey> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
17
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
18
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Esel"@de .
19
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Donkey"@en .
20
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
21
- <http://www.example.com/monkey> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
22
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
23
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Affe"@de .
24
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Monkey"@en .
25
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#altLabel> "Äffle"@de .
26
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#altLabel> "Ape"@en .
27
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
28
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#exactMatch> <http://dbpedia.org/page/Monkey> .
@@ -1,28 +0,0 @@
1
- <http://www.example.com/animal> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
2
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
3
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#prefLabel> "Tier"@de .
4
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#prefLabel> "Animal"@en .
5
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#altLabel> "Viehzeug"@de .
6
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/cow> .
7
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/donkey> .
8
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/monkey> .
9
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#definition> "Ein Tier ist kein Mensch."@de .
10
- <http://www.example.com/cow> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
11
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
12
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#prefLabel> "Kuh"@de .
13
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#prefLabel> "Cow"@en .
14
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#altLabel> "Rind"@de .
15
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
16
- <http://www.example.com/donkey> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
17
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
18
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Esel"@de .
19
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Donkey"@en .
20
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
21
- <http://www.example.com/monkey> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
22
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
23
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Affe"@de .
24
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Monkey"@en .
25
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#altLabel> "Äffle"@de .
26
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#altLabel> "Ape"@en .
27
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
28
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#exactMatch> <http://dbpedia.org/page/Monkey> .
data/public/export/863.nt DELETED
@@ -1,28 +0,0 @@
1
- <http://www.example.com/animal> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
2
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
3
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#prefLabel> "Tier"@de .
4
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#prefLabel> "Animal"@en .
5
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#altLabel> "Viehzeug"@de .
6
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/cow> .
7
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/donkey> .
8
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/monkey> .
9
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#definition> "Ein Tier ist kein Mensch."@de .
10
- <http://www.example.com/cow> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
11
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
12
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#prefLabel> "Kuh"@de .
13
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#prefLabel> "Cow"@en .
14
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#altLabel> "Rind"@de .
15
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
16
- <http://www.example.com/donkey> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
17
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
18
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Esel"@de .
19
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Donkey"@en .
20
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
21
- <http://www.example.com/monkey> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
22
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
23
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Affe"@de .
24
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Monkey"@en .
25
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#altLabel> "Äffle"@de .
26
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#altLabel> "Ape"@en .
27
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
28
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#exactMatch> <http://dbpedia.org/page/Monkey> .
@@ -1,28 +0,0 @@
1
- <http://www.example.com/animal> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
2
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
3
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#prefLabel> "Tier"@de .
4
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#prefLabel> "Animal"@en .
5
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#altLabel> "Viehzeug"@de .
6
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/cow> .
7
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/donkey> .
8
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#narrower> <http://www.example.com/monkey> .
9
- <http://www.example.com/animal> <http://www.w3.org/2004/02/skos/core#definition> "Ein Tier ist kein Mensch."@de .
10
- <http://www.example.com/cow> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
11
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
12
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#prefLabel> "Kuh"@de .
13
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#prefLabel> "Cow"@en .
14
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#altLabel> "Rind"@de .
15
- <http://www.example.com/cow> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
16
- <http://www.example.com/donkey> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
17
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
18
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Esel"@de .
19
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Donkey"@en .
20
- <http://www.example.com/donkey> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
21
- <http://www.example.com/monkey> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
22
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#inScheme> <http://www.example.com/scheme> .
23
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Affe"@de .
24
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#prefLabel> "Monkey"@en .
25
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#altLabel> "Äffle"@de .
26
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#altLabel> "Ape"@en .
27
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#broader> <http://www.example.com/animal> .
28
- <http://www.example.com/monkey> <http://www.w3.org/2004/02/skos/core#exactMatch> <http://dbpedia.org/page/Monkey> .
@@ -1,35 +0,0 @@
1
- // Copyright 2006 Google Inc.
2
- //
3
- // Licensed under the Apache License, Version 2.0 (the "License");
4
- // you may not use this file except in compliance with the License.
5
- // You may obtain a copy of the License at
6
- //
7
- // http://www.apache.org/licenses/LICENSE-2.0
8
- //
9
- // Unless required by applicable law or agreed to in writing, software
10
- // distributed under the License is distributed on an "AS IS" BASIS,
11
- // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- // See the License for the specific language governing permissions and
13
- // limitations under the License.
14
- document.createElement("canvas").getContext||(function(){var s=Math,j=s.round,F=s.sin,G=s.cos,V=s.abs,W=s.sqrt,k=10,v=k/2;function X(){return this.context_||(this.context_=new H(this))}var L=Array.prototype.slice;function Y(b,a){var c=L.call(arguments,2);return function(){return b.apply(a,c.concat(L.call(arguments)))}}var M={init:function(b){if(/MSIE/.test(navigator.userAgent)&&!window.opera){var a=b||document;a.createElement("canvas");a.attachEvent("onreadystatechange",Y(this.init_,this,a))}},init_:function(b){b.namespaces.g_vml_||
15
- b.namespaces.add("g_vml_","urn:schemas-microsoft-com:vml","#default#VML");b.namespaces.g_o_||b.namespaces.add("g_o_","urn:schemas-microsoft-com:office:office","#default#VML");if(!b.styleSheets.ex_canvas_){var a=b.createStyleSheet();a.owningElement.id="ex_canvas_";a.cssText="canvas{display:inline-block;overflow:hidden;text-align:left;width:300px;height:150px}g_vml_\\:*{behavior:url(#default#VML)}g_o_\\:*{behavior:url(#default#VML)}"}var c=b.getElementsByTagName("canvas"),d=0;for(;d<c.length;d++)this.initElement(c[d])},
16
- initElement:function(b){if(!b.getContext){b.getContext=X;b.innerHTML="";b.attachEvent("onpropertychange",Z);b.attachEvent("onresize",$);var a=b.attributes;if(a.width&&a.width.specified)b.style.width=a.width.nodeValue+"px";else b.width=b.clientWidth;if(a.height&&a.height.specified)b.style.height=a.height.nodeValue+"px";else b.height=b.clientHeight}return b}};function Z(b){var a=b.srcElement;switch(b.propertyName){case "width":a.style.width=a.attributes.width.nodeValue+"px";a.getContext().clearRect();
17
- break;case "height":a.style.height=a.attributes.height.nodeValue+"px";a.getContext().clearRect();break}}function $(b){var a=b.srcElement;if(a.firstChild){a.firstChild.style.width=a.clientWidth+"px";a.firstChild.style.height=a.clientHeight+"px"}}M.init();var N=[],B=0;for(;B<16;B++){var C=0;for(;C<16;C++)N[B*16+C]=B.toString(16)+C.toString(16)}function I(){return[[1,0,0],[0,1,0],[0,0,1]]}function y(b,a){var c=I(),d=0;for(;d<3;d++){var f=0;for(;f<3;f++){var h=0,g=0;for(;g<3;g++)h+=b[d][g]*a[g][f];c[d][f]=
18
- h}}return c}function O(b,a){a.fillStyle=b.fillStyle;a.lineCap=b.lineCap;a.lineJoin=b.lineJoin;a.lineWidth=b.lineWidth;a.miterLimit=b.miterLimit;a.shadowBlur=b.shadowBlur;a.shadowColor=b.shadowColor;a.shadowOffsetX=b.shadowOffsetX;a.shadowOffsetY=b.shadowOffsetY;a.strokeStyle=b.strokeStyle;a.globalAlpha=b.globalAlpha;a.arcScaleX_=b.arcScaleX_;a.arcScaleY_=b.arcScaleY_;a.lineScale_=b.lineScale_}function P(b){var a,c=1;b=String(b);if(b.substring(0,3)=="rgb"){var d=b.indexOf("(",3),f=b.indexOf(")",d+
19
- 1),h=b.substring(d+1,f).split(",");a="#";var g=0;for(;g<3;g++)a+=N[Number(h[g])];if(h.length==4&&b.substr(3,1)=="a")c=h[3]}else a=b;return{color:a,alpha:c}}function aa(b){switch(b){case "butt":return"flat";case "round":return"round";case "square":default:return"square"}}function H(b){this.m_=I();this.mStack_=[];this.aStack_=[];this.currentPath_=[];this.fillStyle=this.strokeStyle="#000";this.lineWidth=1;this.lineJoin="miter";this.lineCap="butt";this.miterLimit=k*1;this.globalAlpha=1;this.canvas=b;
20
- var a=b.ownerDocument.createElement("div");a.style.width=b.clientWidth+"px";a.style.height=b.clientHeight+"px";a.style.overflow="hidden";a.style.position="absolute";b.appendChild(a);this.element_=a;this.lineScale_=this.arcScaleY_=this.arcScaleX_=1}var i=H.prototype;i.clearRect=function(){this.element_.innerHTML=""};i.beginPath=function(){this.currentPath_=[]};i.moveTo=function(b,a){var c=this.getCoords_(b,a);this.currentPath_.push({type:"moveTo",x:c.x,y:c.y});this.currentX_=c.x;this.currentY_=c.y};
21
- i.lineTo=function(b,a){var c=this.getCoords_(b,a);this.currentPath_.push({type:"lineTo",x:c.x,y:c.y});this.currentX_=c.x;this.currentY_=c.y};i.bezierCurveTo=function(b,a,c,d,f,h){var g=this.getCoords_(f,h),l=this.getCoords_(b,a),e=this.getCoords_(c,d);Q(this,l,e,g)};function Q(b,a,c,d){b.currentPath_.push({type:"bezierCurveTo",cp1x:a.x,cp1y:a.y,cp2x:c.x,cp2y:c.y,x:d.x,y:d.y});b.currentX_=d.x;b.currentY_=d.y}i.quadraticCurveTo=function(b,a,c,d){var f=this.getCoords_(b,a),h=this.getCoords_(c,d),g={x:this.currentX_+
22
- 0.6666666666666666*(f.x-this.currentX_),y:this.currentY_+0.6666666666666666*(f.y-this.currentY_)};Q(this,g,{x:g.x+(h.x-this.currentX_)/3,y:g.y+(h.y-this.currentY_)/3},h)};i.arc=function(b,a,c,d,f,h){c*=k;var g=h?"at":"wa",l=b+G(d)*c-v,e=a+F(d)*c-v,m=b+G(f)*c-v,r=a+F(f)*c-v;if(l==m&&!h)l+=0.125;var n=this.getCoords_(b,a),o=this.getCoords_(l,e),q=this.getCoords_(m,r);this.currentPath_.push({type:g,x:n.x,y:n.y,radius:c,xStart:o.x,yStart:o.y,xEnd:q.x,yEnd:q.y})};i.rect=function(b,a,c,d){this.moveTo(b,
23
- a);this.lineTo(b+c,a);this.lineTo(b+c,a+d);this.lineTo(b,a+d);this.closePath()};i.strokeRect=function(b,a,c,d){var f=this.currentPath_;this.beginPath();this.moveTo(b,a);this.lineTo(b+c,a);this.lineTo(b+c,a+d);this.lineTo(b,a+d);this.closePath();this.stroke();this.currentPath_=f};i.fillRect=function(b,a,c,d){var f=this.currentPath_;this.beginPath();this.moveTo(b,a);this.lineTo(b+c,a);this.lineTo(b+c,a+d);this.lineTo(b,a+d);this.closePath();this.fill();this.currentPath_=f};i.createLinearGradient=function(b,
24
- a,c,d){var f=new D("gradient");f.x0_=b;f.y0_=a;f.x1_=c;f.y1_=d;return f};i.createRadialGradient=function(b,a,c,d,f,h){var g=new D("gradientradial");g.x0_=b;g.y0_=a;g.r0_=c;g.x1_=d;g.y1_=f;g.r1_=h;return g};i.drawImage=function(b){var a,c,d,f,h,g,l,e,m=b.runtimeStyle.width,r=b.runtimeStyle.height;b.runtimeStyle.width="auto";b.runtimeStyle.height="auto";var n=b.width,o=b.height;b.runtimeStyle.width=m;b.runtimeStyle.height=r;if(arguments.length==3){a=arguments[1];c=arguments[2];h=g=0;l=d=n;e=f=o}else if(arguments.length==
25
- 5){a=arguments[1];c=arguments[2];d=arguments[3];f=arguments[4];h=g=0;l=n;e=o}else if(arguments.length==9){h=arguments[1];g=arguments[2];l=arguments[3];e=arguments[4];a=arguments[5];c=arguments[6];d=arguments[7];f=arguments[8]}else throw Error("Invalid number of arguments");var q=this.getCoords_(a,c),t=[];t.push(" <g_vml_:group",' coordsize="',k*10,",",k*10,'"',' coordorigin="0,0"',' style="width:',10,"px;height:",10,"px;position:absolute;");if(this.m_[0][0]!=1||this.m_[0][1]){var E=[];E.push("M11=",
26
- this.m_[0][0],",","M12=",this.m_[1][0],",","M21=",this.m_[0][1],",","M22=",this.m_[1][1],",","Dx=",j(q.x/k),",","Dy=",j(q.y/k),"");var p=q,z=this.getCoords_(a+d,c),w=this.getCoords_(a,c+f),x=this.getCoords_(a+d,c+f);p.x=s.max(p.x,z.x,w.x,x.x);p.y=s.max(p.y,z.y,w.y,x.y);t.push("padding:0 ",j(p.x/k),"px ",j(p.y/k),"px 0;filter:progid:DXImageTransform.Microsoft.Matrix(",E.join(""),", sizingmethod='clip');")}else t.push("top:",j(q.y/k),"px;left:",j(q.x/k),"px;");t.push(' ">','<g_vml_:image src="',b.src,
27
- '"',' style="width:',k*d,"px;"," height:",k*f,'px;"',' cropleft="',h/n,'"',' croptop="',g/o,'"',' cropright="',(n-h-l)/n,'"',' cropbottom="',(o-g-e)/o,'"'," />","</g_vml_:group>");this.element_.insertAdjacentHTML("BeforeEnd",t.join(""))};i.stroke=function(b){var a=[],c=P(b?this.fillStyle:this.strokeStyle),d=c.color,f=c.alpha*this.globalAlpha;a.push("<g_vml_:shape",' filled="',!!b,'"',' style="position:absolute;width:',10,"px;height:",10,'px;"',' coordorigin="0 0" coordsize="',k*10," ",k*10,'"',' stroked="',
28
- !b,'"',' path="');var h={x:null,y:null},g={x:null,y:null},l=0;for(;l<this.currentPath_.length;l++){var e=this.currentPath_[l];switch(e.type){case "moveTo":a.push(" m ",j(e.x),",",j(e.y));break;case "lineTo":a.push(" l ",j(e.x),",",j(e.y));break;case "close":a.push(" x ");e=null;break;case "bezierCurveTo":a.push(" c ",j(e.cp1x),",",j(e.cp1y),",",j(e.cp2x),",",j(e.cp2y),",",j(e.x),",",j(e.y));break;case "at":case "wa":a.push(" ",e.type," ",j(e.x-this.arcScaleX_*e.radius),",",j(e.y-this.arcScaleY_*e.radius),
29
- " ",j(e.x+this.arcScaleX_*e.radius),",",j(e.y+this.arcScaleY_*e.radius)," ",j(e.xStart),",",j(e.yStart)," ",j(e.xEnd),",",j(e.yEnd));break}if(e){if(h.x==null||e.x<h.x)h.x=e.x;if(g.x==null||e.x>g.x)g.x=e.x;if(h.y==null||e.y<h.y)h.y=e.y;if(g.y==null||e.y>g.y)g.y=e.y}}a.push(' ">');if(b)if(typeof this.fillStyle=="object"){var m=this.fillStyle,r=0,n={x:0,y:0},o=0,q=1;if(m.type_=="gradient"){var t=m.x1_/this.arcScaleX_,E=m.y1_/this.arcScaleY_,p=this.getCoords_(m.x0_/this.arcScaleX_,m.y0_/this.arcScaleY_),
30
- z=this.getCoords_(t,E);r=Math.atan2(z.x-p.x,z.y-p.y)*180/Math.PI;if(r<0)r+=360;if(r<1.0E-6)r=0}else{var p=this.getCoords_(m.x0_,m.y0_),w=g.x-h.x,x=g.y-h.y;n={x:(p.x-h.x)/w,y:(p.y-h.y)/x};w/=this.arcScaleX_*k;x/=this.arcScaleY_*k;var R=s.max(w,x);o=2*m.r0_/R;q=2*m.r1_/R-o}var u=m.colors_;u.sort(function(ba,ca){return ba.offset-ca.offset});var J=u.length,da=u[0].color,ea=u[J-1].color,fa=u[0].alpha*this.globalAlpha,ga=u[J-1].alpha*this.globalAlpha,S=[],l=0;for(;l<J;l++){var T=u[l];S.push(T.offset*q+
31
- o+" "+T.color)}a.push('<g_vml_:fill type="',m.type_,'"',' method="none" focus="100%"',' color="',da,'"',' color2="',ea,'"',' colors="',S.join(","),'"',' opacity="',ga,'"',' g_o_:opacity2="',fa,'"',' angle="',r,'"',' focusposition="',n.x,",",n.y,'" />')}else a.push('<g_vml_:fill color="',d,'" opacity="',f,'" />');else{var K=this.lineScale_*this.lineWidth;if(K<1)f*=K;a.push("<g_vml_:stroke",' opacity="',f,'"',' joinstyle="',this.lineJoin,'"',' miterlimit="',this.miterLimit,'"',' endcap="',aa(this.lineCap),
32
- '"',' weight="',K,'px"',' color="',d,'" />')}a.push("</g_vml_:shape>");this.element_.insertAdjacentHTML("beforeEnd",a.join(""))};i.fill=function(){this.stroke(true)};i.closePath=function(){this.currentPath_.push({type:"close"})};i.getCoords_=function(b,a){var c=this.m_;return{x:k*(b*c[0][0]+a*c[1][0]+c[2][0])-v,y:k*(b*c[0][1]+a*c[1][1]+c[2][1])-v}};i.save=function(){var b={};O(this,b);this.aStack_.push(b);this.mStack_.push(this.m_);this.m_=y(I(),this.m_)};i.restore=function(){O(this.aStack_.pop(),
33
- this);this.m_=this.mStack_.pop()};function ha(b){var a=0;for(;a<3;a++){var c=0;for(;c<2;c++)if(!isFinite(b[a][c])||isNaN(b[a][c]))return false}return true}function A(b,a,c){if(!!ha(a)){b.m_=a;if(c)b.lineScale_=W(V(a[0][0]*a[1][1]-a[0][1]*a[1][0]))}}i.translate=function(b,a){A(this,y([[1,0,0],[0,1,0],[b,a,1]],this.m_),false)};i.rotate=function(b){var a=G(b),c=F(b);A(this,y([[a,c,0],[-c,a,0],[0,0,1]],this.m_),false)};i.scale=function(b,a){this.arcScaleX_*=b;this.arcScaleY_*=a;A(this,y([[b,0,0],[0,a,
34
- 0],[0,0,1]],this.m_),true)};i.transform=function(b,a,c,d,f,h){A(this,y([[b,a,0],[c,d,0],[f,h,1]],this.m_),true)};i.setTransform=function(b,a,c,d,f,h){A(this,[[b,a,0],[c,d,0],[f,h,1]],true)};i.clip=function(){};i.arcTo=function(){};i.createPattern=function(){return new U};function D(b){this.type_=b;this.r1_=this.y1_=this.x1_=this.r0_=this.y0_=this.x0_=0;this.colors_=[]}D.prototype.addColorStop=function(b,a){a=P(a);this.colors_.push({offset:b,color:a.color,alpha:a.alpha})};function U(){}G_vmlCanvasManager=
35
- M;CanvasRenderingContext2D=H;CanvasGradient=D;CanvasPattern=U})();
@@ -1,118 +0,0 @@
1
- /*jslint vars: true, unparam: true, browser: true */
2
- /*global jQuery */
3
-
4
- var IQVOC = (function($) {
5
-
6
- "use strict";
7
-
8
- var dynamicAuth = function(container) {
9
- container = container.nodeType ? container : $(container)[0];
10
- var authLink = $("a", container),
11
- uri = authLink.attr("href");
12
- if(uri.indexOf("/new.html") !== -1) {
13
- var menu = $("ul", container),
14
- label = authLink.text() + " &#9660;";
15
- authLink.click(function(ev) {
16
- authLink.html(label);
17
- menu.removeClass("hidden").slideDown()
18
- .find("li").load(uri + " #new_user_session");
19
- ev.preventDefault();
20
- });
21
- }
22
- };
23
-
24
- var collapseDropdown = function(node) {
25
- var el = $(node || this);
26
- el.find("ul").slideUp(function() {
27
- el.removeClass("hover");
28
- });
29
- };
30
-
31
- // augments Son of Suckerfish drop-down menus
32
- var enhancedDropdown = function(container) {
33
- container = container.jquery ? container : $(container);
34
- var menuItems = $("> li", container),
35
- ddtimer;
36
- menuItems.find("ul").hide();
37
- menuItems.live({
38
- mouseenter: function(ev) {
39
- clearTimeout(ddtimer);
40
- menuItems.not(this).filter(".hover").each(function(i, node) {
41
- collapseDropdown(node);
42
- });
43
- $(this).addClass("hover")
44
- .find("ul").not(".hidden").slideDown();
45
- },
46
- mouseleave: function(ev) {
47
- clearTimeout(ddtimer);
48
- ddtimer = setTimeout(jQuery.proxy(collapseDropdown, this), 600);
49
- }
50
- });
51
- };
52
-
53
- var createNote = function(ev) {
54
- var container = $(this).closest("fieldset"),
55
- source = $("ol li:last-child", container);
56
-
57
- // special case for usage notes
58
- // a usage note contains a select box instead of a textarea
59
- // FIXME: Hardcoded UMT stuff
60
- var isUsageNote = source.find("label:first")[0].getAttribute("for");
61
- isUsageNote = isUsageNote ? isUsageNote.match(/^concept_note_umt_usage_notes/) : false;
62
-
63
- if(source.is(":hidden")) {
64
- source.show();
65
- return false;
66
- }
67
-
68
- var clone = source.clone();
69
-
70
- var count = source.find(isUsageNote ? "select" : "textarea")[0].id
71
- .match(/_(\d+)_/)[1];
72
- count = String(parseInt(count, 10) + 1);
73
- var newIdCount = "_" + count + "_",
74
- newNameCount = "[" + count + "]";
75
-
76
- clone.find("label")[0]
77
- .setAttribute("for", (source.find("label")[0].getAttribute("for") || "")
78
- .replace(/_\d+_/, newIdCount));
79
-
80
- // clone.find("input")
81
- // .attr("id", source.find("input[type=hidden]").attr("id").replace(/_\d+_/, newIdCount))
82
- // .attr("name", source.find("input[type=hidden]").attr("name").replace(/\[\d+\]/, newNameCount));
83
-
84
- var src, el;
85
- if(!isUsageNote) {
86
- src = source.find("textarea")[0];
87
- el = clone.find("textarea").val("")[0];
88
- el.id = src.id.replace(/_\d+_/, newIdCount);
89
- el.name = src.name.replace(/\[\d+\]/, newNameCount);
90
- }
91
- src = source.find("select")[0];
92
- el = clone.find("select")[0];
93
- el.id = src.id.replace(/_\d+_/, newIdCount);
94
- el.name = src.name.replace(/\[\d+\]/, newNameCount);
95
-
96
- clone.addClass("new");
97
- $("ol", container).append(clone);
98
-
99
- return false;
100
- };
101
-
102
- // work around apparent capybara-webkit issue:
103
- // https://github.com/thoughtbot/capybara-webkit/issues/43
104
- var Storage = localStorage || null;
105
- if(Storage === null) {
106
- Storage = {};
107
- Storage.getItem = function() { return null; };
108
- Storage.setItem = $.noop;
109
- }
110
-
111
- return {
112
- Storage: Storage,
113
- dynamicAuth: dynamicAuth,
114
- enhancedDropdown: enhancedDropdown,
115
- createNote: createNote
116
- };
117
-
118
- }(jQuery));
@@ -1,153 +0,0 @@
1
-
2
- /*
3
- Copyright (c) 2011 Sencha Inc. - Author: Nicolas Garcia Belmonte (http://philogb.github.com/)
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in
13
- all copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
- THE SOFTWARE.
22
-
23
- */
24
-
25
- (function(){window.$jit=function(a){var a=a||window,b;for(b in $jit)$jit[b].$extend&&(a[b]=$jit[b])};$jit.version="2.0.1";var f=function(a){return document.getElementById(a)};f.empty=function(){};f.extend=function(a,b){for(var c in b||{})a[c]=b[c];return a};f.lambda=function(a){return typeof a=="function"?a:function(){return a}};f.time=Date.now||function(){return+new Date};f.splat=function(a){var b=f.type(a);return b?b!="array"?[a]:a:[]};f.type=function(a){var b=f.type.s.call(a).match(/^\[object\s(.*)\]$/)[1].toLowerCase();
26
- if(b!="object")return b;if(a&&a.$$family)return a.$$family;return a&&a.nodeName&&a.nodeType==1?"element":b};f.type.s=Object.prototype.toString;f.each=function(a,b){if(f.type(a)=="object")for(var c in a)b(a[c],c);else{c=0;for(var d=a.length;c<d;c++)b(a[c],c)}};f.indexOf=function(a,b){if(Array.indexOf)return a.indexOf(b);for(var c=0,d=a.length;c<d;c++)if(a[c]===b)return c;return-1};f.map=function(a,b){var c=[];f.each(a,function(a,e){c.push(b(a,e))});return c};f.reduce=function(a,b,c){var d=a.length;
27
- if(d==0)return c;for(var e=arguments.length==3?c:a[--d];d--;)e=b(e,a[d]);return e};f.merge=function(){for(var a={},b=0,c=arguments.length;b<c;b++){var d=arguments[b];if(f.type(d)=="object")for(var e in d){var g=d[e],h=a[e];a[e]=h&&f.type(g)=="object"&&f.type(h)=="object"?f.merge(h,g):f.unlink(g)}}return a};f.unlink=function(a){var b;switch(f.type(a)){case "object":b={};for(var c in a)b[c]=f.unlink(a[c]);break;case "array":b=[];c=0;for(var d=a.length;c<d;c++)b[c]=f.unlink(a[c]);break;default:return a}return b};
28
- f.zip=function(){if(arguments.length===0)return[];for(var a=0,b=[],c=arguments.length,d=arguments[0].length;a<d;a++){for(var e=0,g=[];e<c;e++)g.push(arguments[e][a]);b.push(g)}return b};f.rgbToHex=function(a,b){if(a.length<3)return null;if(a.length==4&&a[3]==0&&!b)return"transparent";for(var c=[],d=0;d<3;d++){var e=(a[d]-0).toString(16);c.push(e.length==1?"0"+e:e)}return b?c:"#"+c.join("")};f.hexToRgb=function(a){if(a.length!=7){a=a.match(/^#?(\w{1,2})(\w{1,2})(\w{1,2})$/);a.shift();if(a.length!=
29
- 3)return null;for(var b=[],c=0;c<3;c++){var d=a[c];d.length==1&&(d+=d);b.push(parseInt(d,16))}return b}else return a=parseInt(a.slice(1),16),[a>>16,a>>8&255,a&255]};f.destroy=function(a){f.clean(a);a.parentNode&&a.parentNode.removeChild(a);a.clearAttributes&&a.clearAttributes()};f.clean=function(a){for(var a=a.childNodes,b=0,c=a.length;b<c;b++)f.destroy(a[b])};f.addEvent=function(a,b,c){a.addEventListener?a.addEventListener(b,c,!1):a.attachEvent("on"+b,c)};f.addEvents=function(a,b){for(var c in b)f.addEvent(a,
30
- c,b[c])};f.hasClass=function(a,b){return(" "+a.className+" ").indexOf(" "+b+" ")>-1};f.addClass=function(a,b){if(!f.hasClass(a,b))a.className=a.className+" "+b};f.removeClass=function(a,b){a.className=a.className.replace(RegExp("(^|\\s)"+b+"(?:\\s|$)"),"$1")};f.getPos=function(a){var b=function(a){for(var b={x:0,y:0};a&&!/^(?:body|html)$/i.test(a.tagName);)b.x+=a.offsetLeft,b.y+=a.offsetTop,a=a.offsetParent;return b}(a),a=function(a){for(var b={x:0,y:0};a&&!/^(?:body|html)$/i.test(a.tagName);)b.x+=
31
- a.scrollLeft,b.y+=a.scrollTop,a=a.parentNode;return b}(a);return{x:b.x-a.x,y:b.y-a.y}};f.event={get:function(a,b){return a||(b||window).event},getWheel:function(a){return a.wheelDelta?a.wheelDelta/120:-(a.detail||0)/3},isRightClick:function(a){return a.which==3||a.button==2},getPos:function(a,b){var b=b||window,a=a||b.event,c=b.document,c=c.documentElement||c.body;a.touches&&a.touches.length&&(a=a.touches[0]);return{x:a.pageX||a.clientX+c.scrollLeft,y:a.pageY||a.clientY+c.scrollTop}},stop:function(a){a.stopPropagation&&
32
- a.stopPropagation();a.cancelBubble=!0;a.preventDefault?a.preventDefault():a.returnValue=!1}};$jit.util=$jit.id=f;var i=function(a){var a=a||{},b=function(){for(var a in this)typeof this[a]!="function"&&(this[a]=f.unlink(this[a]));this.constructor=b;if(i.prototyping)return this;a=this.initialize?this.initialize.apply(this,arguments):this;this.$$family="class";return a},c;for(c in i.Mutators)a[c]&&(a=i.Mutators[c](a,a[c]),delete a[c]);f.extend(b,this);b.constructor=i;b.prototype=a;return b};i.Mutators=
33
- {Implements:function(a,b){f.each(f.splat(b),function(b){i.prototyping=b;var b=typeof b=="function"?new b:b,d;for(d in b)d in a||(a[d]=b[d]);delete i.prototyping});return a}};f.extend(i,{inherit:function(a,b){for(var c in b){var d=b[c],e=a[c],g=f.type(d);e&&g=="function"?d!=e&&i.override(a,c,d):a[c]=g=="object"?f.merge(e,d):d}return a},override:function(a,b,c){var d=i.prototyping;d&&a[b]!=d[b]&&(d=null);a[b]=function(){var e=this.parent;this.parent=d?d[b]:a[b];var g=c.apply(this,arguments);this.parent=
34
- e;return g}}});i.prototype.implement=function(){var a=this.prototype;f.each(Array.prototype.slice.call(arguments||[]),function(b){i.inherit(a,b)});return this};$jit.Class=i;$jit.json={prune:function(a,b){this.each(a,function(a,d){if(d==b&&a.children)delete a.children,a.children=[]})},getParent:function(a,b){if(a.id==b)return!1;var c=a.children;if(c&&c.length>0)for(var d=0;d<c.length;d++)if(c[d].id==b)return a;else{var e=this.getParent(c[d],b);if(e)return e}return!1},getSubtree:function(a,b){if(a.id==
35
- b)return a;for(var c=0,d=a.children;d&&c<d.length;c++){var e=this.getSubtree(d[c],b);if(e!=null)return e}return null},eachLevel:function(a,b,c,d){if(b<=c&&(d(a,b),a.children))for(var e=0,a=a.children;e<a.length;e++)this.eachLevel(a[e],b+1,c,d)},each:function(a,b){this.eachLevel(a,0,Number.MAX_VALUE,b)}};$jit.Trans={$extend:!0,linear:function(a){return a}};var v=$jit.Trans;(function(){var a=function(a,c){c=f.splat(c);return f.extend(a,{easeIn:function(d){return a(d,c)},easeOut:function(d){return 1-
36
- a(1-d,c)},easeInOut:function(d){return d<=0.5?a(2*d,c)/2:(2-a(2*(1-d),c))/2}})};f.each({Pow:function(a,c){return Math.pow(a,c[0]||6)},Expo:function(a){return Math.pow(2,8*(a-1))},Circ:function(a){return 1-Math.sin(Math.acos(a))},Sine:function(a){return 1-Math.sin((1-a)*Math.PI/2)},Back:function(a,c){c=c[0]||1.618;return Math.pow(a,2)*((c+1)*a-c)},Bounce:function(a){for(var c,d=0,e=1;;d+=e,e/=2)if(a>=(7-4*d)/11){c=e*e-Math.pow((11-6*d-11*a)/4,2);break}return c},Elastic:function(a,c){return Math.pow(2,
37
- 10*--a)*Math.cos(20*a*Math.PI*(c[0]||1)/3)}},function(b,c){v[c]=a(b)});f.each(["Quad","Cubic","Quart","Quint"],function(b,c){v[b]=a(function(a){return Math.pow(a,[c+2])})})})();var B=new i({initialize:function(a){this.setOptions(a)},setOptions:function(a){this.opt=f.merge({duration:2500,fps:40,transition:v.Quart.easeInOut,compute:f.empty,complete:f.empty,link:"ignore"},a||{});return this},step:function(){var a=f.time(),b=this.opt;a<this.time+b.duration?(a=b.transition((a-this.time)/b.duration),b.compute(a)):
38
- (this.timer=clearInterval(this.timer),b.compute(1),b.complete())},start:function(){if(!this.check())return this;this.time=0;this.startTimer();return this},startTimer:function(){var a=this,b=this.opt.fps;if(this.timer)return!1;this.time=f.time()-this.time;this.timer=setInterval(function(){a.step()},Math.round(1E3/b));return!0},pause:function(){this.stopTimer();return this},resume:function(){this.startTimer();return this},stopTimer:function(){if(!this.timer)return!1;this.time=f.time()-this.time;this.timer=
39
- clearInterval(this.timer);return!0},check:function(){if(!this.timer)return!0;if(this.opt.link=="cancel")return this.stopTimer(),!0;return!1}}),o=function(){for(var a=arguments,b=0,c=a.length,d={};b<c;b++){var e=o[a[b]];e.$extend?f.extend(d,e):d[a[b]]=e}return d};o.Canvas={$extend:!0,injectInto:"id",type:"2D",width:!1,height:!1,useCanvas:!1,withLabels:!0,background:!1,Scene:{Lighting:{enable:!1,ambient:[1,1,1],directional:{direction:{x:-100,y:-100,z:-100},color:[0.5,0.3,0.1]}}}};o.Node={$extend:!1,
40
- overridable:!1,type:"circle",color:"#ccb",alpha:1,dim:3,height:20,width:90,autoHeight:!1,autoWidth:!1,lineWidth:1,transform:!0,align:"center",angularWidth:1,span:1,CanvasStyles:{}};o.Edge={$extend:!1,overridable:!1,type:"line",color:"#ccb",lineWidth:1,dim:15,alpha:1,epsilon:7,CanvasStyles:{}};o.Fx={$extend:!0,fps:40,duration:2500,transition:$jit.Trans.Quart.easeInOut,clearCanvas:!0};o.Label={$extend:!1,overridable:!1,type:"HTML",style:" ",size:10,family:"sans-serif",textAlign:"center",textBaseline:"alphabetic",
41
- color:"#fff"};o.Tips={$extend:!1,enable:!1,type:"auto",offsetX:20,offsetY:20,force:!1,onShow:f.empty,onHide:f.empty};o.NodeStyles={$extend:!1,enable:!1,type:"auto",stylesHover:!1,stylesClick:!1};o.Events={$extend:!1,enable:!1,enableForEdges:!1,type:"auto",onClick:f.empty,onRightClick:f.empty,onMouseMove:f.empty,onMouseEnter:f.empty,onMouseLeave:f.empty,onDragStart:f.empty,onDragMove:f.empty,onDragCancel:f.empty,onDragEnd:f.empty,onTouchStart:f.empty,onTouchMove:f.empty,onTouchEnd:f.empty,onMouseWheel:f.empty};
42
- o.Navigation={$extend:!1,enable:!1,type:"auto",panning:!1,zooming:!1};o.Controller={$extend:!0,onBeforeCompute:f.empty,onAfterCompute:f.empty,onCreateLabel:f.empty,onPlaceLabel:f.empty,onComplete:f.empty,onBeforePlotLine:f.empty,onAfterPlotLine:f.empty,onBeforePlotNode:f.empty,onAfterPlotNode:f.empty,request:!1};var r={initialize:function(a,b){this.viz=b;this.canvas=b.canvas;this.config=b.config[a];this.nodeTypes=b.fx.nodeTypes;var c=this.config.type;this.labelContainer=(this.dom=c=="auto"?b.config.Label.type!=
43
- "Native":c!="Native")&&b.labels.getLabelContainer();this.isEnabled()&&this.initializePost()},initializePost:f.empty,setAsProperty:f.lambda(!1),isEnabled:function(){return this.config.enable},isLabel:function(a,b,c){var a=f.event.get(a,b),b=this.labelContainer,d=a.target||a.srcElement,a=a.relatedTarget;return c?a&&a==this.viz.canvas.getCtx().canvas&&!!d&&this.isDescendantOf(d,b):this.isDescendantOf(d,b)},isDescendantOf:function(a,b){for(;a&&a.parentNode;){if(a.parentNode==b)return a;a=a.parentNode}return!1}},
44
- y={onMouseUp:f.empty,onMouseDown:f.empty,onMouseMove:f.empty,onMouseOver:f.empty,onMouseOut:f.empty,onMouseWheel:f.empty,onTouchStart:f.empty,onTouchMove:f.empty,onTouchEnd:f.empty,onTouchCancel:f.empty},E=new i({initialize:function(a){this.viz=a;this.canvas=a.canvas;this.edge=this.node=!1;this.registeredObjects=[];this.attachEvents()},attachEvents:function(){var a=this.canvas.getElement(),b=this;a.oncontextmenu=f.lambda(!1);f.addEvents(a,{mouseup:function(a,c){var g=f.event.get(a,c);b.handleEvent("MouseUp",
45
- a,c,b.makeEventObject(a,c),f.event.isRightClick(g))},mousedown:function(a,c){var g=f.event.get(a,c);b.handleEvent("MouseDown",a,c,b.makeEventObject(a,c),f.event.isRightClick(g))},mousemove:function(a,c){b.handleEvent("MouseMove",a,c,b.makeEventObject(a,c))},mouseover:function(a,c){b.handleEvent("MouseOver",a,c,b.makeEventObject(a,c))},mouseout:function(a,c){b.handleEvent("MouseOut",a,c,b.makeEventObject(a,c))},touchstart:function(a,c){b.handleEvent("TouchStart",a,c,b.makeEventObject(a,c))},touchmove:function(a,
46
- c){b.handleEvent("TouchMove",a,c,b.makeEventObject(a,c))},touchend:function(a,c){b.handleEvent("TouchEnd",a,c,b.makeEventObject(a,c))}});var c=function(a,c){var g=f.event.get(a,c),g=f.event.getWheel(g);b.handleEvent("MouseWheel",a,c,g)};!document.getBoxObjectFor&&window.mozInnerScreenX==null?f.addEvent(a,"mousewheel",c):a.addEventListener("DOMMouseScroll",c,!1)},register:function(a){this.registeredObjects.push(a)},handleEvent:function(){for(var a=Array.prototype.slice.call(arguments),b=a.shift(),
47
- c=0,d=this.registeredObjects,e=d.length;c<e;c++)d[c]["on"+b].apply(d[c],a)},makeEventObject:function(a,b){var c=this,d=this.viz.graph,e=this.viz.fx,g=e.nodeTypes,h=e.edgeTypes;return{pos:!1,node:!1,edge:!1,contains:!1,getNodeCalled:!1,getEdgeCalled:!1,getPos:function(){var d=c.viz.canvas,e=d.getSize(),g=d.getPos(),h=d.translateOffsetX,n=d.translateOffsetY,i=d.scaleOffsetX,d=d.scaleOffsetY,u=f.event.getPos(a,b);return this.pos={x:(u.x-g.x-e.width/2-h)*1/i,y:(u.y-g.y-e.height/2-n)*1/d}},getNode:function(){if(this.getNodeCalled)return this.node;
48
- this.getNodeCalled=!0;for(var a in d.nodes){var b=d.nodes[a],h=b&&g[b.getData("type")];if(h=h&&h.contains&&h.contains.call(e,b,this.getPos()))return this.contains=h,c.node=this.node=b}return c.node=this.node=!1},getEdge:function(){if(this.getEdgeCalled)return this.edge;this.getEdgeCalled=!0;var a={},b;for(b in d.edges){var g=d.edges[b];a[b]=!0;for(var f in g)if(!(f in a)){var n=g[f],i=n&&h[n.getData("type")];if(i=i&&i.contains&&i.contains.call(e,n,this.getPos()))return this.contains=i,c.edge=this.edge=
49
- n}}return c.edge=this.edge=!1},getContains:function(){if(this.getNodeCalled)return this.contains;this.getNode();return this.contains}}}}),w={initializeExtras:function(){var a=new E(this),b=this;f.each(["NodeStyles","Tips","Navigation","Events"],function(c){var d=new w.Classes[c](c,b);d.isEnabled()&&a.register(d);d.setAsProperty()&&(b[c.toLowerCase()]=d)})},Classes:{}};w.Classes.Events=new i({Implements:[r,y],initializePost:function(){this.fx=this.viz.fx;this.ntypes=this.viz.fx.nodeTypes;this.etypes=
50
- this.viz.fx.edgeTypes;this.moved=this.touchMoved=this.touched=this.pressed=this.hovered=!1},setAsProperty:f.lambda(!0),onMouseUp:function(a,b,c,d){a=f.event.get(a,b);if(!this.moved)if(d)this.config.onRightClick(this.hovered,c,a);else this.config.onClick(this.pressed,c,a);if(this.pressed){if(this.moved)this.config.onDragEnd(this.pressed,c,a);else this.config.onDragCancel(this.pressed,c,a);this.pressed=this.moved=!1}},onMouseOut:function(a,b,c){var d=f.event.get(a,b),e;if(this.dom&&(e=this.isLabel(a,
51
- b,!0)))this.config.onMouseLeave(this.viz.graph.getNode(e.id),c,d),this.hovered=!1;else{a=d.relatedTarget;for(b=this.canvas.getElement();a&&a.parentNode;){if(b==a.parentNode)return;a=a.parentNode}if(this.hovered)this.config.onMouseLeave(this.hovered,c,d),this.hovered=!1}},onMouseOver:function(a,b,c){var d=f.event.get(a,b),e;if(this.dom&&(e=this.isLabel(a,b,!0)))this.hovered=this.viz.graph.getNode(e.id),this.config.onMouseEnter(this.hovered,c,d)},onMouseMove:function(a,b,c){a=f.event.get(a,b);if(this.pressed)this.moved=
52
- !0,this.config.onDragMove(this.pressed,c,a);else if(this.dom)this.config.onMouseMove(this.hovered,c,a);else{if(this.hovered){var b=this.hovered,d=b.nodeFrom?this.etypes[b.getData("type")]:this.ntypes[b.getData("type")];if(d&&d.contains&&d.contains.call(this.fx,b,c.getPos())){this.config.onMouseMove(b,c,a);return}else this.config.onMouseLeave(b,c,a),this.hovered=!1}if(this.hovered=c.getNode()||this.config.enableForEdges&&c.getEdge())this.config.onMouseEnter(this.hovered,c,a);else this.config.onMouseMove(!1,
53
- c,a)}},onMouseWheel:function(a,b,c){this.config.onMouseWheel(c,f.event.get(a,b))},onMouseDown:function(a,b,c){var d=f.event.get(a,b);if(this.dom){if(a=this.isLabel(a,b))this.pressed=this.viz.graph.getNode(a.id)}else this.pressed=c.getNode()||this.config.enableForEdges&&c.getEdge();this.pressed&&this.config.onDragStart(this.pressed,c,d)},onTouchStart:function(a,b,c){var d=f.event.get(a,b),e;(this.touched=this.dom&&(e=this.isLabel(a,b))?this.viz.graph.getNode(e.id):c.getNode()||this.config.enableForEdges&&
54
- c.getEdge())&&this.config.onTouchStart(this.touched,c,d)},onTouchMove:function(a,b,c){a=f.event.get(a,b);if(this.touched)this.touchMoved=!0,this.config.onTouchMove(this.touched,c,a)},onTouchEnd:function(a,b,c){a=f.event.get(a,b);if(this.touched){if(this.touchMoved)this.config.onTouchEnd(this.touched,c,a);else this.config.onTouchCancel(this.touched,c,a);this.touched=this.touchMoved=!1}}});w.Classes.Tips=new i({Implements:[r,y],initializePost:function(){if(document.body){var a=f("_tooltip")||document.createElement("div");
55
- a.id="_tooltip";a.className="tip";f.extend(a.style,{position:"absolute",display:"none",zIndex:13E3});document.body.appendChild(a);this.tip=a;this.node=!1}},setAsProperty:f.lambda(!0),onMouseOut:function(a,b){f.event.get(a,b);if(this.dom&&this.isLabel(a,b,!0))this.hide(!0);else{for(var c=a.relatedTarget,d=this.canvas.getElement();c&&c.parentNode;){if(d==c.parentNode)return;c=c.parentNode}this.hide(!1)}},onMouseOver:function(a,b){var c;if(this.dom&&(c=this.isLabel(a,b,!1)))this.node=this.viz.graph.getNode(c.id),
56
- this.config.onShow(this.tip,this.node,c)},onMouseMove:function(a,b,c){this.dom&&this.isLabel(a,b)&&this.setTooltipPosition(f.event.getPos(a,b));if(!this.dom){var d=c.getNode();if(d){if(this.config.force||!this.node||this.node.id!=d.id)this.node=d,this.config.onShow(this.tip,d,c.getContains());this.setTooltipPosition(f.event.getPos(a,b))}else this.hide(!0)}},setTooltipPosition:function(a){var b=this.tip,c=b.style,d=this.config;c.display="";var e={height:document.body.clientHeight,width:document.body.clientWidth},
57
- b={width:b.offsetWidth,height:b.offsetHeight},g=d.offsetX,d=d.offsetY;c.top=(a.y+d+b.height>e.height?a.y-b.height-d:a.y+d)+"px";c.left=(a.x+b.width+g>e.width?a.x-b.width-g:a.x+g)+"px"},hide:function(a){this.tip.style.display="none";a&&this.config.onHide()}});w.Classes.NodeStyles=new i({Implements:[r,y],initializePost:function(){this.fx=this.viz.fx;this.types=this.viz.fx.nodeTypes;this.nStyles=this.config;this.nodeStylesOnHover=this.nStyles.stylesHover;this.nodeStylesOnClick=this.nStyles.stylesClick;
58
- this.hoveredNode=!1;this.fx.nodeFxAnimation=new B;this.move=this.down=!1},onMouseOut:function(a,b){this.down=this.move=!1;if(this.hoveredNode){this.dom&&this.isLabel(a,b,!0)&&this.toggleStylesOnHover(this.hoveredNode,!1);for(var c=a.relatedTarget,d=this.canvas.getElement();c&&c.parentNode;){if(d==c.parentNode)return;c=c.parentNode}this.toggleStylesOnHover(this.hoveredNode,!1);this.hoveredNode=!1}},onMouseOver:function(a,b){var c;if(this.dom&&(c=this.isLabel(a,b,!0)))if(c=this.viz.graph.getNode(c.id),
59
- !c.selected)this.hoveredNode=c,this.toggleStylesOnHover(this.hoveredNode,!0)},onMouseDown:function(a,b,c,d){if(!d){var e;if(this.dom&&(e=this.isLabel(a,b)))this.down=this.viz.graph.getNode(e.id);else if(!this.dom)this.down=c.getNode();this.move=!1}},onMouseUp:function(a,b,c,d){if(!d){if(!this.move)this.onClick(c.getNode());this.down=this.move=!1}},getRestoredStyles:function(a,b){var c={},d=this["nodeStylesOn"+b],e;for(e in d)c[e]=a.styles["$"+e];return c},toggleStylesOnHover:function(a,b){this.nodeStylesOnHover&&
60
- this.toggleStylesOn("Hover",a,b)},toggleStylesOnClick:function(a,b){this.nodeStylesOnClick&&this.toggleStylesOn("Click",a,b)},toggleStylesOn:function(a,b,c){var d=this.viz;if(c){if(!b.styles)b.styles=f.merge(b.data,{});for(var e in this["nodeStylesOn"+a])c="$"+e,c in b.styles||(b.styles[c]=b.getData(e));d.fx.nodeFx(f.extend({elements:{id:b.id,properties:this["nodeStylesOn"+a]},transition:v.Quart.easeOut,duration:300,fps:40},this.config))}else a=this.getRestoredStyles(b,a),d.fx.nodeFx(f.extend({elements:{id:b.id,
61
- properties:a},transition:v.Quart.easeOut,duration:300,fps:40},this.config))},onClick:function(a){if(a){var b=this.nodeStylesOnClick;if(b)a.selected?(this.toggleStylesOnClick(a,!1),delete a.selected):(this.viz.graph.eachNode(function(a){if(a.selected){for(var d in b)a.setData(d,a.styles["$"+d],"end");delete a.selected}}),this.toggleStylesOnClick(a,!0),a.selected=!0,delete a.hovered,this.hoveredNode=!1)}},onMouseMove:function(a,b,c){if(this.down)this.move=!0;if(!this.dom||!this.isLabel(a,b)){var d=
62
- this.nodeStylesOnHover;if(d&&!this.dom){if(this.hoveredNode&&(a=this.types[this.hoveredNode.getData("type")])&&a.contains&&a.contains.call(this.fx,this.hoveredNode,c.getPos()))return;c=c.getNode();if((this.hoveredNode||c)&&!c.hovered)if(c&&!c.selected)this.fx.nodeFxAnimation.stopTimer(),this.viz.graph.eachNode(function(a){if(a.hovered&&!a.selected){for(var b in d)a.setData(b,a.styles["$"+b],"end");delete a.hovered}}),c.hovered=!0,this.hoveredNode=c,this.toggleStylesOnHover(c,!0);else if(this.hoveredNode&&
63
- !this.hoveredNode.selected)this.fx.nodeFxAnimation.stopTimer(),this.toggleStylesOnHover(this.hoveredNode,!1),delete this.hoveredNode.hovered,this.hoveredNode=!1}}}});w.Classes.Navigation=new i({Implements:[r,y],initializePost:function(){this.pressed=this.pos=!1},onMouseWheel:function(a,b,c){this.config.zooming&&(f.event.stop(f.event.get(a,b)),a=1+c*(this.config.zooming/1E3),this.canvas.scale(a,a))},onMouseDown:function(a,b,c){if(this.config.panning&&!(this.config.panning=="avoid nodes"&&(this.dom?
64
- this.isLabel(a,b):c.getNode()))){this.pressed=!0;this.pos=c.getPos();var a=this.canvas,b=a.translateOffsetX,c=a.translateOffsetY,d=a.scaleOffsetY;this.pos.x*=a.scaleOffsetX;this.pos.x+=b;this.pos.y*=d;this.pos.y+=c}},onMouseMove:function(a,b,c){if(this.config.panning&&this.pressed&&!(this.config.panning=="avoid nodes"&&(this.dom?this.isLabel(a,b):c.getNode()))){var a=this.pos,c=c.getPos(),d=this.canvas,e=d.translateOffsetX,g=d.translateOffsetY,b=d.scaleOffsetX,d=d.scaleOffsetY;c.x*=b;c.y*=d;c.x+=
65
- e;c.y+=g;e=c.x-a.x;a=c.y-a.y;this.pos=c;this.canvas.translate(e*1/b,a*1/d)}},onMouseUp:function(){if(this.config.panning)this.pressed=!1}});var s;(function(){function a(a,b){var g=document.createElement(a),h;for(h in b)typeof b[h]=="object"?f.extend(g[h],b[h]):g[h]=b[h];a=="canvas"&&!c&&G_vmlCanvasManager&&(g=G_vmlCanvasManager.initElement(document.body.appendChild(g)));return g}var b=typeof HTMLCanvasElement,c=b=="object"||b=="function";$jit.Canvas=s=new i({canvases:[],pos:!1,element:!1,labelContainer:!1,
66
- translateOffsetX:0,translateOffsetY:0,scaleOffsetX:1,scaleOffsetY:1,initialize:function(b,c){this.viz=b;this.opt=this.config=c;var g=f.type(c.injectInto)=="string"?c.injectInto:c.injectInto.id,h=c.type,l=g+"-label",j=f(g),t=c.width||j.offsetWidth,C=c.height||j.offsetHeight;this.id=g;var n={injectInto:g,width:t,height:C};this.element=a("div",{id:g+"-canvaswidget",style:{position:"relative",width:t+"px",height:C+"px"}});this.labelContainer=this.createLabelContainer(c.Label.type,l,n);this.canvases.push(new s.Base[h]({config:f.extend({idSuffix:"-canvas"},
67
- n),plot:function(){b.fx.plot()},resize:function(){b.refresh()}}));if(g=c.background)n=new s.Background[g.type](b,f.extend(g,n)),this.canvases.push(new s.Base[h](n));for(h=this.canvases.length;h--;)this.element.appendChild(this.canvases[h].canvas),h>0&&this.canvases[h].plot();this.element.appendChild(this.labelContainer);j.appendChild(this.element);var i=null,u=this;f.addEvent(window,"scroll",function(){clearTimeout(i);i=setTimeout(function(){u.getPos(!0)},500)})},getCtx:function(a){return this.canvases[a||
68
- 0].getCtx()},getConfig:function(){return this.opt},getElement:function(){return this.element},getSize:function(a){return this.canvases[a||0].getSize()},resize:function(a,b){this.getPos(!0);this.translateOffsetX=this.translateOffsetY=0;this.scaleOffsetX=this.scaleOffsetY=1;for(var c=0,h=this.canvases.length;c<h;c++)this.canvases[c].resize(a,b);c=this.element.style;c.width=a+"px";c.height=b+"px";if(this.labelContainer)this.labelContainer.style.width=a+"px"},translate:function(a,b,c){this.translateOffsetX+=
69
- a*this.scaleOffsetX;this.translateOffsetY+=b*this.scaleOffsetY;for(var h=0,f=this.canvases.length;h<f;h++)this.canvases[h].translate(a,b,c)},scale:function(a,b){var c=this.scaleOffsetX*a,h=this.scaleOffsetY*b,f=this.translateOffsetX*(a-1)/c,j=this.translateOffsetY*(b-1)/h;this.scaleOffsetX=c;this.scaleOffsetY=h;c=0;for(h=this.canvases.length;c<h;c++)this.canvases[c].scale(a,b,!0);this.translate(f,j,!1)},getPos:function(a){if(a||!this.pos)return this.pos=f.getPos(this.getElement());return this.pos},
70
- clear:function(a){this.canvases[a||0].clear()},path:function(a,b){var c=this.canvases[0].getCtx();c.beginPath();b(c);c[a]();c.closePath()},createLabelContainer:function(b,c,g){if(b=="HTML"||b=="Native")return a("div",{id:c,style:{overflow:"visible",position:"absolute",top:0,left:0,width:g.width+"px",height:0}});else if(b=="SVG"){b=document.createElementNS("http://www.w3.org/2000/svg","svg:svg");b.setAttribute("width",g.width);b.setAttribute("height",g.height);var h=b.style;h.position="absolute";h.left=
71
- h.top="0px";h=document.createElementNS("http://www.w3.org/2000/svg","svg:g");h.setAttribute("width",g.width);h.setAttribute("height",g.height);h.setAttribute("x",0);h.setAttribute("y",0);h.setAttribute("id",c);b.appendChild(h);return b}}});s.Base={};s.Base["2D"]=new i({translateOffsetX:0,translateOffsetY:0,scaleOffsetX:1,scaleOffsetY:1,initialize:function(a){this.viz=a;this.opt=a.config;this.size=!1;this.createCanvas();this.translateToCenter()},createCanvas:function(){var b=this.opt,c=b.width,g=b.height;
72
- this.canvas=a("canvas",{id:b.injectInto+b.idSuffix,width:c,height:g,style:{position:"absolute",top:0,left:0,width:c+"px",height:g+"px"}})},getCtx:function(){if(!this.ctx)return this.ctx=this.canvas.getContext("2d");return this.ctx},getSize:function(){if(this.size)return this.size;var a=this.canvas;return this.size={width:a.width,height:a.height}},translateToCenter:function(a){var b=this.getSize(),c=a?b.width-a.width-this.translateOffsetX*2:b.width;height=a?b.height-a.height-this.translateOffsetY*
73
- 2:b.height;b=this.getCtx();a&&b.scale(1/this.scaleOffsetX,1/this.scaleOffsetY);b.translate(c/2,height/2)},resize:function(a,b){var g=this.getSize(),h=this.canvas,f=h.style;this.size=!1;h.width=a;h.height=b;f.width=a+"px";f.height=b+"px";c?this.translateToCenter():this.translateToCenter(g);this.translateOffsetX=this.translateOffsetY=0;this.scaleOffsetX=this.scaleOffsetY=1;this.clear();this.viz.resize(a,b,this)},translate:function(a,b,c){var h=this.scaleOffsetY;this.translateOffsetX+=a*this.scaleOffsetX;
74
- this.translateOffsetY+=b*h;this.getCtx().translate(a,b);!c&&this.plot()},scale:function(a,b,c){this.scaleOffsetX*=a;this.scaleOffsetY*=b;this.getCtx().scale(a,b);!c&&this.plot()},clear:function(){var a=this.getSize(),b=this.translateOffsetX,c=this.translateOffsetY,h=this.scaleOffsetX,f=this.scaleOffsetY;this.getCtx().clearRect((-a.width/2-b)*1/h,(-a.height/2-c)*1/f,a.width*1/h,a.height*1/f)},plot:function(){this.clear();this.viz.plot(this)}});s.Background={};s.Background.Circles=new i({initialize:function(a,
75
- b){this.viz=a;this.config=f.merge({idSuffix:"-bkcanvas",levelDistance:100,numberOfCircles:6,CanvasStyles:{},offset:0},b)},resize:function(a,b,c){this.plot(c)},plot:function(a){var a=a.getCtx(),b=this.config,c=b.CanvasStyles,h;for(h in c)a[h]=c[h];h=b.numberOfCircles;b=b.levelDistance;for(c=1;c<=h;c++)a.beginPath(),a.arc(0,0,b*c,0,2*Math.PI,!1),a.stroke(),a.closePath()}})})();var q=function(a,b){this.theta=a||0;this.rho=b||0};$jit.Polar=q;q.prototype={getc:function(a){return this.toComplex(a)},getp:function(){return this},
76
- set:function(a){a=a.getp();this.theta=a.theta;this.rho=a.rho},setc:function(a,b){this.rho=Math.sqrt(a*a+b*b);this.theta=Math.atan2(b,a);this.theta<0&&(this.theta+=Math.PI*2)},setp:function(a,b){this.theta=a;this.rho=b},clone:function(){return new q(this.theta,this.rho)},toComplex:function(a){var b=Math.cos(this.theta)*this.rho,c=Math.sin(this.theta)*this.rho;if(a)return{x:b,y:c};return new m(b,c)},add:function(a){return new q(this.theta+a.theta,this.rho+a.rho)},scale:function(a){return new q(this.theta,
77
- this.rho*a)},equals:function(a){return this.theta==a.theta&&this.rho==a.rho},$add:function(a){this.theta+=a.theta;this.rho+=a.rho;return this},$madd:function(a){this.theta=(this.theta+a.theta)%(Math.PI*2);this.rho+=a.rho;return this},$scale:function(a){this.rho*=a;return this},isZero:function(){var a=Math.abs;return a(this.theta)<1.0E-4&&a(this.rho)<1.0E-4},interpolate:function(a,b){var c=Math.PI,d=c*2,e=function(a){return a<0?a%d+d:a%d},g=this.theta,h=a.theta,f=Math.abs(g-h);return{theta:f==c?g>
78
- h?e(h+(g-d-h)*b):e(h-d+(g-h)*b):f>=c?g>h?e(h+(g-d-h)*b):e(h-d+(g-(h-d))*b):e(h+(g-h)*b),rho:(this.rho-a.rho)*b+a.rho}}};q.KER=new q(0,0);var m=function(a,b){this.x=a||0;this.y=b||0};$jit.Complex=m;m.prototype={getc:function(){return this},getp:function(a){return this.toPolar(a)},set:function(a){a=a.getc(!0);this.x=a.x;this.y=a.y},setc:function(a,b){this.x=a;this.y=b},setp:function(a,b){this.x=Math.cos(a)*b;this.y=Math.sin(a)*b},clone:function(){return new m(this.x,this.y)},toPolar:function(a){var b=
79
- this.norm(),c=Math.atan2(this.y,this.x);c<0&&(c+=Math.PI*2);if(a)return{theta:c,rho:b};return new q(c,b)},norm:function(){return Math.sqrt(this.squaredNorm())},squaredNorm:function(){return this.x*this.x+this.y*this.y},add:function(a){return new m(this.x+a.x,this.y+a.y)},prod:function(a){return new m(this.x*a.x-this.y*a.y,this.y*a.x+this.x*a.y)},conjugate:function(){return new m(this.x,-this.y)},scale:function(a){return new m(this.x*a,this.y*a)},equals:function(a){return this.x==a.x&&this.y==a.y},
80
- $add:function(a){this.x+=a.x;this.y+=a.y;return this},$prod:function(a){var b=this.x,c=this.y;this.x=b*a.x-c*a.y;this.y=c*a.x+b*a.y;return this},$conjugate:function(){this.y=-this.y;return this},$scale:function(a){this.x*=a;this.y*=a;return this},$div:function(a){var b=this.x,c=this.y,d=a.squaredNorm();this.x=b*a.x+c*a.y;this.y=c*a.x-b*a.y;return this.$scale(1/d)},isZero:function(){var a=Math.abs;return a(this.x)<1.0E-4&&a(this.y)<1.0E-4}};m.KER=new m(0,0);$jit.Graph=new i({initialize:function(a,
81
- b,c,d){var e={klass:m,Node:{}};this.Node=b;this.Edge=c;this.Label=d;this.opt=f.merge(e,a||{});this.nodes={};this.edges={};var g=this;this.nodeList={};for(var h in z)g.nodeList[h]=function(a){return function(){var b=Array.prototype.slice.call(arguments);g.eachNode(function(c){c[a].apply(c,b)})}}(h)},getNode:function(a){if(this.hasNode(a))return this.nodes[a];return!1},get:function(a){return this.getNode(a)},getByName:function(a){for(var b in this.nodes){var c=this.nodes[b];if(c.name==a)return c}return!1},
82
- getAdjacence:function(a,b){if(a in this.edges)return this.edges[a][b];return!1},addNode:function(a){if(!this.nodes[a.id]){var b=this.edges[a.id]={};this.nodes[a.id]=new k.Node(f.extend({id:a.id,name:a.name,data:f.merge(a.data||{},{}),adjacencies:b},this.opt.Node),this.opt.klass,this.Node,this.Edge,this.Label)}return this.nodes[a.id]},addAdjacence:function(a,b,c){this.hasNode(a.id)||this.addNode(a);this.hasNode(b.id)||this.addNode(b);a=this.nodes[a.id];b=this.nodes[b.id];if(!a.adjacentTo(b)){var d=
83
- this.edges[a.id]=this.edges[a.id]||{},e=this.edges[b.id]=this.edges[b.id]||{};d[b.id]=e[a.id]=new k.Adjacence(a,b,c,this.Edge,this.Label);return d[b.id]}return this.edges[a.id][b.id]},removeNode:function(a){if(this.hasNode(a)){delete this.nodes[a];var b=this.edges[a],c;for(c in b)delete this.edges[c][a];delete this.edges[a]}},removeAdjacence:function(a,b){delete this.edges[a][b];delete this.edges[b][a]},hasNode:function(a){return a in this.nodes},empty:function(){this.nodes={};this.edges={}}});var k=
84
- $jit.Graph,z;(function(){var a=function(a,b,c,h,f){var j,c=c||"current";if(c=="current")j=this.data;else if(c=="start")j=this.startData;else if(c=="end")j=this.endData;a="$"+(a?a+"-":"")+b;if(h)return j[a];if(!this.Config.overridable)return f[b]||0;return a in j?j[a]:a in this.data?this.data[a]:f[b]||0},b=function(a,b,c,h){var h=h||"current",f;if(h=="current")f=this.data;else if(h=="start")f=this.startData;else if(h=="end")f=this.endData;f["$"+(a?a+"-":"")+b]=c},c=function(a,b){var a="$"+(a?a+"-":
85
- ""),c=this;f.each(b,function(b){b=a+b;delete c.data[b];delete c.endData[b];delete c.startData[b]})};z={getData:function(b,c,g){return a.call(this,"",b,c,g,this.Config)},setData:function(a,c,g){b.call(this,"",a,c,g)},setDataset:function(a,b){var a=f.splat(a),c;for(c in b)for(var h=0,l=f.splat(b[c]),j=a.length;h<j;h++)this.setData(c,l[h],a[h])},removeData:function(){c.call(this,"",Array.prototype.slice.call(arguments))},getCanvasStyle:function(b,c,g){return a.call(this,"canvas",b,c,g,this.Config.CanvasStyles)},
86
- setCanvasStyle:function(a,c,g){b.call(this,"canvas",a,c,g)},setCanvasStyles:function(a,b){var a=f.splat(a),c;for(c in b)for(var h=0,l=f.splat(b[c]),j=a.length;h<j;h++)this.setCanvasStyle(c,l[h],a[h])},removeCanvasStyle:function(){c.call(this,"canvas",Array.prototype.slice.call(arguments))},getLabelData:function(b,c,g){return a.call(this,"label",b,c,g,this.Label)},setLabelData:function(a,c,g){b.call(this,"label",a,c,g)},setLabelDataset:function(a,b){var a=f.splat(a),c;for(c in b)for(var h=0,l=f.splat(b[c]),
87
- j=a.length;h<j;h++)this.setLabelData(c,l[h],a[h])},removeLabelData:function(){c.call(this,"label",Array.prototype.slice.call(arguments))}}})();k.Node=new i({initialize:function(a,b,c,d,e){b={id:"",name:"",data:{},startData:{},endData:{},adjacencies:{},selected:!1,drawn:!1,exist:!1,angleSpan:{begin:0,end:0},pos:new b,startPos:new b,endPos:new b};f.extend(this,f.extend(b,a));this.Config=this.Node=c;this.Edge=d;this.Label=e},adjacentTo:function(a){return a.id in this.adjacencies},getAdjacency:function(a){return this.adjacencies[a]},
88
- getPos:function(a){a=a||"current";if(a=="current")return this.pos;else if(a=="end")return this.endPos;else if(a=="start")return this.startPos},setPos:function(a,b){var b=b||"current",c;if(b=="current")c=this.pos;else if(b=="end")c=this.endPos;else if(b=="start")c=this.startPos;c.set(a)}});k.Node.implement(z);k.Adjacence=new i({initialize:function(a,b,c,d,e){this.nodeFrom=a;this.nodeTo=b;this.data=c||{};this.startData={};this.endData={};this.Config=this.Edge=d;this.Label=e}});k.Adjacence.implement(z);
89
- k.Util={filter:function(a){if(!a||f.type(a)!="string")return function(){return!0};var b=a.split(" ");return function(a){for(var d=0;d<b.length;d++)if(a[b[d]])return!1;return!0}},getNode:function(a,b){return a.nodes[b]},eachNode:function(a,b,c){var c=this.filter(c),d;for(d in a.nodes)c(a.nodes[d])&&b(a.nodes[d])},each:function(a,b,c){this.eachNode(a,b,c)},eachAdjacency:function(a,b,c){var d=a.adjacencies,c=this.filter(c),e;for(e in d){var g=d[e];if(c(g)){if(g.nodeFrom!=a){var h=g.nodeFrom;g.nodeFrom=
90
- g.nodeTo;g.nodeTo=h}b(g,e)}}},computeLevels:function(a,b,c,d){var c=c||0,e=this.filter(d);this.eachNode(a,function(a){a._flag=!1;a._depth=-1},d);a=a.getNode(b);a._depth=c;for(var g=[a];g.length!=0;){var h=g.pop();h._flag=!0;this.eachAdjacency(h,function(a){a=a.nodeTo;if(a._flag==!1&&e(a)){if(a._depth<0)a._depth=h._depth+1+c;g.unshift(a)}},d)}},eachBFS:function(a,b,c,d){var e=this.filter(d);this.clean(a);for(var g=[a.getNode(b)];g.length!=0;)a=g.pop(),a._flag=!0,c(a,a._depth),this.eachAdjacency(a,
91
- function(a){a=a.nodeTo;if(a._flag==!1&&e(a))a._flag=!0,g.unshift(a)},d)},eachLevel:function(a,b,c,d,e){var g=a._depth,h=this.filter(e),f=this,c=c===!1?Number.MAX_VALUE-g:c;(function t(a,b,c){var e=a._depth;e>=b&&e<=c&&h(a)&&d(a,e);e<c&&f.eachAdjacency(a,function(a){a=a.nodeTo;a._depth>e&&t(a,b,c)})})(a,b+g,c+g)},eachSubgraph:function(a,b,c){this.eachLevel(a,0,!1,b,c)},eachSubnode:function(a,b,c){this.eachLevel(a,1,1,b,c)},anySubnode:function(a,b,c){var d=!1,b=b||f.lambda(!0),e=f.type(b)=="string"?
92
- function(a){return a[b]}:b;this.eachSubnode(a,function(a){e(a)&&(d=!0)},c);return d},getSubnodes:function(a,b,c){var d=[],b=b||0,e;f.type(b)=="array"?(e=b[0],b=b[1]):(e=b,b=Number.MAX_VALUE-a._depth);this.eachLevel(a,e,b,function(a){d.push(a)},c);return d},getParents:function(a){var b=[];this.eachAdjacency(a,function(c){c=c.nodeTo;c._depth<a._depth&&b.push(c)});return b},isDescendantOf:function(a,b){if(a.id==b)return!0;for(var c=this.getParents(a),d=!1,e=0;!d&&e<c.length;e++)d=d||this.isDescendantOf(c[e],
93
- b);return d},clean:function(a){this.eachNode(a,function(a){a._flag=!1})},getClosestNodeToOrigin:function(a,b,c){return this.getClosestNodeToPos(a,q.KER,b,c)},getClosestNodeToPos:function(a,b,c,d){var e=null,c=c||"current",b=b&&b.getc(!0)||m.KER,g=function(a,b){var c=a.x-b.x,d=a.y-b.y;return c*c+d*d};this.eachNode(a,function(a){e=e==null||g(a.getPos(c).getc(!0),b)<g(e.getPos(c).getc(!0),b)?a:e},d);return e}};f.each(["get","getNode","each","eachNode","computeLevels","eachBFS","clean","getClosestNodeToPos",
94
- "getClosestNodeToOrigin"],function(a){k.prototype[a]=function(){return k.Util[a].apply(k.Util,[this].concat(Array.prototype.slice.call(arguments)))}});f.each(["eachAdjacency","eachLevel","eachSubgraph","eachSubnode","anySubnode","getSubnodes","getParents","isDescendantOf"],function(a){k.Node.prototype[a]=function(){return k.Util[a].apply(k.Util,[this].concat(Array.prototype.slice.call(arguments)))}});k.Op={options:{type:"nothing",duration:2E3,hideLabels:!0,fps:30},initialize:function(a){this.viz=
95
- a},removeNode:function(a,b){var c=this.viz,d=f.merge(this.options,c.controller,b),e=f.splat(a),g,h,l;switch(d.type){case "nothing":for(g=0;g<e.length;g++)c.graph.removeNode(e[g]);break;case "replot":this.removeNode(e,{type:"nothing"});c.labels.clearLabels();c.refresh(!0);break;case "fade:seq":case "fade":h=this;for(g=0;g<e.length;g++)l=c.graph.getNode(e[g]),l.setData("alpha",0,"end");c.fx.animate(f.merge(d,{modes:["node-property:alpha"],onComplete:function(){h.removeNode(e,{type:"nothing"});c.labels.clearLabels();
96
- c.reposition();c.fx.animate(f.merge(d,{modes:["linear"]}))}}));break;case "fade:con":h=this;for(g=0;g<e.length;g++)l=c.graph.getNode(e[g]),l.setData("alpha",0,"end"),l.ignore=!0;c.reposition();c.fx.animate(f.merge(d,{modes:["node-property:alpha","linear"],onComplete:function(){h.removeNode(e,{type:"nothing"});d.onComplete&&d.onComplete()}}));break;case "iter":h=this;c.fx.sequence({condition:function(){return e.length!=0},step:function(){h.removeNode(e.shift(),{type:"nothing"});c.labels.clearLabels()},
97
- onComplete:function(){d.onComplete&&d.onComplete()},duration:Math.ceil(d.duration/e.length)});break;default:this.doError()}},removeEdge:function(a,b){var c=this.viz,d=f.merge(this.options,c.controller,b),e=f.type(a[0])=="string"?[a]:a,g,h,l;switch(d.type){case "nothing":for(g=0;g<e.length;g++)c.graph.removeAdjacence(e[g][0],e[g][1]);break;case "replot":this.removeEdge(e,{type:"nothing"});c.refresh(!0);break;case "fade:seq":case "fade":h=this;for(g=0;g<e.length;g++)(l=c.graph.getAdjacence(e[g][0],
98
- e[g][1]))&&l.setData("alpha",0,"end");c.fx.animate(f.merge(d,{modes:["edge-property:alpha"],onComplete:function(){h.removeEdge(e,{type:"nothing"});c.reposition();c.fx.animate(f.merge(d,{modes:["linear"]}))}}));break;case "fade:con":h=this;for(g=0;g<e.length;g++)if(l=c.graph.getAdjacence(e[g][0],e[g][1]))l.setData("alpha",0,"end"),l.ignore=!0;c.reposition();c.fx.animate(f.merge(d,{modes:["edge-property:alpha","linear"],onComplete:function(){h.removeEdge(e,{type:"nothing"});d.onComplete&&d.onComplete()}}));
99
- break;case "iter":h=this;c.fx.sequence({condition:function(){return e.length!=0},step:function(){h.removeEdge(e.shift(),{type:"nothing"});c.labels.clearLabels()},onComplete:function(){d.onComplete()},duration:Math.ceil(d.duration/e.length)});break;default:this.doError()}},sum:function(a,b){var c=this.viz,d=f.merge(this.options,c.controller,b),e=c.root,g;c.root=b.id||c.root;switch(d.type){case "nothing":g=c.construct(a);g.eachNode(function(a){a.eachAdjacency(function(a){c.graph.addAdjacence(a.nodeFrom,
100
- a.nodeTo,a.data)})});break;case "replot":c.refresh(!0);this.sum(a,{type:"nothing"});c.refresh(!0);break;case "fade:seq":case "fade":case "fade:con":that=this;g=c.construct(a);var h=!this.preprocessSum(g)?["node-property:alpha"]:["node-property:alpha","edge-property:alpha"];c.reposition();d.type!="fade:con"?c.fx.animate(f.merge(d,{modes:["linear"],onComplete:function(){c.fx.animate(f.merge(d,{modes:h,onComplete:function(){d.onComplete()}}))}})):(c.graph.eachNode(function(a){a.id!=e&&a.pos.isZero()&&
101
- (a.pos.set(a.endPos),a.startPos.set(a.endPos))}),c.fx.animate(f.merge(d,{modes:["linear"].concat(h)})));break;default:this.doError()}},morph:function(a,b,c){var c=c||{},d=this.viz,e=f.merge(this.options,d.controller,b),g=d.root,h;d.root=b.id||d.root;switch(e.type){case "nothing":h=d.construct(a);h.eachNode(function(a){var b=d.graph.hasNode(a.id);a.eachAdjacency(function(a){var b=!!d.graph.getAdjacence(a.nodeFrom.id,a.nodeTo.id);d.graph.addAdjacence(a.nodeFrom,a.nodeTo,a.data);if(b){var b=d.graph.getAdjacence(a.nodeFrom.id,
102
- a.nodeTo.id),c;for(c in a.data||{})b.data[c]=a.data[c]}});if(b){var b=d.graph.getNode(a.id),c;for(c in a.data||{})b.data[c]=a.data[c]}});d.graph.eachNode(function(a){a.eachAdjacency(function(a){h.getAdjacence(a.nodeFrom.id,a.nodeTo.id)||d.graph.removeAdjacence(a.nodeFrom.id,a.nodeTo.id)});h.hasNode(a.id)||d.graph.removeNode(a.id)});break;case "replot":d.labels.clearLabels(!0);this.morph(a,{type:"nothing"});d.refresh(!0);d.refresh(!0);break;case "fade:seq":case "fade":case "fade:con":that=this;h=d.construct(a);
103
- var l="node-property"in c&&f.map(f.splat(c["node-property"]),function(a){return"$"+a});d.graph.eachNode(function(a){var b=h.getNode(a.id);if(b){var b=b.data,c;for(c in b)l&&f.indexOf(l,c)>-1?a.endData[c]=b[c]:a.data[c]=b[c]}else a.setData("alpha",1),a.setData("alpha",1,"start"),a.setData("alpha",0,"end"),a.ignore=!0});d.graph.eachNode(function(a){a.ignore||a.eachAdjacency(function(a){if(!a.nodeFrom.ignore&&!a.nodeTo.ignore){var b=h.getNode(a.nodeFrom.id),a=h.getNode(a.nodeTo.id);b.adjacentTo(a)||
104
- (a=d.graph.getAdjacence(b.id,a.id),j=!0,a.setData("alpha",1),a.setData("alpha",1,"start"),a.setData("alpha",0,"end"))}})});var j=this.preprocessSum(h),a=!j?["node-property:alpha"]:["node-property:alpha","edge-property:alpha"];a[0]+="node-property"in c?":"+f.splat(c["node-property"]).join(":"):"";a[1]=(a[1]||"edge-property:alpha")+("edge-property"in c?":"+f.splat(c["edge-property"]).join(":"):"");"label-property"in c&&a.push("label-property:"+f.splat(c["label-property"]).join(":"));d.reposition?d.reposition():
105
- d.compute("end");d.graph.eachNode(function(a){a.id!=g&&a.pos.getp().equals(q.KER)&&(a.pos.set(a.endPos),a.startPos.set(a.endPos))});d.fx.animate(f.merge(e,{modes:[c.position||"polar"].concat(a),onComplete:function(){d.graph.eachNode(function(a){a.ignore&&d.graph.removeNode(a.id)});d.graph.eachNode(function(a){a.eachAdjacency(function(a){a.ignore&&d.graph.removeAdjacence(a.nodeFrom.id,a.nodeTo.id)})});e.onComplete()}}))}},contract:function(a,b){var c=this.viz;if(!a.collapsed&&a.anySubnode(f.lambda(!0)))b=
106
- f.merge(this.options,c.config,b||{},{modes:["node-property:alpha:span","linear"]}),a.collapsed=!0,function e(a){a.eachSubnode(function(a){a.ignore=!0;a.setData("alpha",0,b.type=="animate"?"end":"current");e(a)})}(a),b.type=="animate"?(c.compute("end"),c.rotated&&c.rotate(c.rotated,"none",{property:"end"}),function g(b){b.eachSubnode(function(b){b.setPos(a.getPos("end"),"end");g(b)})}(a),c.fx.animate(b)):b.type=="replot"&&c.refresh()},expand:function(a,b){if("collapsed"in a){var c=this.viz,b=f.merge(this.options,
107
- c.config,b||{},{modes:["node-property:alpha:span","linear"]});delete a.collapsed;(function e(a){a.eachSubnode(function(a){delete a.ignore;a.setData("alpha",1,b.type=="animate"?"end":"current");e(a)})})(a);b.type=="animate"?(c.compute("end"),c.rotated&&c.rotate(c.rotated,"none",{property:"end"}),c.fx.animate(b)):b.type=="replot"&&c.refresh()}},preprocessSum:function(a){var b=this.viz;a.eachNode(function(a){b.graph.hasNode(a.id)||(b.graph.addNode(a),a=b.graph.getNode(a.id),a.setData("alpha",0),a.setData("alpha",
108
- 0,"start"),a.setData("alpha",1,"end"))});var c=!1;a.eachNode(function(a){a.eachAdjacency(function(a){var d=b.graph.getNode(a.nodeFrom.id),h=b.graph.getNode(a.nodeTo.id);d.adjacentTo(h)||(a=b.graph.addAdjacence(d,h,a.data),d.startAlpha==d.endAlpha&&h.startAlpha==h.endAlpha&&(c=!0,a.setData("alpha",0),a.setData("alpha",0,"start"),a.setData("alpha",1,"end")))})});return c}};var A={none:{render:f.empty,contains:f.lambda(!1)},circle:{render:function(a,b,c,d){d=d.getCtx();d.beginPath();d.arc(b.x,b.y,c,
109
- 0,Math.PI*2,!0);d.closePath();d[a]()},contains:function(a,b,c){var d=a.x-b.x,a=a.y-b.y;return d*d+a*a<=c*c}},ellipse:{render:function(a,b,c,d,e){var e=e.getCtx(),g=1,h=1,f=1,j=1,t=0;c>d?(t=c/2,h=d/c,j=c/d):(t=d/2,g=c/d,f=d/c);e.save();e.scale(g,h);e.beginPath();e.arc(b.x*f,b.y*j,t,0,Math.PI*2,!0);e.closePath();e[a]();e.restore()},contains:function(a,b,c,d){var e=0,g=1,h=1,f=0,j=0,e=0;c>d?(e=c/2,h=d/c):(e=d/2,g=c/d);f=(a.x-b.x)*(1/g);j=(a.y-b.y)*(1/h);return f*f+j*j<=e*e}},square:{render:function(a,
110
- b,c,d){d.getCtx()[a+"Rect"](b.x-c,b.y-c,2*c,2*c)},contains:function(a,b,c){return Math.abs(b.x-a.x)<=c&&Math.abs(b.y-a.y)<=c}},rectangle:{render:function(a,b,c,d,e){e.getCtx()[a+"Rect"](b.x-c/2,b.y-d/2,c,d)},contains:function(a,b,c,d){return Math.abs(b.x-a.x)<=c/2&&Math.abs(b.y-a.y)<=d/2}},triangle:{render:function(a,b,c,d){var d=d.getCtx(),e=b.x,g=b.y-c,f=e-c,b=b.y+c,c=e+c;d.beginPath();d.moveTo(e,g);d.lineTo(f,b);d.lineTo(c,b);d.closePath();d[a]()},contains:function(a,b,c){return A.circle.contains(a,
111
- b,c)}},star:{render:function(a,b,c,d){var d=d.getCtx(),e=Math.PI/5;d.save();d.translate(b.x,b.y);d.beginPath();d.moveTo(c,0);for(b=0;b<9;b++)d.rotate(e),b%2==0?d.lineTo(c/0.525731*0.200811,0):d.lineTo(c,0);d.closePath();d[a]();d.restore()},contains:function(a,b,c){return A.circle.contains(a,b,c)}}},D={line:{render:function(a,b,c){c=c.getCtx();c.beginPath();c.moveTo(a.x,a.y);c.lineTo(b.x,b.y);c.stroke()},contains:function(a,b,c,d){var e=Math.min,g=Math.max,f=e(a.x,b.x),l=g(a.x,b.x),e=e(a.y,b.y),g=
112
- g(a.y,b.y);if(c.x>=f&&c.x<=l&&c.y>=e&&c.y<=g){if(Math.abs(b.x-a.x)<=d)return!0;return Math.abs((b.y-a.y)/(b.x-a.x)*(c.x-a.x)+a.y-c.y)<=d}return!1}},arrow:{render:function(a,b,c,d,e){e=e.getCtx();d&&(d=a,a=b,b=d);d=new m(b.x-a.x,b.y-a.y);d.$scale(c/d.norm());var c=new m(b.x-d.x,b.y-d.y),g=new m(-d.y/2,d.x/2),d=c.add(g),c=c.$add(g.$scale(-1));e.beginPath();e.moveTo(a.x,a.y);e.lineTo(b.x,b.y);e.stroke();e.beginPath();e.moveTo(d.x,d.y);e.lineTo(c.x,c.y);e.lineTo(b.x,b.y);e.closePath();e.fill()},contains:function(a,
113
- b,c,d){return D.line.contains(a,b,c,d)}},hyperline:{render:function(a,b,c,d){function e(a,b){return a<b?a+Math.PI>b?!1:!0:b+Math.PI>a?!0:!1}var d=d.getCtx(),g=function(a,b){var c=a.x*b.y-a.y*b.x,d=a.squaredNorm(),e=b.squaredNorm();if(c==0)return{x:0,y:0,ratio:-1};var g=(a.y*e-b.y*d+a.y-b.y)/c,c=(b.x*d-a.x*e+b.x-a.x)/c,d=(g*g+c*c)/4-1;if(d<0)return{x:0,y:0,ratio:-1};d=Math.sqrt(d);return{x:-g/2,y:-c/2,ratio:d>1E3?-1:d,a:g,b:c}}(a,b);g.a>1E3||g.b>1E3||g.ratio<0?(d.beginPath(),d.moveTo(a.x*c,a.y*c),
114
- d.lineTo(b.x*c,b.y*c)):(b=Math.atan2(b.y-g.y,b.x-g.x),a=Math.atan2(a.y-g.y,a.x-g.x),e=e(b,a),d.beginPath(),d.arc(g.x*c,g.y*c,g.ratio*c,b,a,e));d.stroke()},contains:f.lambda(!1)}};k.Plot={initialize:function(a,b){this.viz=a;this.config=a.config;this.node=a.config.Node;this.edge=a.config.Edge;this.animation=new B;this.nodeTypes=new b.Plot.NodeTypes;this.edgeTypes=new b.Plot.EdgeTypes;this.labels=a.labels},nodeHelper:A,edgeHelper:D,Interpolator:{map:{border:"color",color:"color",width:"number",height:"number",
115
- dim:"number",alpha:"number",lineWidth:"number",angularWidth:"number",span:"number",valueArray:"array-number",dimArray:"array-number"},canvas:{globalAlpha:"number",fillStyle:"color",strokeStyle:"color",lineWidth:"number",shadowBlur:"number",shadowColor:"color",shadowOffsetX:"number",shadowOffsetY:"number",miterLimit:"number"},label:{size:"number",color:"color"},compute:function(a,b,c){return a+(b-a)*c},moebius:function(a,b,c,d){b=d.scale(-c);if(b.norm()<1){var c=b.x,d=b.y,e=a.startPos.getc().moebiusTransformation(b);
116
- a.pos.setc(e.x,e.y);b.x=c;b.y=d}},linear:function(a,b,c){var b=a.startPos.getc(!0),d=a.endPos.getc(!0);a.pos.setc(this.compute(b.x,d.x,c),this.compute(b.y,d.y,c))},polar:function(a,b,c){b=a.startPos.getp(!0);c=a.endPos.getp().interpolate(b,c);a.pos.setp(c.theta,c.rho)},number:function(a,b,c,d,e){var g=a[d](b,"start"),d=a[d](b,"end");a[e](b,this.compute(g,d,c))},color:function(a,b,c,d,e){var g=f.hexToRgb(a[d](b,"start")),d=f.hexToRgb(a[d](b,"end")),h=this.compute,c=f.rgbToHex([parseInt(h(g[0],d[0],
117
- c)),parseInt(h(g[1],d[1],c)),parseInt(h(g[2],d[2],c))]);a[e](b,c)},"array-number":function(a,b,c,d,e){for(var g=a[d](b,"start"),d=a[d](b,"end"),f=[],l=0,j=g.length;l<j;l++){var t=g[l],i=d[l];if(t.length){for(var n=0,k=t.length,u=[];n<k;n++)u.push(this.compute(t[n],i[n],c));f.push(u)}else f.push(this.compute(t,i,c))}a[e](b,f)},node:function(a,b,c,d,e,g){d=this[d];if(b)for(var f=b.length,l=0;l<f;l++){var j=b[l];this[d[j]](a,j,c,e,g)}else for(j in d)this[d[j]](a,j,c,e,g)},edge:function(a,b,c,d,e,g){var a=
118
- a.adjacencies,f;for(f in a)this.node(a[f],b,c,d,e,g)},"node-property":function(a,b,c){this.node(a,b,c,"map","getData","setData")},"edge-property":function(a,b,c){this.edge(a,b,c,"map","getData","setData")},"label-property":function(a,b,c){this.node(a,b,c,"label","getLabelData","setLabelData")},"node-style":function(a,b,c){this.node(a,b,c,"canvas","getCanvasStyle","setCanvasStyle")},"edge-style":function(a,b,c){this.edge(a,b,c,"canvas","getCanvasStyle","setCanvasStyle")}},sequence:function(a){var b=
119
- this,a=f.merge({condition:f.lambda(!1),step:f.empty,onComplete:f.empty,duration:200},a||{}),c=setInterval(function(){a.condition()?a.step():(clearInterval(c),a.onComplete());b.viz.refresh(!0)},a.duration)},prepare:function(a){var b=this.viz.graph,c={"node-property":{getter:"getData",setter:"setData"},"edge-property":{getter:"getData",setter:"setData"},"node-style":{getter:"getCanvasStyle",setter:"setCanvasStyle"},"edge-style":{getter:"getCanvasStyle",setter:"setCanvasStyle"}},d={};if(f.type(a)=="array")for(var e=
120
- 0,g=a.length;e<g;e++){var h=a[e].split(":");d[h.shift()]=h}else for(e in a)e=="position"?d[a.position]=[]:d[e]=f.splat(a[e]);b.eachNode(function(a){a.startPos.set(a.pos);f.each(["node-property","node-style"],function(b){if(b in d)for(var e=d[b],g=0,f=e.length;g<f;g++)a[c[b].setter](e[g],a[c[b].getter](e[g]),"start")});f.each(["edge-property","edge-style"],function(b){if(b in d){var e=d[b];a.eachAdjacency(function(a){for(var d=0,g=e.length;d<g;d++)a[c[b].setter](e[d],a[c[b].getter](e[d]),"start")})}})});
121
- return d},animate:function(a,b){var a=f.merge(this.viz.config,a||{}),c=this,d=this.viz.graph,e=this.Interpolator,g=a.type==="nodefx"?this.nodeFxAnimation:this.animation,h=this.prepare(a.modes);a.hideLabels&&this.labels.hideLabels(!0);g.setOptions(f.extend(a,{$animating:!1,compute:function(g){d.eachNode(function(a){for(var c in h)e[c](a,h[c],g,b)});c.plot(a,this.$animating,g);this.$animating=!0},complete:function(){a.hideLabels&&c.labels.hideLabels(!1);c.plot(a);a.onComplete()}})).start()},nodeFx:function(a){var b=
122
- this.viz,c=b.graph,d=this.nodeFxAnimation,e=f.merge(this.viz.config,{elements:{id:!1,properties:{}},reposition:!1}),a=f.merge(e,a||{},{onBeforeCompute:f.empty,onAfterCompute:f.empty});d.stopTimer();var g=a.elements.properties;a.elements.id?(d=f.splat(a.elements.id),f.each(d,function(a){if(a=c.getNode(a))for(var b in g)a.setData(b,g[b],"end")})):c.eachNode(function(a){for(var b in g)a.setData(b,g[b],"end")});var d=[],h;for(h in g)d.push(h);h=["node-property:"+d.join(":")];a.reposition&&(h.push("linear"),
123
- b.compute("end"));this.animate(f.merge(a,{modes:h,type:"nodefx"}))},plot:function(a,b){var c=this.viz,d=c.graph,e=c.canvas,c=c.root,g=this;e.getCtx();a=a||this.viz.controller;a.clearCanvas&&e.clear();if(c=d.getNode(c)){var f=!!c.visited;d.eachNode(function(c){var d=c.getData("alpha");c.eachAdjacency(function(d){var j=d.nodeTo;!!j.visited===f&&c.drawn&&j.drawn&&(!b&&a.onBeforePlotLine(d),g.plotLine(d,e,b),!b&&a.onAfterPlotLine(d))});c.drawn&&(!b&&a.onBeforePlotNode(c),g.plotNode(c,e,b),!b&&a.onAfterPlotNode(c));
124
- !g.labelsHidden&&a.withLabels&&(c.drawn&&d>=0.95?g.labels.plotLabel(e,c,a):g.labels.hideLabel(c,!1));c.visited=!f})}},plotTree:function(a,b,c){var d=this,e=this.viz.canvas;e.getCtx();var g=a.getData("alpha");a.eachSubnode(function(g){if(b.plotSubtree(a,g)&&g.exist&&g.drawn){var f=a.getAdjacency(g.id);!c&&b.onBeforePlotLine(f);d.plotLine(f,e,c);!c&&b.onAfterPlotLine(f);d.plotTree(g,b,c)}});a.drawn?(!c&&b.onBeforePlotNode(a),this.plotNode(a,e,c),!c&&b.onAfterPlotNode(a),!b.hideLabels&&b.withLabels&&
125
- g>=0.95?this.labels.plotLabel(e,a,b):this.labels.hideLabel(a,!1)):this.labels.hideLabel(a,!0)},plotNode:function(a,b,c){var d=a.getData("type"),e=this.node.CanvasStyles;if(d!="none"){var g=a.getData("lineWidth"),f=a.getData("color"),l=a.getData("alpha"),j=b.getCtx();j.save();j.lineWidth=g;j.fillStyle=j.strokeStyle=f;j.globalAlpha=l;for(var i in e)j[i]=a.getCanvasStyle(i);this.nodeTypes[d].render.call(this,a,b,c);j.restore()}},plotLine:function(a,b,c){var d=a.getData("type"),e=this.edge.CanvasStyles;
126
- if(d!="none"){var g=a.getData("lineWidth"),f=a.getData("color"),l=b.getCtx(),j=a.nodeFrom,i=a.nodeTo;l.save();l.lineWidth=g;l.fillStyle=l.strokeStyle=f;l.globalAlpha=Math.min(j.getData("alpha"),i.getData("alpha"),a.getData("alpha"));for(var k in e)l[k]=a.getCanvasStyle(k);this.edgeTypes[d].render.call(this,a,b,c);l.restore()}}};k.Plot3D=f.merge(k.Plot,{Interpolator:{linear:function(a,b,c){var b=a.startPos.getc(!0),d=a.endPos.getc(!0);a.pos.setc(this.compute(b.x,d.x,c),this.compute(b.y,d.y,c),this.compute(b.z,
127
- d.z,c))}},plotNode:function(a,b){a.getData("type")!="none"&&this.plotElement(a,b,{getAlpha:function(){return a.getData("alpha")}})},plotLine:function(a,b){a.getData("type")!="none"&&this.plotElement(a,b,{getAlpha:function(){return Math.min(a.nodeFrom.getData("alpha"),a.nodeTo.getData("alpha"),a.getData("alpha"))}})},plotElement:function(a,b,c){var d=b.getCtx(),e=new Matrix4,g=b.config.Scene.Lighting,h=b.canvases[0],b=h.program,h=h.camera;if(!a.geometry)a.geometry=new (O3D[a.getData("type")]);a.geometry.update(a);
128
- if(!a.webGLVertexBuffer){for(var l=[],j=[],i=[],k=0,n=a.geometry,m=0,u=n.vertices,n=n.faces,q=n.length;m<q;m++){var p=n[m],o=u[p.a],s=u[p.b],r=u[p.c],x=p.d?u[p.d]:!1,p=p.normal;l.push(o.x,o.y,o.z);l.push(s.x,s.y,s.z);l.push(r.x,r.y,r.z);x&&l.push(x.x,x.y,x.z);i.push(p.x,p.y,p.z);i.push(p.x,p.y,p.z);i.push(p.x,p.y,p.z);x&&i.push(p.x,p.y,p.z);j.push(k,k+1,k+2);x?(j.push(k,k+2,k+3),k+=4):k+=3}a.webGLVertexBuffer=d.createBuffer();d.bindBuffer(d.ARRAY_BUFFER,a.webGLVertexBuffer);d.bufferData(d.ARRAY_BUFFER,
129
- new Float32Array(l),d.STATIC_DRAW);a.webGLFaceBuffer=d.createBuffer();d.bindBuffer(d.ELEMENT_ARRAY_BUFFER,a.webGLFaceBuffer);d.bufferData(d.ELEMENT_ARRAY_BUFFER,new Uint16Array(j),d.STATIC_DRAW);a.webGLFaceCount=j.length;a.webGLNormalBuffer=d.createBuffer();d.bindBuffer(d.ARRAY_BUFFER,a.webGLNormalBuffer);d.bufferData(d.ARRAY_BUFFER,new Float32Array(i),d.STATIC_DRAW)}e.multiply(h.matrix,a.geometry.matrix);d.uniformMatrix4fv(b.viewMatrix,!1,e.flatten());d.uniformMatrix4fv(b.projectionMatrix,!1,h.projectionMatrix.flatten());
130
- e=Matrix4.makeInvert(e);e.$transpose();d.uniformMatrix4fv(b.normalMatrix,!1,e.flatten());e=f.hexToRgb(a.getData("color"));e.push(c.getAlpha());d.uniform4f(b.color,e[0]/255,e[1]/255,e[2]/255,e[3]);d.uniform1i(b.enableLighting,g.enable);if(g.enable){if(g.ambient)c=g.ambient,d.uniform3f(b.ambientColor,c[0],c[1],c[2]);if(g.directional)g=g.directional,e=g.color,g=g.direction,g=(new Vector3(g.x,g.y,g.z)).normalize().$scale(-1),d.uniform3f(b.lightingDirection,g.x,g.y,g.z),d.uniform3f(b.directionalColor,
131
- e[0],e[1],e[2])}d.bindBuffer(d.ARRAY_BUFFER,a.webGLVertexBuffer);d.vertexAttribPointer(b.position,3,d.FLOAT,!1,0,0);d.bindBuffer(d.ARRAY_BUFFER,a.webGLNormalBuffer);d.vertexAttribPointer(b.normal,3,d.FLOAT,!1,0,0);d.bindBuffer(d.ELEMENT_ARRAY_BUFFER,a.webGLFaceBuffer);d.drawElements(d.TRIANGLES,a.webGLFaceCount,d.UNSIGNED_SHORT,0)}});k.Label={};k.Label.Native=new i({initialize:function(a){this.viz=a},plotLabel:function(a,b,c){var d=a.getCtx();b.pos.getc(!0);d.font=b.getLabelData("style")+" "+b.getLabelData("size")+
132
- "px "+b.getLabelData("family");d.textAlign=b.getLabelData("textAlign");d.fillStyle=d.strokeStyle=b.getLabelData("color");d.textBaseline=b.getLabelData("textBaseline");this.renderLabel(a,b,c)},renderLabel:function(a,b){var c=a.getCtx(),d=b.pos.getc(!0);c.fillText(b.name,d.x,d.y+b.getData("height")/2)},hideLabel:f.empty,hideLabels:f.empty});k.Label.DOM=new i({labelsHidden:!1,labelContainer:!1,labels:{},getLabelContainer:function(){return this.labelContainer?this.labelContainer:this.labelContainer=document.getElementById(this.viz.config.labelContainer)},
133
- getLabel:function(a){return a in this.labels&&this.labels[a]!=null?this.labels[a]:this.labels[a]=document.getElementById(a)},hideLabels:function(a){this.getLabelContainer().style.display=a?"none":"";this.labelsHidden=a},clearLabels:function(a){for(var b in this.labels)if(a||!this.viz.graph.hasNode(b))this.disposeLabel(b),delete this.labels[b]},disposeLabel:function(a){(a=this.getLabel(a))&&a.parentNode&&a.parentNode.removeChild(a)},hideLabel:function(a,b){var a=f.splat(a),c=b?"":"none",d=this;f.each(a,
134
- function(a){if(a=d.getLabel(a.id))a.style.display=c})},fitsInCanvas:function(a,b){var c=b.getSize();if(a.x>=c.width||a.x<0||a.y>=c.height||a.y<0)return!1;return!0}});k.Label.HTML=new i({Implements:k.Label.DOM,plotLabel:function(a,b,c){var a=b.id,d=this.getLabel(a);if(!d&&!(d=document.getElementById(a))){var d=document.createElement("div"),e=this.getLabelContainer();d.id=a;d.className="node";d.style.position="absolute";c.onCreateLabel(d,b);e.appendChild(d);this.labels[b.id]=d}this.placeLabel(d,b,c)}});
135
- k.Label.SVG=new i({Implements:k.Label.DOM,plotLabel:function(a,b,c){var a=b.id,d=this.getLabel(a);if(!d&&!(d=document.getElementById(a))){var d=document.createElementNS("http://www.w3.org/2000/svg","svg:text"),e=document.createElementNS("http://www.w3.org/2000/svg","svg:tspan");d.appendChild(e);e=this.getLabelContainer();d.setAttribute("id",a);d.setAttribute("class","node");e.appendChild(d);c.onCreateLabel(d,b);this.labels[b.id]=d}this.placeLabel(d,b,c)}});var r=$jit.Layouts={},F={label:null,compute:function(a,
136
- b,c){this.initializeLabel(c);var d=this.label,e=d.style;a.eachNode(function(a){var b=a.getData("autoWidth"),c=a.getData("autoHeight");if(b||c){delete a.data.$width;delete a.data.$height;delete a.data.$dim;var j=a.getData("width"),i=a.getData("height");e.width=b?"auto":j+"px";e.height=c?"auto":i+"px";d.innerHTML=a.name;b=d.offsetWidth;c=d.offsetHeight;j=a.getData("type");f.indexOf(["circle","square","triangle","star"],j)===-1?(a.setData("width",b),a.setData("height",c)):(b=b>c?b:c,a.setData("width",
137
- b),a.setData("height",b),a.setData("dim",b))}})},initializeLabel:function(a){if(!this.label)this.label=document.createElement("div"),document.body.appendChild(this.label);this.setLabelStyles(a)},setLabelStyles:function(){f.extend(this.label.style,{visibility:"hidden",position:"absolute",width:"auto",height:"auto"});this.label.className="jit-autoadjust-label"}};r.Radial=new i({compute:function(a){a=f.splat(a||["current","start","end"]);F.compute(this.graph,a,this.config);this.graph.computeLevels(this.root,
138
- 0,"ignore");var b=this.createLevelDistanceFunc();this.computeAngularWidths(a);this.computePositions(a,b)},computePositions:function(a,b){for(var c=this.graph,d=c.getNode(this.root),e=this.parent,g=0,f=a.length;g<f;g++){var i=a[g];d.setPos(new q(0,0),i);d.setData("span",Math.PI*2,i)}d.angleSpan={begin:0,end:2*Math.PI};c.eachBFS(this.root,function(c){var d=c.angleSpan.end-c.angleSpan.begin,g=c.angleSpan.begin,f=b(c),h=0,i=[],l={};c.eachSubnode(function(b){h+=b._treeAngularWidth;for(var c=0,d=a.length;c<
139
- d;c++){var e=a[c],g=b.getData("dim",e);l[e]=e in l?g>l[e]?g:l[e]:g}i.push(b)},"ignore");e&&e.id==c.id&&i.length>0&&i[0].dist&&i.sort(function(a,b){return(a.dist>=b.dist)-(a.dist<=b.dist)});for(var c=0,k=i.length;c<k;c++){var m=i[c];if(!m._flag){for(var o=m._treeAngularWidth/h*d,s=g+o/2,r=0,w=a.length;r<w;r++){var v=a[r];m.setPos(new q(s,f),v);m.setData("span",o,v);m.setData("dim-quotient",m.getData("dim",v)/l[v],v)}m.angleSpan={begin:g,end:g+o};g+=o}}},"ignore")},setAngularWidthForNodes:function(a){this.graph.eachBFS(this.root,
140
- function(b,c){var d=b.getData("angularWidth",a[0])||5;b._angularWidth=d/c},"ignore")},setSubtreesAngularWidth:function(){var a=this;this.graph.eachNode(function(b){a.setSubtreeAngularWidth(b)},"ignore")},setSubtreeAngularWidth:function(a){var b=this,c=a._angularWidth,d=0;a.eachSubnode(function(a){b.setSubtreeAngularWidth(a);d+=a._treeAngularWidth},"ignore");a._treeAngularWidth=Math.max(c,d)},computeAngularWidths:function(a){this.setAngularWidthForNodes(a);this.setSubtreesAngularWidth()}});$jit.RGraph=
141
- new i({Implements:[{construct:function(a){var b=f.type(a)=="array",c=new k(this.graphOptions,this.config.Node,this.config.Edge,this.config.Label);b?function(a,b){for(var c=function(c){for(var g=0,f=b.length;g<f;g++)if(b[g].id==c)return b[g];return a.addNode({id:c,name:c})},h=0,i=b.length;h<i;h++){a.addNode(b[h]);var j=b[h].adjacencies;if(j)for(var k=0,m=j.length;k<m;k++){var n=j[k],o={};if(typeof j[k]!="string")o=f.merge(n.data,{}),n=n.nodeTo;a.addAdjacence(b[h],c(n),o)}}}(c,a):function(a,b){a.addNode(b);
142
- if(b.children)for(var c=0,f=b.children;c<f.length;c++)a.addAdjacence(b,f[c]),arguments.callee(a,f[c])}(c,a);return c},loadJSON:function(a,b){this.json=a;this.labels&&this.labels.clearLabels&&this.labels.clearLabels(!0);this.graph=this.construct(a);this.root=f.type(a)!="array"?a.id:a[b?b:0].id},toJSON:function(a){if((a||"tree")=="tree")var b={},b=function e(a){var b={};b.id=a.id;b.name=a.name;b.data=a.data;var c=[];a.eachSubnode(function(a){c.push(e(a))});b.children=c;return b}(this.graph.getNode(this.root));
143
- else{var b=[],c=!!this.graph.getNode(this.root).visited;this.graph.eachNode(function(a){var g={};g.id=a.id;g.name=a.name;g.data=a.data;var f=[];a.eachAdjacency(function(a){var b=a.nodeTo;if(!!b.visited===c){var e={};e.nodeTo=b.id;e.data=a.data;f.push(e)}});g.adjacencies=f;b.push(g);a.visited=!c})}return b}},w,r.Radial],initialize:function(a){var b=$jit.RGraph,a=this.controller=this.config=f.merge(o("Canvas","Node","Edge","Fx","Controller","Tips","NodeStyles","Events","Navigation","Label"),{interpolation:"linear",
144
- levelDistance:100},a);if(a.useCanvas)this.canvas=a.useCanvas,this.config.labelContainer=this.canvas.id+"-label";else{if(a.background)a.background=f.merge({type:"Circles"},a.background);this.canvas=new s(this,a);this.config.labelContainer=(typeof a.injectInto=="string"?a.injectInto:a.injectInto.id)+"-label"}this.graphOptions={klass:q,Node:{selected:!1,exist:!0,drawn:!0}};this.graph=new k(this.graphOptions,this.config.Node,this.config.Edge);this.labels=new b.Label[a.Label.type](this);this.fx=new b.Plot(this,
145
- b);this.op=new b.Op(this);this.root=this.json=null;this.parent=this.busy=!1;this.initializeExtras()},createLevelDistanceFunc:function(){var a=this.config.levelDistance;return function(b){return(b._depth+1)*a}},refresh:function(){this.compute();this.plot()},reposition:function(){this.compute("end")},plot:function(){this.fx.plot()},getNodeAndParentAngle:function(a){var b=!1,c=this.graph.getNode(a),a=c.getParents();if(a=a.length>0?a[0]:!1)b=a.pos.getc(),c=c.pos.getc(),b=b.add(c.scale(-1)),b=Math.atan2(b.y,
146
- b.x),b<0&&(b+=2*Math.PI);return{parent:a,theta:b}},tagChildren:function(a,b){if(a.angleSpan){var c=[];a.eachAdjacency(function(a){c.push(a.nodeTo)},"ignore");for(var d=c.length,e=0;e<d&&b!=c[e].id;e++);for(var e=(e+1)%d,g=0;b!=c[e].id;e=(e+1)%d)c[e].dist=g++}},onClick:function(a,b){if(this.root!=a&&!this.busy){this.busy=!0;this.root=a;var c=this;this.controller.onBeforeCompute(this.graph.getNode(a));var d=this.getNodeAndParentAngle(a);this.tagChildren(d.parent,a);this.parent=d.parent;this.compute("end");
147
- var e=d.theta-d.parent.endPos.theta;this.graph.eachNode(function(a){a.endPos.set(a.endPos.getp().add(new q(e,0)))});d=this.config.interpolation;b=f.merge({onComplete:f.empty},b||{});this.fx.animate(f.merge({hideLabels:!0,modes:[d]},b,{onComplete:function(){c.busy=!1;b.onComplete()}}))}}});$jit.RGraph.$extend=!0;(function(a){a.Op=new i({Implements:k.Op});a.Plot=new i({Implements:k.Plot});a.Label={};a.Label.Native=new i({Implements:k.Label.Native});a.Label.SVG=new i({Implements:k.Label.SVG,initialize:function(a){this.viz=
148
- a},placeLabel:function(a,c,d){var e=c.pos.getc(!0),g=this.viz.canvas,f=g.translateOffsetX,i=g.translateOffsetY,j=g.scaleOffsetX,k=g.scaleOffsetY,g=g.getSize(),e={x:Math.round(e.x*j+f+g.width/2),y:Math.round(e.y*k+i+g.height/2)};a.setAttribute("x",e.x);a.setAttribute("y",e.y);d.onPlaceLabel(a,c)}});a.Label.HTML=new i({Implements:k.Label.HTML,initialize:function(a){this.viz=a},placeLabel:function(a,c,d){var e=c.pos.getc(!0),f=this.viz.canvas,h=f.translateOffsetX,i=f.translateOffsetY,j=f.scaleOffsetX,
149
- k=f.scaleOffsetY,m=f.getSize(),e={x:Math.round(e.x*j+h+m.width/2),y:Math.round(e.y*k+i+m.height/2)},h=a.style;h.left=e.x+"px";h.top=e.y+"px";h.display=this.fitsInCanvas(e,f)?"":"none";d.onPlaceLabel(a,c)}});a.Plot.NodeTypes=new i({none:{render:f.empty,contains:f.lambda(!1)},circle:{render:function(a,c){var d=a.pos.getc(!0),e=a.getData("dim");this.nodeHelper.circle.render("fill",d,e,c)},contains:function(a,c){var d=a.pos.getc(!0),e=a.getData("dim");return this.nodeHelper.circle.contains(d,c,e)}},ellipse:{render:function(a,
150
- c){var d=a.pos.getc(!0),e=a.getData("width"),f=a.getData("height");this.nodeHelper.ellipse.render("fill",d,e,f,c)},contains:function(a,c){var d=a.pos.getc(!0),e=a.getData("width"),f=a.getData("height");return this.nodeHelper.ellipse.contains(d,c,e,f)}},square:{render:function(a,c){var d=a.pos.getc(!0),e=a.getData("dim");this.nodeHelper.square.render("fill",d,e,c)},contains:function(a,c){var d=a.pos.getc(!0),e=a.getData("dim");return this.nodeHelper.square.contains(d,c,e)}},rectangle:{render:function(a,
151
- c){var d=a.pos.getc(!0),e=a.getData("width"),f=a.getData("height");this.nodeHelper.rectangle.render("fill",d,e,f,c)},contains:function(a,c){var d=a.pos.getc(!0),e=a.getData("width"),f=a.getData("height");return this.nodeHelper.rectangle.contains(d,c,e,f)}},triangle:{render:function(a,c){var d=a.pos.getc(!0),e=a.getData("dim");this.nodeHelper.triangle.render("fill",d,e,c)},contains:function(a,c){var d=a.pos.getc(!0),e=a.getData("dim");return this.nodeHelper.triangle.contains(d,c,e)}},star:{render:function(a,
152
- c){var d=a.pos.getc(!0),e=a.getData("dim");this.nodeHelper.star.render("fill",d,e,c)},contains:function(a,c){var d=a.pos.getc(!0),e=a.getData("dim");return this.nodeHelper.star.contains(d,c,e)}}});a.Plot.EdgeTypes=new i({none:f.empty,line:{render:function(a,c){var d=a.nodeFrom.pos.getc(!0),e=a.nodeTo.pos.getc(!0);this.edgeHelper.line.render(d,e,c)},contains:function(a,c){var d=a.nodeFrom.pos.getc(!0),e=a.nodeTo.pos.getc(!0);return this.edgeHelper.line.contains(d,e,c,this.edge.epsilon)}},arrow:{render:function(a,
153
- c){var d=a.nodeFrom.pos.getc(!0),e=a.nodeTo.pos.getc(!0),f=a.getData("dim"),h=a.data.$direction;this.edgeHelper.arrow.render(d,e,f,h&&h.length>1&&h[0]!=a.nodeFrom.id,c)},contains:function(a,c){var d=a.nodeFrom.pos.getc(!0),e=a.nodeTo.pos.getc(!0);return this.edgeHelper.arrow.contains(d,e,c,this.edge.epsilon)}}})})($jit.RGraph)})();