@datagrok/helm 2.3.2 → 2.3.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (324) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/dist/package-test.js +1 -1
  3. package/dist/package-test.js.map +1 -1
  4. package/dist/package.js +1 -1
  5. package/dist/package.js.map +1 -1
  6. package/package.json +4 -4
  7. package/src/cell-renderer.ts +5 -4
  8. package/src/helm-helper.ts +6 -6
  9. package/src/helm-monomer-placer.ts +1 -1
  10. package/src/helm-web-editor.ts +5 -5
  11. package/src/package-test.ts +0 -1
  12. package/src/package-utils.ts +211 -69
  13. package/src/package.ts +10 -71
  14. package/src/tests/findMonomers-tests.ts +2 -1
  15. package/src/tests/get-monomer-tests.ts +1 -49
  16. package/src/tests/helm-input-tests.ts +31 -20
  17. package/src/utils/get-monomer.ts +49 -1
  18. package/src/utils/helm-grid-cell-renderer.ts +8 -9
  19. package/src/utils/index.ts +2 -3
  20. package/src/widgets/helm-input.ts +4 -4
  21. package/vendor/dojo-1.10.10/dijit/BackgroundIframe.js +63 -0
  22. package/vendor/dojo-1.10.10/dijit/BackgroundIframe.js.uncompressed.js +116 -0
  23. package/vendor/dojo-1.10.10/dijit/Destroyable.js +35 -0
  24. package/vendor/dojo-1.10.10/dijit/Destroyable.js.uncompressed.js +83 -0
  25. package/vendor/dojo-1.10.10/dijit/Tooltip.js +240 -0
  26. package/vendor/dojo-1.10.10/dijit/Tooltip.js.uncompressed.js +612 -0
  27. package/vendor/dojo-1.10.10/dijit/Viewport.js +44 -0
  28. package/vendor/dojo-1.10.10/dijit/Viewport.js.uncompressed.js +87 -0
  29. package/vendor/dojo-1.10.10/dijit/WidgetSet.js +76 -0
  30. package/vendor/dojo-1.10.10/dijit/WidgetSet.js.uncompressed.js +247 -0
  31. package/vendor/dojo-1.10.10/dijit/_AttachMixin.js +94 -0
  32. package/vendor/dojo-1.10.10/dijit/_AttachMixin.js.uncompressed.js +238 -0
  33. package/vendor/dojo-1.10.10/dijit/_Contained.js +17 -0
  34. package/vendor/dojo-1.10.10/dijit/_Contained.js.uncompressed.js +56 -0
  35. package/vendor/dojo-1.10.10/dijit/_Container.js +47 -0
  36. package/vendor/dojo-1.10.10/dijit/_Container.js.uncompressed.js +108 -0
  37. package/vendor/dojo-1.10.10/dijit/_CssStateMixin.js +198 -0
  38. package/vendor/dojo-1.10.10/dijit/_CssStateMixin.js.uncompressed.js +372 -0
  39. package/vendor/dojo-1.10.10/dijit/_FocusMixin.js +11 -0
  40. package/vendor/dojo-1.10.10/dijit/_FocusMixin.js.uncompressed.js +66 -0
  41. package/vendor/dojo-1.10.10/dijit/_HasDropDown.js +188 -0
  42. package/vendor/dojo-1.10.10/dijit/_HasDropDown.js.uncompressed.js +472 -0
  43. package/vendor/dojo-1.10.10/dijit/_OnDijitClickMixin.js +8 -0
  44. package/vendor/dojo-1.10.10/dijit/_OnDijitClickMixin.js.uncompressed.js +31 -0
  45. package/vendor/dojo-1.10.10/dijit/_TemplatedMixin.js +90 -0
  46. package/vendor/dojo-1.10.10/dijit/_TemplatedMixin.js.uncompressed.js +205 -0
  47. package/vendor/dojo-1.10.10/dijit/_Widget.js +66 -0
  48. package/vendor/dojo-1.10.10/dijit/_Widget.js.uncompressed.js +352 -0
  49. package/vendor/dojo-1.10.10/dijit/_WidgetBase.js +353 -0
  50. package/vendor/dojo-1.10.10/dijit/_WidgetBase.js.uncompressed.js +1200 -0
  51. package/vendor/dojo-1.10.10/dijit/_base/focus.js +68 -0
  52. package/vendor/dojo-1.10.10/dijit/_base/focus.js.uncompressed.js +207 -0
  53. package/vendor/dojo-1.10.10/dijit/_base/manager.js +10 -0
  54. package/vendor/dojo-1.10.10/dijit/_base/manager.js.uncompressed.js +35 -0
  55. package/vendor/dojo-1.10.10/dijit/_base/place.js +52 -0
  56. package/vendor/dojo-1.10.10/dijit/_base/place.js.uncompressed.js +131 -0
  57. package/vendor/dojo-1.10.10/dijit/_base/popup.js +23 -0
  58. package/vendor/dojo-1.10.10/dijit/_base/popup.js.uncompressed.js +58 -0
  59. package/vendor/dojo-1.10.10/dijit/_base/scroll.js +6 -0
  60. package/vendor/dojo-1.10.10/dijit/_base/scroll.js.uncompressed.js +22 -0
  61. package/vendor/dojo-1.10.10/dijit/_base/sniff.js +3 -0
  62. package/vendor/dojo-1.10.10/dijit/_base/sniff.js.uncompressed.js +12 -0
  63. package/vendor/dojo-1.10.10/dijit/_base/typematic.js +3 -0
  64. package/vendor/dojo-1.10.10/dijit/_base/typematic.js.uncompressed.js +10 -0
  65. package/vendor/dojo-1.10.10/dijit/_base/wai.js +32 -0
  66. package/vendor/dojo-1.10.10/dijit/_base/wai.js.uncompressed.js +109 -0
  67. package/vendor/dojo-1.10.10/dijit/_base/window.js +6 -0
  68. package/vendor/dojo-1.10.10/dijit/_base/window.js.uncompressed.js +18 -0
  69. package/vendor/dojo-1.10.10/dijit/_base.js +4 -0
  70. package/vendor/dojo-1.10.10/dijit/a11y.js +109 -0
  71. package/vendor/dojo-1.10.10/dijit/a11y.js.uncompressed.js +191 -0
  72. package/vendor/dojo-1.10.10/dijit/a11yclick.js +66 -0
  73. package/vendor/dojo-1.10.10/dijit/a11yclick.js.uncompressed.js +139 -0
  74. package/vendor/dojo-1.10.10/dijit/focus.js +188 -0
  75. package/vendor/dojo-1.10.10/dijit/focus.js.uncompressed.js +371 -0
  76. package/vendor/dojo-1.10.10/dijit/form/Button.js +49 -0
  77. package/vendor/dojo-1.10.10/dijit/form/Button.js.uncompressed.js +130 -0
  78. package/vendor/dojo-1.10.10/dijit/form/ComboBox.js +4 -0
  79. package/vendor/dojo-1.10.10/dijit/form/ComboBox.js.uncompressed.js +27 -0
  80. package/vendor/dojo-1.10.10/dijit/form/ComboButton.js +21 -0
  81. package/vendor/dojo-1.10.10/dijit/form/ComboButton.js.uncompressed.js +86 -0
  82. package/vendor/dojo-1.10.10/dijit/form/DropDownButton.js +38 -0
  83. package/vendor/dojo-1.10.10/dijit/form/DropDownButton.js.uncompressed.js +102 -0
  84. package/vendor/dojo-1.10.10/dijit/form/ToggleButton.js +7 -0
  85. package/vendor/dojo-1.10.10/dijit/form/ToggleButton.js.uncompressed.js +26 -0
  86. package/vendor/dojo-1.10.10/dijit/form/_ButtonMixin.js +50 -0
  87. package/vendor/dojo-1.10.10/dijit/form/_ButtonMixin.js.uncompressed.js +116 -0
  88. package/vendor/dojo-1.10.10/dijit/form/_FormValueMixin.js +26 -0
  89. package/vendor/dojo-1.10.10/dijit/form/_FormValueMixin.js.uncompressed.js +81 -0
  90. package/vendor/dojo-1.10.10/dijit/form/_FormValueWidget.js +24 -0
  91. package/vendor/dojo-1.10.10/dijit/form/_FormValueWidget.js.uncompressed.js +51 -0
  92. package/vendor/dojo-1.10.10/dijit/form/_FormWidget.js +22 -0
  93. package/vendor/dojo-1.10.10/dijit/form/_FormWidget.js.uncompressed.js +67 -0
  94. package/vendor/dojo-1.10.10/dijit/form/_FormWidgetMixin.js +111 -0
  95. package/vendor/dojo-1.10.10/dijit/form/_FormWidgetMixin.js.uncompressed.js +254 -0
  96. package/vendor/dojo-1.10.10/dijit/form/_ToggleButtonMixin.js +32 -0
  97. package/vendor/dojo-1.10.10/dijit/form/_ToggleButtonMixin.js.uncompressed.js +69 -0
  98. package/vendor/dojo-1.10.10/dijit/hccss.js +9 -0
  99. package/vendor/dojo-1.10.10/dijit/hccss.js.uncompressed.js +21 -0
  100. package/vendor/dojo-1.10.10/dijit/layout/AccordionContainer.js +215 -0
  101. package/vendor/dojo-1.10.10/dijit/layout/AccordionContainer.js.uncompressed.js +550 -0
  102. package/vendor/dojo-1.10.10/dijit/layout/AccordionPane.js +7 -0
  103. package/vendor/dojo-1.10.10/dijit/layout/AccordionPane.js.uncompressed.js +25 -0
  104. package/vendor/dojo-1.10.10/dijit/layout/ContentPane.js +235 -0
  105. package/vendor/dojo-1.10.10/dijit/layout/ContentPane.js.uncompressed.js +653 -0
  106. package/vendor/dojo-1.10.10/dijit/layout/StackContainer.js +171 -0
  107. package/vendor/dojo-1.10.10/dijit/layout/StackContainer.js.uncompressed.js +411 -0
  108. package/vendor/dojo-1.10.10/dijit/layout/StackController.js +194 -0
  109. package/vendor/dojo-1.10.10/dijit/layout/StackController.js.uncompressed.js +410 -0
  110. package/vendor/dojo-1.10.10/dijit/layout/_ContentPaneResizeMixin.js +99 -0
  111. package/vendor/dojo-1.10.10/dijit/layout/_ContentPaneResizeMixin.js.uncompressed.js +236 -0
  112. package/vendor/dojo-1.10.10/dijit/layout/_LayoutWidget.js +47 -0
  113. package/vendor/dojo-1.10.10/dijit/layout/_LayoutWidget.js.uncompressed.js +190 -0
  114. package/vendor/dojo-1.10.10/dijit/layout/utils.js +77 -0
  115. package/vendor/dojo-1.10.10/dijit/layout/utils.js.uncompressed.js +151 -0
  116. package/vendor/dojo-1.10.10/dijit/main.js +4 -0
  117. package/vendor/dojo-1.10.10/dijit/main.js.uncompressed.js +16 -0
  118. package/vendor/dojo-1.10.10/dijit/nls/dijit-all_en-us.js +2 -0
  119. package/vendor/dojo-1.10.10/dijit/nls/dijit-all_en-us.js.uncompressed.js +21 -0
  120. package/vendor/dojo-1.10.10/dijit/nls/loading.js +2 -0
  121. package/vendor/dojo-1.10.10/dijit/nls/loading.js.uncompressed.js +47 -0
  122. package/vendor/dojo-1.10.10/dijit/place.js +142 -0
  123. package/vendor/dojo-1.10.10/dijit/place.js.uncompressed.js +407 -0
  124. package/vendor/dojo-1.10.10/dijit/popup.js +162 -0
  125. package/vendor/dojo-1.10.10/dijit/popup.js.uncompressed.js +441 -0
  126. package/vendor/dojo-1.10.10/dijit/registry.js +79 -0
  127. package/vendor/dojo-1.10.10/dijit/registry.js.uncompressed.js +159 -0
  128. package/vendor/dojo-1.10.10/dijit/selection.js +364 -0
  129. package/vendor/dojo-1.10.10/dijit/selection.js.uncompressed.js +525 -0
  130. package/vendor/dojo-1.10.10/dijit/typematic.js +96 -0
  131. package/vendor/dojo-1.10.10/dijit/typematic.js.uncompressed.js +211 -0
  132. package/vendor/dojo-1.10.10/dojo/NodeList-manipulate.js +195 -0
  133. package/vendor/dojo-1.10.10/dojo/NodeList-manipulate.js.uncompressed.js +761 -0
  134. package/vendor/dojo-1.10.10/dojo/Stateful.js +90 -0
  135. package/vendor/dojo-1.10.10/dojo/Stateful.js.uncompressed.js +218 -0
  136. package/vendor/dojo-1.10.10/dojo/_base/url.js +87 -0
  137. package/vendor/dojo-1.10.10/dojo/_base/url.js.uncompressed.js +109 -0
  138. package/vendor/dojo-1.10.10/dojo/cache.js +9 -0
  139. package/vendor/dojo-1.10.10/dojo/cache.js.uncompressed.js +7 -0
  140. package/vendor/dojo-1.10.10/dojo/colors.js +74 -0
  141. package/vendor/dojo-1.10.10/dojo/colors.js.uncompressed.js +232 -0
  142. package/vendor/dojo-1.10.10/dojo/cookie.js +48 -0
  143. package/vendor/dojo-1.10.10/dojo/cookie.js.uncompressed.js +98 -0
  144. package/vendor/dojo-1.10.10/dojo/date/stamp.js +82 -0
  145. package/vendor/dojo-1.10.10/dojo/date/stamp.js.uncompressed.js +144 -0
  146. package/vendor/dojo-1.10.10/dojo/dojo.js +7 -0
  147. package/vendor/dojo-1.10.10/dojo/dojo.js.uncompressed.js +18680 -0
  148. package/vendor/dojo-1.10.10/dojo/fx/Toggler.js +27 -0
  149. package/vendor/dojo-1.10.10/dojo/fx/Toggler.js.uncompressed.js +101 -0
  150. package/vendor/dojo-1.10.10/dojo/fx/easing.js +165 -0
  151. package/vendor/dojo-1.10.10/dojo/fx/easing.js.uncompressed.js +276 -0
  152. package/vendor/dojo-1.10.10/dojo/fx.js +271 -0
  153. package/vendor/dojo-1.10.10/dojo/fx.js.uncompressed.js +443 -0
  154. package/vendor/dojo-1.10.10/dojo/hccss.js +26 -0
  155. package/vendor/dojo-1.10.10/dojo/hccss.js.uncompressed.js +52 -0
  156. package/vendor/dojo-1.10.10/dojo/html.js +161 -0
  157. package/vendor/dojo-1.10.10/dojo/html.js.uncompressed.js +370 -0
  158. package/vendor/dojo-1.10.10/dojo/io/iframe.js +71 -0
  159. package/vendor/dojo-1.10.10/dojo/io/iframe.js.uncompressed.js +190 -0
  160. package/vendor/dojo-1.10.10/dojo/io/script.js +112 -0
  161. package/vendor/dojo-1.10.10/dojo/io/script.js.uncompressed.js +280 -0
  162. package/vendor/dojo-1.10.10/dojo/parser.js +437 -0
  163. package/vendor/dojo-1.10.10/dojo/parser.js.uncompressed.js +915 -0
  164. package/vendor/dojo-1.10.10/dojo/promise/all.js +59 -0
  165. package/vendor/dojo-1.10.10/dojo/promise/all.js.uncompressed.js +77 -0
  166. package/vendor/dojo-1.10.10/dojo/regexp.js +32 -0
  167. package/vendor/dojo-1.10.10/dojo/regexp.js.uncompressed.js +70 -0
  168. package/vendor/dojo-1.10.10/dojo/request/iframe.js +291 -0
  169. package/vendor/dojo-1.10.10/dojo/request/iframe.js.uncompressed.js +438 -0
  170. package/vendor/dojo-1.10.10/dojo/request/script.js +129 -0
  171. package/vendor/dojo-1.10.10/dojo/request/script.js.uncompressed.js +237 -0
  172. package/vendor/dojo-1.10.10/dojo/require.js +11 -0
  173. package/vendor/dojo-1.10.10/dojo/require.js.uncompressed.js +7 -0
  174. package/vendor/dojo-1.10.10/dojo/resources/blank.gif +0 -0
  175. package/vendor/dojo-1.10.10/dojo/string.js +67 -0
  176. package/vendor/dojo-1.10.10/dojo/string.js.uncompressed.js +181 -0
  177. package/vendor/dojo-1.10.10/dojo/touch.js +191 -0
  178. package/vendor/dojo-1.10.10/dojo/touch.js.uncompressed.js +468 -0
  179. package/vendor/dojo-1.10.10/dojo/uacss.js +36 -0
  180. package/vendor/dojo-1.10.10/dojo/uacss.js.uncompressed.js +85 -0
  181. package/vendor/dojo-1.10.10/dojo/window.js +141 -0
  182. package/vendor/dojo-1.10.10/dojo/window.js.uncompressed.js +241 -0
  183. package/vendor/dojo-1.10.10/dojox/charting/Chart.js +626 -0
  184. package/vendor/dojo-1.10.10/dojox/charting/Chart.js.uncompressed.js +1220 -0
  185. package/vendor/dojo-1.10.10/dojox/charting/Chart2D.js +5 -0
  186. package/vendor/dojo-1.10.10/dojox/charting/Chart2D.js.uncompressed.js +16 -0
  187. package/vendor/dojo-1.10.10/dojox/charting/Element.js +247 -0
  188. package/vendor/dojo-1.10.10/dojox/charting/Element.js.uncompressed.js +402 -0
  189. package/vendor/dojo-1.10.10/dojox/charting/Series.js +24 -0
  190. package/vendor/dojo-1.10.10/dojox/charting/Series.js.uncompressed.js +58 -0
  191. package/vendor/dojo-1.10.10/dojox/charting/SimpleTheme.js +191 -0
  192. package/vendor/dojo-1.10.10/dojox/charting/SimpleTheme.js.uncompressed.js +577 -0
  193. package/vendor/dojo-1.10.10/dojox/charting/Theme.js +42 -0
  194. package/vendor/dojo-1.10.10/dojox/charting/Theme.js.uncompressed.js +120 -0
  195. package/vendor/dojo-1.10.10/dojox/charting/action2d/Base.js +11 -0
  196. package/vendor/dojo-1.10.10/dojox/charting/action2d/Base.js.uncompressed.js +36 -0
  197. package/vendor/dojo-1.10.10/dojox/charting/action2d/Highlight.js +77 -0
  198. package/vendor/dojo-1.10.10/dojox/charting/action2d/Highlight.js.uncompressed.js +144 -0
  199. package/vendor/dojo-1.10.10/dojox/charting/action2d/Magnify.js +58 -0
  200. package/vendor/dojo-1.10.10/dojox/charting/action2d/Magnify.js.uncompressed.js +123 -0
  201. package/vendor/dojo-1.10.10/dojox/charting/action2d/MoveSlice.js +54 -0
  202. package/vendor/dojo-1.10.10/dojox/charting/action2d/MoveSlice.js.uncompressed.js +124 -0
  203. package/vendor/dojo-1.10.10/dojox/charting/action2d/PlotAction.js +28 -0
  204. package/vendor/dojo-1.10.10/dojox/charting/action2d/PlotAction.js.uncompressed.js +74 -0
  205. package/vendor/dojo-1.10.10/dojox/charting/action2d/Tooltip.js +116 -0
  206. package/vendor/dojo-1.10.10/dojox/charting/action2d/Tooltip.js.uncompressed.js +178 -0
  207. package/vendor/dojo-1.10.10/dojox/charting/axis2d/Base.js +24 -0
  208. package/vendor/dojo-1.10.10/dojox/charting/axis2d/Base.js.uncompressed.js +83 -0
  209. package/vendor/dojo-1.10.10/dojox/charting/axis2d/Default.js +557 -0
  210. package/vendor/dojo-1.10.10/dojox/charting/axis2d/Default.js.uncompressed.js +980 -0
  211. package/vendor/dojo-1.10.10/dojox/charting/axis2d/Invisible.js +65 -0
  212. package/vendor/dojo-1.10.10/dojox/charting/axis2d/Invisible.js.uncompressed.js +224 -0
  213. package/vendor/dojo-1.10.10/dojox/charting/axis2d/common.js +91 -0
  214. package/vendor/dojo-1.10.10/dojox/charting/axis2d/common.js.uncompressed.js +164 -0
  215. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Areas.js +7 -0
  216. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Areas.js.uncompressed.js +14 -0
  217. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Bars.js +168 -0
  218. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Bars.js.uncompressed.js +311 -0
  219. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Base.js +61 -0
  220. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Base.js.uncompressed.js +161 -0
  221. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Bubble.js +141 -0
  222. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Bubble.js.uncompressed.js +242 -0
  223. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Candlesticks.js +126 -0
  224. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Candlesticks.js.uncompressed.js +243 -0
  225. package/vendor/dojo-1.10.10/dojox/charting/plot2d/CartesianBase.js +108 -0
  226. package/vendor/dojo-1.10.10/dojox/charting/plot2d/CartesianBase.js.uncompressed.js +290 -0
  227. package/vendor/dojo-1.10.10/dojox/charting/plot2d/ClusteredBars.js +13 -0
  228. package/vendor/dojo-1.10.10/dojox/charting/plot2d/ClusteredBars.js.uncompressed.js +14 -0
  229. package/vendor/dojo-1.10.10/dojox/charting/plot2d/ClusteredColumns.js +13 -0
  230. package/vendor/dojo-1.10.10/dojox/charting/plot2d/ClusteredColumns.js.uncompressed.js +14 -0
  231. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Columns.js +153 -0
  232. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Columns.js.uncompressed.js +249 -0
  233. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Default.js +253 -0
  234. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Default.js.uncompressed.js +472 -0
  235. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Grid.js +182 -0
  236. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Grid.js.uncompressed.js +356 -0
  237. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Lines.js +6 -0
  238. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Lines.js.uncompressed.js +12 -0
  239. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Markers.js +6 -0
  240. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Markers.js.uncompressed.js +12 -0
  241. package/vendor/dojo-1.10.10/dojox/charting/plot2d/MarkersOnly.js +7 -0
  242. package/vendor/dojo-1.10.10/dojox/charting/plot2d/MarkersOnly.js.uncompressed.js +13 -0
  243. package/vendor/dojo-1.10.10/dojox/charting/plot2d/OHLC.js +110 -0
  244. package/vendor/dojo-1.10.10/dojox/charting/plot2d/OHLC.js.uncompressed.js +208 -0
  245. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Pie.js +303 -0
  246. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Pie.js.uncompressed.js +547 -0
  247. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Scatter.js +134 -0
  248. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Scatter.js.uncompressed.js +207 -0
  249. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Spider.js +299 -0
  250. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Spider.js.uncompressed.js +537 -0
  251. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Stacked.js +24 -0
  252. package/vendor/dojo-1.10.10/dojox/charting/plot2d/Stacked.js.uncompressed.js +44 -0
  253. package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedAreas.js +7 -0
  254. package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedAreas.js.uncompressed.js +14 -0
  255. package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedBars.js +22 -0
  256. package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedBars.js.uncompressed.js +33 -0
  257. package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedColumns.js +20 -0
  258. package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedColumns.js.uncompressed.js +31 -0
  259. package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedLines.js +6 -0
  260. package/vendor/dojo-1.10.10/dojox/charting/plot2d/StackedLines.js.uncompressed.js +12 -0
  261. package/vendor/dojo-1.10.10/dojox/charting/plot2d/_PlotEvents.js +68 -0
  262. package/vendor/dojo-1.10.10/dojox/charting/plot2d/_PlotEvents.js.uncompressed.js +120 -0
  263. package/vendor/dojo-1.10.10/dojox/charting/plot2d/common.js +209 -0
  264. package/vendor/dojo-1.10.10/dojox/charting/plot2d/common.js.uncompressed.js +214 -0
  265. package/vendor/dojo-1.10.10/dojox/charting/plot2d/commonStacked.js +76 -0
  266. package/vendor/dojo-1.10.10/dojox/charting/plot2d/commonStacked.js.uncompressed.js +77 -0
  267. package/vendor/dojo-1.10.10/dojox/charting/scaler/common.js +59 -0
  268. package/vendor/dojo-1.10.10/dojox/charting/scaler/common.js.uncompressed.js +70 -0
  269. package/vendor/dojo-1.10.10/dojox/charting/scaler/linear.js +220 -0
  270. package/vendor/dojo-1.10.10/dojox/charting/scaler/linear.js.uncompressed.js +262 -0
  271. package/vendor/dojo-1.10.10/dojox/charting/scaler/primitive.js +23 -0
  272. package/vendor/dojo-1.10.10/dojox/charting/scaler/primitive.js.uncompressed.js +36 -0
  273. package/vendor/dojo-1.10.10/dojox/charting/themes/Claro.js +39 -0
  274. package/vendor/dojo-1.10.10/dojox/charting/themes/Claro.js.uncompressed.js +106 -0
  275. package/vendor/dojo-1.10.10/dojox/charting/themes/Wetland.js +5 -0
  276. package/vendor/dojo-1.10.10/dojox/charting/themes/Wetland.js.uncompressed.js +12 -0
  277. package/vendor/dojo-1.10.10/dojox/charting/themes/common.js +4 -0
  278. package/vendor/dojo-1.10.10/dojox/charting/themes/common.js.uncompressed.js +3 -0
  279. package/vendor/dojo-1.10.10/dojox/charting/widget/Legend.js +102 -0
  280. package/vendor/dojo-1.10.10/dojox/charting/widget/Legend.js.uncompressed.js +165 -0
  281. package/vendor/dojo-1.10.10/dojox/color/Palette.js +163 -0
  282. package/vendor/dojo-1.10.10/dojox/color/Palette.js.uncompressed.js +460 -0
  283. package/vendor/dojo-1.10.10/dojox/color/_base.js +174 -0
  284. package/vendor/dojo-1.10.10/dojox/color/_base.js.uncompressed.js +196 -0
  285. package/vendor/dojo-1.10.10/dojox/gfx/fx.js +297 -0
  286. package/vendor/dojo-1.10.10/dojox/gfx/fx.js.uncompressed.js +350 -0
  287. package/vendor/dojo-1.10.10/dojox/gfx/gradutils.js +63 -0
  288. package/vendor/dojo-1.10.10/dojox/gfx/gradutils.js.uncompressed.js +91 -0
  289. package/vendor/dojo-1.10.10/dojox/gfx/matrix.js +170 -0
  290. package/vendor/dojo-1.10.10/dojox/gfx/matrix.js.uncompressed.js +501 -0
  291. package/vendor/dojo-1.10.10/dojox/gfx/path.js +319 -0
  292. package/vendor/dojo-1.10.10/dojox/gfx/path.js.uncompressed.js +478 -0
  293. package/vendor/dojo-1.10.10/dojox/gfx/shape.js +459 -0
  294. package/vendor/dojo-1.10.10/dojox/gfx/shape.js.uncompressed.js +1091 -0
  295. package/vendor/dojo-1.10.10/dojox/gfx/svg.js +662 -0
  296. package/vendor/dojo-1.10.10/dojox/gfx/svg.js.uncompressed.js +1023 -0
  297. package/vendor/dojo-1.10.10/dojox/gfx/utils.js +199 -0
  298. package/vendor/dojo-1.10.10/dojox/gfx/utils.js.uncompressed.js +322 -0
  299. package/vendor/dojo-1.10.10/dojox/gfx.js +2 -0
  300. package/vendor/dojo-1.10.10/dojox/gfx.js.uncompressed.js +1136 -0
  301. package/vendor/dojo-1.10.10/dojox/lang/functional/array.js +151 -0
  302. package/vendor/dojo-1.10.10/dojox/lang/functional/array.js.uncompressed.js +169 -0
  303. package/vendor/dojo-1.10.10/dojox/lang/functional/fold.js +93 -0
  304. package/vendor/dojo-1.10.10/dojox/lang/functional/fold.js.uncompressed.js +125 -0
  305. package/vendor/dojo-1.10.10/dojox/lang/functional/lambda.js +81 -0
  306. package/vendor/dojo-1.10.10/dojox/lang/functional/lambda.js.uncompressed.js +132 -0
  307. package/vendor/dojo-1.10.10/dojox/lang/functional/object.js +54 -0
  308. package/vendor/dojo-1.10.10/dojox/lang/functional/object.js.uncompressed.js +78 -0
  309. package/vendor/dojo-1.10.10/dojox/lang/functional/reversed.js +61 -0
  310. package/vendor/dojo-1.10.10/dojox/lang/functional/reversed.js.uncompressed.js +77 -0
  311. package/vendor/dojo-1.10.10/dojox/lang/functional/scan.js +87 -0
  312. package/vendor/dojo-1.10.10/dojox/lang/functional/scan.js.uncompressed.js +107 -0
  313. package/vendor/dojo-1.10.10/dojox/lang/functional.js +4 -0
  314. package/vendor/dojo-1.10.10/dojox/lang/functional.js.uncompressed.js +3 -0
  315. package/vendor/dojo-1.10.10/dojox/lang/utils.js +86 -0
  316. package/vendor/dojo-1.10.10/dojox/lang/utils.js.uncompressed.js +121 -0
  317. package/vendor/dojo-1.10.10/dojox/main.js +4 -0
  318. package/vendor/dojo-1.10.10/dojox/main.js.uncompressed.js +14 -0
  319. package/vendor/dojo-1.10.10/dojox/storage/LocalStorageProvider.js +112 -0
  320. package/vendor/dojo-1.10.10/dojox/storage/LocalStorageProvider.js.uncompressed.js +208 -0
  321. package/vendor/dojo-1.10.10/dojox/storage/Provider.js +62 -0
  322. package/vendor/dojo-1.10.10/dojox/storage/Provider.js.uncompressed.js +344 -0
  323. package/vendor/dojo-1.10.10/dojox/storage/manager.js +110 -0
  324. package/vendor/dojo-1.10.10/dojox/storage/manager.js.uncompressed.js +263 -0
@@ -0,0 +1,547 @@
1
+ define("dojox/charting/plot2d/Pie", ["dojo/_base/lang", "dojo/_base/array" ,"dojo/_base/declare",
2
+ "./Base", "./_PlotEvents", "./common",
3
+ "dojox/gfx", "dojox/gfx/matrix", "dojox/lang/functional", "dojox/lang/utils","dojo/has"],
4
+ function(lang, arr, declare, Base, PlotEvents, dc, g, m, df, du, has){
5
+
6
+ /*=====
7
+ declare("dojox.charting.plot2d.__PieCtorArgs", dojox.charting.plot2d.__DefaultCtorArgs, {
8
+ // summary:
9
+ // Specialized keyword arguments object for use in defining parameters on a Pie chart.
10
+
11
+ // labels: Boolean?
12
+ // Whether or not to draw labels for each pie slice. Default is true.
13
+ labels: true,
14
+
15
+ // ticks: Boolean?
16
+ // Whether or not to draw ticks to labels within each slice. Default is false.
17
+ ticks: false,
18
+
19
+ // fixed: Boolean?
20
+ // Whether a fixed precision must be applied to data values for display. Default is true.
21
+ fixed: true,
22
+
23
+ // precision: Number?
24
+ // The precision at which to round data values for display. Default is 0.
25
+ precision: 1,
26
+
27
+ // labelOffset: Number?
28
+ // The amount in pixels by which to offset labels. Default is 20.
29
+ labelOffset: 20,
30
+
31
+ // labelStyle: String?
32
+ // Options as to where to draw labels. Values include "default", and "columns". Default is "default".
33
+ labelStyle: "default", // default/columns
34
+
35
+ // omitLabels: Boolean?
36
+ // Whether labels of slices small to the point of not being visible are omitted. Default false.
37
+ omitLabels: false,
38
+
39
+ // htmlLabels: Boolean?
40
+ // Whether or not to use HTML to render slice labels. Default is true.
41
+ htmlLabels: true,
42
+
43
+ // radGrad: String?
44
+ // The type of radial gradient to use in rendering. Default is "native".
45
+ radGrad: "native",
46
+
47
+ // fanSize: Number?
48
+ // The amount for a radial gradient. Default is 5.
49
+ fanSize: 5,
50
+
51
+ // startAngle: Number?
52
+ // Where to being rendering gradients in slices, in degrees. Default is 0.
53
+ startAngle: 0,
54
+
55
+ // radius: Number?
56
+ // The size of the radial gradient. Default is 0.
57
+ radius: 0,
58
+
59
+ // shadow: dojox.gfx.Stroke?
60
+ // An optional stroke to use to draw any shadows for a series on a plot.
61
+ shadow: {},
62
+
63
+ // fill: dojox.gfx.Fill?
64
+ // Any fill to be used for elements on the plot.
65
+ fill: {},
66
+
67
+ // filter: dojox.gfx.Filter?
68
+ // An SVG filter to be used for elements on the plot. gfx SVG renderer must be used and dojox/gfx/svgext must
69
+ // be required for this to work.
70
+ filter: {},
71
+
72
+ // styleFunc: Function?
73
+ // A function that returns a styling object for the a given data item.
74
+ styleFunc: null
75
+ });
76
+ =====*/
77
+
78
+ var FUDGE_FACTOR = 0.2; // use to overlap fans
79
+
80
+ return declare("dojox.charting.plot2d.Pie", [Base, PlotEvents], {
81
+ // summary:
82
+ // The plot that represents a typical pie chart.
83
+ defaultParams: {
84
+ labels: true,
85
+ ticks: false,
86
+ fixed: true,
87
+ precision: 1,
88
+ labelOffset: 20,
89
+ labelStyle: "default", // default/columns
90
+ htmlLabels: true, // use HTML to draw labels
91
+ radGrad: "native", // or "linear", or "fan"
92
+ fanSize: 5, // maximum fan size in degrees
93
+ startAngle: 0 // start angle for slices in degrees
94
+ },
95
+ optionalParams: {
96
+ radius: 0,
97
+ omitLabels: false,
98
+ // theme components
99
+ stroke: {},
100
+ outline: {},
101
+ shadow: {},
102
+ fill: {},
103
+ filter: {},
104
+ styleFunc: null,
105
+ font: "",
106
+ fontColor: "",
107
+ labelWiring: {}
108
+ },
109
+
110
+ constructor: function(chart, kwArgs){
111
+ // summary:
112
+ // Create a pie plot.
113
+ this.opt = lang.clone(this.defaultParams);
114
+ du.updateWithObject(this.opt, kwArgs);
115
+ du.updateWithPattern(this.opt, kwArgs, this.optionalParams);
116
+ this.axes = [];
117
+ this.run = null;
118
+ this.dyn = [];
119
+ this.runFilter = [];
120
+ },
121
+ clear: function(){
122
+ // summary:
123
+ // Clear out all of the information tied to this plot.
124
+ // returns: dojox/charting/plot2d/Pie
125
+ // A reference to this plot for functional chaining.
126
+ this.inherited(arguments);
127
+ this.dyn = [];
128
+ this.run = null;
129
+ return this; // dojox/charting/plot2d/Pie
130
+ },
131
+ setAxis: function(axis){
132
+ // summary:
133
+ // Dummy method, since axes are irrelevant with a Pie chart.
134
+ // returns: dojox/charting/plot2d/Pie
135
+ // The reference to this plot for functional chaining.
136
+ return this; // dojox/charting/plot2d/Pie
137
+ },
138
+ addSeries: function(run){
139
+ // summary:
140
+ // Add a series of data to this plot.
141
+ // returns: dojox/charting/plot2d/Pie
142
+ // The reference to this plot for functional chaining.
143
+ this.run = run;
144
+ return this; // dojox/charting/plot2d/Pie
145
+ },
146
+ getSeriesStats: function(){
147
+ // summary:
148
+ // Returns default stats (irrelevant for this type of plot).
149
+ // returns: Object
150
+ // {hmin, hmax, vmin, vmax} min/max in both directions.
151
+ return lang.delegate(dc.defaultStats); // Object
152
+ },
153
+ getRequiredColors: function(){
154
+ // summary:
155
+ // Return the number of colors needed to draw this plot.
156
+ return this.run ? this.run.data.length : 0;
157
+ },
158
+ render: function(dim, offsets){
159
+ // summary:
160
+ // Render the plot on the chart.
161
+ // dim: Object
162
+ // An object of the form { width, height }.
163
+ // offsets: Object
164
+ // An object of the form { l, r, t, b }.
165
+ // returns: dojox/charting/plot2d/Pie
166
+ // A reference to this plot for functional chaining.
167
+ if(!this.dirty){ return this; }
168
+ this.resetEvents();
169
+ this.dirty = false;
170
+ this._eventSeries = {};
171
+ this.cleanGroup();
172
+ var s = this.group, t = this.chart.theme;
173
+
174
+ if(!this.run || !this.run.data.length){
175
+ return this;
176
+ }
177
+
178
+ // calculate the geometry
179
+ var rx = (dim.width - offsets.l - offsets.r) / 2,
180
+ ry = (dim.height - offsets.t - offsets.b) / 2,
181
+ r = Math.min(rx, ry),
182
+ labelFont = "font" in this.opt ? this.opt.font : t.series.font,
183
+ size,
184
+ startAngle = m._degToRad(this.opt.startAngle),
185
+ start = startAngle, filteredRun, slices, labels, shift, labelR,
186
+ events = this.events();
187
+
188
+ var run = arr.map(this.run.data, function(item, i){
189
+ if(typeof item != "number" && item.hidden){
190
+ this.runFilter.push(i);
191
+ item.hidden = false;
192
+ }
193
+ if(arr.some(this.runFilter, function(filter){return filter == i;})){
194
+ if(typeof item == "number"){
195
+ return 0;
196
+ }else{
197
+ return {y: 0, text: item.text};
198
+ }
199
+ }else{
200
+ return item;
201
+ }
202
+ }, this);
203
+
204
+ this.dyn = [];
205
+
206
+ if("radius" in this.opt){
207
+ r = this.opt.radius;
208
+ labelR = r - this.opt.labelOffset;
209
+ }
210
+ var circle = {
211
+ cx: offsets.l + rx,
212
+ cy: offsets.t + ry,
213
+ r: r
214
+ };
215
+
216
+ // draw shadow
217
+ if(this.opt.shadow || t.shadow){
218
+ var shadow = this.opt.shadow || t.shadow;
219
+ var scircle = lang.clone(circle);
220
+ scircle.cx += shadow.dx;
221
+ scircle.cy += shadow.dy;
222
+ s.createCircle(scircle).setFill(shadow.color).setStroke(shadow);
223
+ }
224
+ if(s.setFilter && (this.opt.filter || t.filter)){
225
+ s.createCircle(circle).setFill(t.series.stroke).setFilter(this.opt.filter || t.filter);
226
+ }
227
+
228
+ if(typeof run[0] == "number"){
229
+ filteredRun = df.map(run, "x ? Math.max(x, 0) : 0");
230
+ if(df.every(filteredRun, "<= 0")){
231
+ s.createCircle(circle).setStroke(t.series.stroke);
232
+ this.dyn = arr.map(filteredRun, function(){
233
+ return { };
234
+ });
235
+ return this;
236
+ }else{
237
+ slices = df.map(filteredRun, "/this", df.foldl(filteredRun, "+", 0));
238
+ if(this.opt.labels){
239
+ labels = arr.map(slices, function(x){
240
+ return x > 0 ? this._getLabel(x * 100) + "%" : "";
241
+ }, this);
242
+ }
243
+ }
244
+ }else{
245
+ filteredRun = df.map(run, "x ? Math.max(x.y, 0) : 0");
246
+ if(df.every(filteredRun, "<= 0")){
247
+ s.createCircle(circle).setStroke(t.series.stroke);
248
+ this.dyn = arr.map(filteredRun, function(){
249
+ return { };
250
+ });
251
+ return this;
252
+ }else{
253
+ slices = df.map(filteredRun, "/this", df.foldl(filteredRun, "+", 0));
254
+ if(this.opt.labels){
255
+ labels = arr.map(slices, function(x, i){
256
+ if(x < 0){ return ""; }
257
+ var v = run[i];
258
+ return "text" in v ? v.text : this._getLabel(x * 100) + "%";
259
+ }, this);
260
+ }
261
+ }
262
+ }
263
+ var themes = df.map(run, function(v, i){
264
+ var tMixin = [this.opt, this.run];
265
+ if(v !== null && typeof v != "number"){
266
+ tMixin.push(v);
267
+ }
268
+ if(this.opt.styleFunc){
269
+ tMixin.push(this.opt.styleFunc(v));
270
+ }
271
+ return t.next("slice", tMixin, true);
272
+ }, this);
273
+
274
+ if(this.opt.labels){
275
+ size = labelFont ? g.normalizedLength(g.splitFontString(labelFont).size) : 0;
276
+ shift = df.foldl1(df.map(labels, function(label, i){
277
+ var font = themes[i].series.font;
278
+ return g._base._getTextBox(label, {font: font}).w;
279
+ }, this), "Math.max(a, b)") / 2;
280
+ if(this.opt.labelOffset < 0){
281
+ r = Math.min(rx - 2 * shift, ry - size) + this.opt.labelOffset;
282
+ }
283
+ labelR = r - this.opt.labelOffset;
284
+ }
285
+
286
+ // draw slices
287
+ var eventSeries = new Array(slices.length);
288
+ arr.some(slices, function(slice, i){
289
+ if(slice < 0){
290
+ // degenerated slice
291
+ return false; // continue
292
+ }
293
+ var v = run[i], theme = themes[i], specialFill, o;
294
+ if(slice == 0){
295
+ this.dyn.push({fill: theme.series.fill, stroke: theme.series.stroke});
296
+ return false;
297
+ }
298
+
299
+ if(slice >= 1){
300
+ // whole pie
301
+ specialFill = this._plotFill(theme.series.fill, dim, offsets);
302
+ specialFill = this._shapeFill(specialFill,
303
+ {
304
+ x: circle.cx - circle.r, y: circle.cy - circle.r,
305
+ width: 2 * circle.r, height: 2 * circle.r
306
+ });
307
+ specialFill = this._pseudoRadialFill(specialFill, {x: circle.cx, y: circle.cy}, circle.r);
308
+ var shape = s.createCircle(circle).setFill(specialFill).setStroke(theme.series.stroke);
309
+ this.dyn.push({fill: specialFill, stroke: theme.series.stroke});
310
+
311
+ if(events){
312
+ o = {
313
+ element: "slice",
314
+ index: i,
315
+ run: this.run,
316
+ shape: shape,
317
+ x: i,
318
+ y: typeof v == "number" ? v : v.y,
319
+ cx: circle.cx,
320
+ cy: circle.cy,
321
+ cr: r
322
+ };
323
+ this._connectEvents(o);
324
+ eventSeries[i] = o;
325
+ }
326
+
327
+ return false; // we continue because we want to collect null data points for legend
328
+ }
329
+ // calculate the geometry of the slice
330
+ var end = start + slice * 2 * Math.PI;
331
+ if(i + 1 == slices.length){
332
+ end = startAngle + 2 * Math.PI;
333
+ }
334
+ var step = end - start,
335
+ x1 = circle.cx + r * Math.cos(start),
336
+ y1 = circle.cy + r * Math.sin(start),
337
+ x2 = circle.cx + r * Math.cos(end),
338
+ y2 = circle.cy + r * Math.sin(end);
339
+ // draw the slice
340
+ var fanSize = m._degToRad(this.opt.fanSize);
341
+ if(theme.series.fill && theme.series.fill.type === "radial" && this.opt.radGrad === "fan" && step > fanSize){
342
+ var group = s.createGroup(), nfans = Math.ceil(step / fanSize), delta = step / nfans;
343
+ specialFill = this._shapeFill(theme.series.fill,
344
+ {x: circle.cx - circle.r, y: circle.cy - circle.r, width: 2 * circle.r, height: 2 * circle.r});
345
+ for(var j = 0; j < nfans; ++j){
346
+ var fansx = j == 0 ? x1 : circle.cx + r * Math.cos(start + (j - FUDGE_FACTOR) * delta),
347
+ fansy = j == 0 ? y1 : circle.cy + r * Math.sin(start + (j - FUDGE_FACTOR) * delta),
348
+ fanex = j == nfans - 1 ? x2 : circle.cx + r * Math.cos(start + (j + 1 + FUDGE_FACTOR) * delta),
349
+ faney = j == nfans - 1 ? y2 : circle.cy + r * Math.sin(start + (j + 1 + FUDGE_FACTOR) * delta);
350
+ group.createPath().
351
+ moveTo(circle.cx, circle.cy).
352
+ lineTo(fansx, fansy).
353
+ arcTo(r, r, 0, delta > Math.PI, true, fanex, faney).
354
+ lineTo(circle.cx, circle.cy).
355
+ closePath().
356
+ setFill(this._pseudoRadialFill(specialFill, {x: circle.cx, y: circle.cy}, r, start + (j + 0.5) * delta, start + (j + 0.5) * delta));
357
+ }
358
+ group.createPath().
359
+ moveTo(circle.cx, circle.cy).
360
+ lineTo(x1, y1).
361
+ arcTo(r, r, 0, step > Math.PI, true, x2, y2).
362
+ lineTo(circle.cx, circle.cy).
363
+ closePath().
364
+ setStroke(theme.series.stroke);
365
+ shape = group;
366
+ }else{
367
+ shape = s.createPath().
368
+ moveTo(circle.cx, circle.cy).
369
+ lineTo(x1, y1).
370
+ arcTo(r, r, 0, step > Math.PI, true, x2, y2).
371
+ lineTo(circle.cx, circle.cy).
372
+ closePath().
373
+ setStroke(theme.series.stroke);
374
+ specialFill = theme.series.fill;
375
+ if(specialFill && specialFill.type === "radial"){
376
+ specialFill = this._shapeFill(specialFill, {x: circle.cx - circle.r, y: circle.cy - circle.r, width: 2 * circle.r, height: 2 * circle.r});
377
+ if(this.opt.radGrad === "linear"){
378
+ specialFill = this._pseudoRadialFill(specialFill, {x: circle.cx, y: circle.cy}, r, start, end);
379
+ }
380
+ }else if(specialFill && specialFill.type === "linear"){
381
+ specialFill = this._plotFill(specialFill, dim, offsets);
382
+ specialFill = this._shapeFill(specialFill, shape.getBoundingBox());
383
+ }
384
+ shape.setFill(specialFill);
385
+ }
386
+ this.dyn.push({fill: specialFill, stroke: theme.series.stroke});
387
+
388
+ if(events){
389
+ o = {
390
+ element: "slice",
391
+ index: i,
392
+ run: this.run,
393
+ shape: shape,
394
+ x: i,
395
+ y: typeof v == "number" ? v : v.y,
396
+ cx: circle.cx,
397
+ cy: circle.cy,
398
+ cr: r
399
+ };
400
+ this._connectEvents(o);
401
+ eventSeries[i] = o;
402
+ }
403
+
404
+ start = end;
405
+
406
+ return false; // continue
407
+ }, this);
408
+ // draw labels
409
+ if(this.opt.labels){
410
+ var isRtl = has("dojo-bidi") && this.chart.isRightToLeft();
411
+ if(this.opt.labelStyle == "default"){ // inside or outside based on labelOffset
412
+ start = startAngle;
413
+ arr.some(slices, function(slice, i){
414
+ if(slice <= 0){
415
+ // degenerated slice
416
+ return false; // continue
417
+ }
418
+ var theme = themes[i];
419
+ if(slice >= 1){
420
+ // whole pie
421
+ this.renderLabel(s, circle.cx, circle.cy + size / 2, labels[i], theme, this.opt.labelOffset > 0);
422
+ return true; // stop iteration
423
+ }
424
+ // calculate the geometry of the slice
425
+ var end = start + slice * 2 * Math.PI;
426
+ if(i + 1 == slices.length){
427
+ end = startAngle + 2 * Math.PI;
428
+ }
429
+ if(this.opt.omitLabels && end-start < 0.001){
430
+ return false; // continue
431
+ }
432
+ var labelAngle = (start + end) / 2,
433
+ x = circle.cx + labelR * Math.cos(labelAngle),
434
+ y = circle.cy + labelR * Math.sin(labelAngle) + size / 2;
435
+ // draw the label
436
+ this.renderLabel(s, isRtl ? dim.width - x : x, y, labels[i], theme, this.opt.labelOffset > 0);
437
+ start = end;
438
+ return false; // continue
439
+ }, this);
440
+ }else if(this.opt.labelStyle == "columns"){
441
+ start = startAngle;
442
+ var omitLabels = this.opt.omitLabels;
443
+ //calculate label angles
444
+ var labeledSlices = [];
445
+ arr.forEach(slices, function(slice, i){
446
+ var end = start + slice * 2 * Math.PI;
447
+ if(i + 1 == slices.length){
448
+ end = startAngle + 2 * Math.PI;
449
+ }
450
+ var labelAngle = (start + end) / 2;
451
+ labeledSlices.push({
452
+ angle: labelAngle,
453
+ left: Math.cos(labelAngle) < 0,
454
+ theme: themes[i],
455
+ index: i,
456
+ omit: omitLabels?end - start < 0.001:false
457
+ });
458
+ start = end;
459
+ });
460
+ //calculate label radius to each slice
461
+ var labelHeight = g._base._getTextBox("a",{ font: labelFont }).h;
462
+ this._getProperLabelRadius(labeledSlices, labelHeight, circle.r * 1.1);
463
+ //draw label and wiring
464
+ arr.forEach(labeledSlices, function(slice, i){
465
+ if(!slice.omit){
466
+ var leftColumn = circle.cx - circle.r * 2,
467
+ rightColumn = circle.cx + circle.r * 2,
468
+ labelWidth = g._base._getTextBox(labels[i], {font: slice.theme.series.font}).w,
469
+ x = circle.cx + slice.labelR * Math.cos(slice.angle),
470
+ y = circle.cy + slice.labelR * Math.sin(slice.angle),
471
+ jointX = (slice.left) ? (leftColumn + labelWidth) : (rightColumn - labelWidth),
472
+ labelX = (slice.left) ? leftColumn : jointX;
473
+ var wiring = s.createPath().moveTo(circle.cx + circle.r * Math.cos(slice.angle), circle.cy + circle.r * Math.sin(slice.angle));
474
+ if(Math.abs(slice.labelR * Math.cos(slice.angle)) < circle.r * 2 - labelWidth){
475
+ wiring.lineTo(x, y);
476
+ }
477
+ wiring.lineTo(jointX, y).setStroke(slice.theme.series.labelWiring);
478
+ this.renderLabel(s, isRtl ? dim.width - labelWidth - labelX : labelX, y, labels[i], slice.theme, false, "left");
479
+ }
480
+ },this);
481
+ }
482
+ }
483
+ // post-process events to restore the original indexing
484
+ var esi = 0;
485
+ this._eventSeries[this.run.name] = df.map(run, function(v){
486
+ return v <= 0 ? null : eventSeries[esi++];
487
+ });
488
+ // chart mirroring starts
489
+ if(has("dojo-bidi")){
490
+ this._checkOrientation(this.group, dim, offsets);
491
+ }
492
+ // chart mirroring ends
493
+ return this; // dojox/charting/plot2d/Pie
494
+ },
495
+ _getProperLabelRadius: function(slices, labelHeight, minRidius){
496
+ var leftCenterSlice, rightCenterSlice,
497
+ leftMinSIN = 1, rightMinSIN = 1;
498
+ if(slices.length == 1){
499
+ slices[0].labelR = minRidius;
500
+ return;
501
+ }
502
+ for(var i = 0; i < slices.length; i++){
503
+ var tempSIN = Math.abs(Math.sin(slices[i].angle));
504
+ if(slices[i].left){
505
+ if(leftMinSIN >= tempSIN){
506
+ leftMinSIN = tempSIN;
507
+ leftCenterSlice = slices[i];
508
+ }
509
+ }else{
510
+ if(rightMinSIN >= tempSIN){
511
+ rightMinSIN = tempSIN;
512
+ rightCenterSlice = slices[i];
513
+ }
514
+ }
515
+ }
516
+ leftCenterSlice.labelR = rightCenterSlice.labelR = minRidius;
517
+ this._calculateLabelR(leftCenterSlice, slices, labelHeight);
518
+ this._calculateLabelR(rightCenterSlice, slices, labelHeight);
519
+ },
520
+ _calculateLabelR: function(firstSlice, slices, labelHeight){
521
+ var i = firstSlice.index,length = slices.length,
522
+ currentLabelR = firstSlice.labelR, nextLabelR;
523
+ while(!(slices[i%length].left ^ slices[(i+1)%length].left)){
524
+ if(!slices[(i + 1) % length].omit){
525
+ nextLabelR = (Math.sin(slices[i % length].angle) * currentLabelR + ((slices[i % length].left) ? (-labelHeight) : labelHeight)) /
526
+ Math.sin(slices[(i + 1) % length].angle);
527
+ currentLabelR = (nextLabelR < firstSlice.labelR) ? firstSlice.labelR : nextLabelR;
528
+ slices[(i + 1) % length].labelR = currentLabelR;
529
+ }
530
+ i++;
531
+ }
532
+ i = firstSlice.index;
533
+ var j = (i == 0)?length-1 : i - 1;
534
+ while(!(slices[i].left ^ slices[j].left)){
535
+ if(!slices[j].omit){
536
+ nextLabelR = (Math.sin(slices[i].angle) * currentLabelR + ((slices[i].left) ? labelHeight : (-labelHeight))) /
537
+ Math.sin(slices[j].angle);
538
+ currentLabelR = (nextLabelR < firstSlice.labelR) ? firstSlice.labelR : nextLabelR;
539
+ slices[j].labelR = currentLabelR;
540
+ }
541
+ i--;j--;
542
+ i = (i < 0)?i+slices.length:i;
543
+ j = (j < 0)?j+slices.length:j;
544
+ }
545
+ }
546
+ });
547
+ });
@@ -0,0 +1,134 @@
1
+ //>>built
2
+ define("dojox/charting/plot2d/Scatter",["dojo/_base/lang","dojo/_base/array","dojo/_base/declare","dojo/has","./CartesianBase","./_PlotEvents","./common","dojox/lang/functional","dojox/lang/functional/reversed","dojox/lang/utils","dojox/gfx/fx","dojox/gfx/gradutils"],function(_1,_2,_3,_4,_5,_6,dc,df,_7,du,fx,_8){
3
+ var _9=_7.lambda("item.purgeGroup()");
4
+ return _3("dojox.charting.plot2d.Scatter",[_5,_6],{defaultParams:{shadows:null,animate:null},optionalParams:{markerStroke:{},markerOutline:{},markerShadow:{},markerFill:{},markerFont:"",markerFontColor:"",styleFunc:null},constructor:function(_a,_b){
5
+ this.opt=_1.clone(_1.mixin(this.opt,this.defaultParams));
6
+ du.updateWithObject(this.opt,_b);
7
+ du.updateWithPattern(this.opt,_b,this.optionalParams);
8
+ this.animate=this.opt.animate;
9
+ },render:function(_c,_d){
10
+ if(this.zoom&&!this.isDataDirty()){
11
+ return this.performZoom(_c,_d);
12
+ }
13
+ this.resetEvents();
14
+ this.dirty=this.isDirty();
15
+ var s;
16
+ if(this.dirty){
17
+ _2.forEach(this.series,_9);
18
+ this._eventSeries={};
19
+ this.cleanGroup();
20
+ s=this.getGroup();
21
+ df.forEachRev(this.series,function(_e){
22
+ _e.cleanGroup(s);
23
+ });
24
+ }
25
+ var t=this.chart.theme,_f=this.events();
26
+ for(var i=this.series.length-1;i>=0;--i){
27
+ var run=this.series[i];
28
+ if(!this.dirty&&!run.dirty){
29
+ t.skip();
30
+ this._reconnectEvents(run.name);
31
+ continue;
32
+ }
33
+ run.cleanGroup();
34
+ if(!run.data.length){
35
+ run.dirty=false;
36
+ t.skip();
37
+ continue;
38
+ }
39
+ var _10=t.next("marker",[this.opt,run]),_11,ht=this._hScaler.scaler.getTransformerFromModel(this._hScaler),vt=this._vScaler.scaler.getTransformerFromModel(this._vScaler);
40
+ if(run.hidden){
41
+ run.dyn.marker=_10.symbol;
42
+ run.dyn.markerFill=_10.marker.fill;
43
+ run.dyn.markerStroke=_10.marker.stroke;
44
+ continue;
45
+ }
46
+ s=run.group;
47
+ if(typeof run.data[0]=="number"){
48
+ _11=_2.map(run.data,function(v,i){
49
+ return {x:ht(i+1)+_d.l,y:_c.height-_d.b-vt(v)};
50
+ },this);
51
+ }else{
52
+ _11=_2.map(run.data,function(v,i){
53
+ return {x:ht(v.x)+_d.l,y:_c.height-_d.b-vt(v.y)};
54
+ },this);
55
+ }
56
+ var _12=new Array(_11.length),_13=new Array(_11.length),_14=new Array(_11.length);
57
+ _2.forEach(_11,function(c,i){
58
+ var _15=run.data[i],_16;
59
+ if(this.opt.styleFunc||typeof _15!="number"){
60
+ var _17=typeof _15!="number"?[_15]:[];
61
+ if(this.opt.styleFunc){
62
+ _17.push(this.opt.styleFunc(_15));
63
+ }
64
+ _16=t.addMixin(_10,"marker",_17,true);
65
+ }else{
66
+ _16=t.post(_10,"marker");
67
+ }
68
+ var _18="M"+c.x+" "+c.y+" "+_16.symbol;
69
+ if(_16.marker.shadow){
70
+ _12[i]=s.createPath("M"+(c.x+_16.marker.shadow.dx)+" "+(c.y+_16.marker.shadow.dy)+" "+_16.symbol).setStroke(_16.marker.shadow).setFill(_16.marker.shadow.color);
71
+ if(this.animate){
72
+ this._animateScatter(_12[i],_c.height-_d.b);
73
+ }
74
+ }
75
+ if(_16.marker.outline){
76
+ var _19=dc.makeStroke(_16.marker.outline);
77
+ _19.width=2*_19.width+_16.marker.stroke.width;
78
+ _14[i]=s.createPath(_18).setStroke(_19);
79
+ if(this.animate){
80
+ this._animateScatter(_14[i],_c.height-_d.b);
81
+ }
82
+ }
83
+ var _1a=dc.makeStroke(_16.marker.stroke),_1b=this._plotFill(_16.marker.fill,_c,_d);
84
+ if(_1b&&(_1b.type==="linear"||_1b.type=="radial")){
85
+ var _1c=_8.getColor(_1b,{x:c.x,y:c.y});
86
+ if(_1a){
87
+ _1a.color=_1c;
88
+ }
89
+ _13[i]=s.createPath(_18).setStroke(_1a).setFill(_1c);
90
+ }else{
91
+ _13[i]=s.createPath(_18).setStroke(_1a).setFill(_1b);
92
+ }
93
+ if(this.opt.labels){
94
+ var _1d=_13[i].getBoundingBox();
95
+ this.createLabel(s,_15,_1d,_16);
96
+ }
97
+ if(this.animate){
98
+ this._animateScatter(_13[i],_c.height-_d.b);
99
+ }
100
+ },this);
101
+ if(_13.length){
102
+ run.dyn.marker=_10.symbol;
103
+ run.dyn.markerStroke=_13[_13.length-1].getStroke();
104
+ run.dyn.markerFill=_13[_13.length-1].getFill();
105
+ }
106
+ if(_f){
107
+ var _1e=new Array(_13.length);
108
+ _2.forEach(_13,function(s,i){
109
+ var o={element:"marker",index:i,run:run,shape:s,outline:_14&&_14[i]||null,shadow:_12&&_12[i]||null,cx:_11[i].x,cy:_11[i].y};
110
+ if(typeof run.data[0]=="number"){
111
+ o.x=i+1;
112
+ o.y=run.data[i];
113
+ }else{
114
+ o.x=run.data[i].x;
115
+ o.y=run.data[i].y;
116
+ }
117
+ this._connectEvents(o);
118
+ _1e[i]=o;
119
+ },this);
120
+ this._eventSeries[run.name]=_1e;
121
+ }else{
122
+ delete this._eventSeries[run.name];
123
+ }
124
+ run.dirty=false;
125
+ }
126
+ this.dirty=false;
127
+ if(_4("dojo-bidi")){
128
+ this._checkOrientation(this.group,_c,_d);
129
+ }
130
+ return this;
131
+ },_animateScatter:function(_1f,_20){
132
+ fx.animateTransform(_1.delegate({shape:_1f,duration:1200,transform:[{name:"translate",start:[0,_20],end:[0,0]},{name:"scale",start:[0,0],end:[1,1]},{name:"original"}]},this.animate)).play();
133
+ }});
134
+ });