sea-chart 0.0.1

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 (214) hide show
  1. package/README.md +4 -0
  2. package/lib/assets/icons/area-chart.svg +10 -0
  3. package/lib/assets/icons/bar-chart.svg +12 -0
  4. package/lib/assets/icons/card.svg +22 -0
  5. package/lib/assets/icons/combination-chart.svg +17 -0
  6. package/lib/assets/icons/dtable-logo.svg +16 -0
  7. package/lib/assets/icons/facet-chart.svg +12 -0
  8. package/lib/assets/icons/gauge.svg +18 -0
  9. package/lib/assets/icons/heat-map.svg +14 -0
  10. package/lib/assets/icons/histogram.svg +12 -0
  11. package/lib/assets/icons/line-chart.svg +12 -0
  12. package/lib/assets/icons/map.svg +20 -0
  13. package/lib/assets/icons/pie-chart.svg +11 -0
  14. package/lib/assets/icons/rectangular-tree-diagram.svg +10 -0
  15. package/lib/assets/icons/scatter-chart.svg +15 -0
  16. package/lib/assets/icons/type-change.svg +17 -0
  17. package/lib/assets/img/area-chart.png +0 -0
  18. package/lib/assets/img/area-group-chart.png +0 -0
  19. package/lib/assets/img/bar-group.png +0 -0
  20. package/lib/assets/img/bar-stack.png +0 -0
  21. package/lib/assets/img/bar.png +0 -0
  22. package/lib/assets/img/combination-chart.png +0 -0
  23. package/lib/assets/img/compared-chart.png +0 -0
  24. package/lib/assets/img/completeness-chart.png +0 -0
  25. package/lib/assets/img/custom-bar.png +0 -0
  26. package/lib/assets/img/dashboard-chart.png +0 -0
  27. package/lib/assets/img/group-completeness-chart.png +0 -0
  28. package/lib/assets/img/group_line.png +0 -0
  29. package/lib/assets/img/heat-map.png +0 -0
  30. package/lib/assets/img/horizontal-bar.png +0 -0
  31. package/lib/assets/img/horizontal-group-bar.png +0 -0
  32. package/lib/assets/img/line.png +0 -0
  33. package/lib/assets/img/map-bubble.png +0 -0
  34. package/lib/assets/img/map.png +0 -0
  35. package/lib/assets/img/mirror.png +0 -0
  36. package/lib/assets/img/number-card.png +0 -0
  37. package/lib/assets/img/pie.png +0 -0
  38. package/lib/assets/img/pivot-table.png +0 -0
  39. package/lib/assets/img/ring.png +0 -0
  40. package/lib/assets/img/scatter.png +0 -0
  41. package/lib/assets/img/stacked-horizontal-bar.png +0 -0
  42. package/lib/assets/img/treemap.png +0 -0
  43. package/lib/assets/img/trend-chart.png +0 -0
  44. package/lib/assets/img/world-map-bubble.png +0 -0
  45. package/lib/assets/img/world-map.png +0 -0
  46. package/lib/components/collaborator/index.js +24 -0
  47. package/lib/components/formatter/area.js +162 -0
  48. package/lib/components/formatter/bar-group.js +160 -0
  49. package/lib/components/formatter/bar.js +150 -0
  50. package/lib/components/formatter/basic-number-card.js +138 -0
  51. package/lib/components/formatter/chart-component.js +266 -0
  52. package/lib/components/formatter/combination.js +407 -0
  53. package/lib/components/formatter/dashboard.js +182 -0
  54. package/lib/components/formatter/horizontal-bar-group.js +161 -0
  55. package/lib/components/formatter/horizontal-bar.js +152 -0
  56. package/lib/components/formatter/horizontal-component.js +91 -0
  57. package/lib/components/formatter/index.js +181 -0
  58. package/lib/components/formatter/line-group.js +157 -0
  59. package/lib/components/formatter/line.js +170 -0
  60. package/lib/components/formatter/pie.js +201 -0
  61. package/lib/components/formatter/ring.js +277 -0
  62. package/lib/components/formatter/table/index.css +103 -0
  63. package/lib/components/formatter/table/index.js +42 -0
  64. package/lib/components/formatter/table/one-dimension-table-no-numeric-columns.js +145 -0
  65. package/lib/components/formatter/table/one-dimension-table-with-numeric-columns.js +193 -0
  66. package/lib/components/formatter/table/pivot-table-display-name.js +249 -0
  67. package/lib/components/formatter/table/two-dimension-table.js +241 -0
  68. package/lib/components/formatter/treemap.js +213 -0
  69. package/lib/components/icon/index.css +5 -0
  70. package/lib/components/icon/index.js +22 -0
  71. package/lib/components/index.js +5 -0
  72. package/lib/components/loading/index.css +54 -0
  73. package/lib/components/loading/index.js +10 -0
  74. package/lib/components/number-input/index.js +31 -0
  75. package/lib/components/pixel-editor/index.css +29 -0
  76. package/lib/components/pixel-editor/index.js +42 -0
  77. package/lib/components/select-group/index.css +67 -0
  78. package/lib/components/select-group/index.js +63 -0
  79. package/lib/components/settings/advance-bar-settings/data-settings.js +120 -0
  80. package/lib/components/settings/advance-bar-settings/index.js +3 -0
  81. package/lib/components/settings/advance-bar-settings/style-settings.js +149 -0
  82. package/lib/components/settings/bar-settings/data-settings.js +137 -0
  83. package/lib/components/settings/bar-settings/index.js +3 -0
  84. package/lib/components/settings/bar-settings/style-settings.js +163 -0
  85. package/lib/components/settings/basic-number-card/data-settings.js +121 -0
  86. package/lib/components/settings/basic-number-card/index.js +3 -0
  87. package/lib/components/settings/basic-number-card/style-settings.js +42 -0
  88. package/lib/components/settings/combination-settings/data-settings.js +256 -0
  89. package/lib/components/settings/combination-settings/index.js +3 -0
  90. package/lib/components/settings/combination-settings/style-settings.js +183 -0
  91. package/lib/components/settings/dashboard-settings/data-settings.js +167 -0
  92. package/lib/components/settings/dashboard-settings/index.js +2 -0
  93. package/lib/components/settings/data-settings.js +67 -0
  94. package/lib/components/settings/horizontal-bar-settings/data-settings.js +45 -0
  95. package/lib/components/settings/horizontal-bar-settings/index.js +3 -0
  96. package/lib/components/settings/horizontal-bar-settings/style-settings.js +38 -0
  97. package/lib/components/settings/index.css +73 -0
  98. package/lib/components/settings/index.js +74 -0
  99. package/lib/components/settings/pie-settings/data-settings.js +123 -0
  100. package/lib/components/settings/pie-settings/index.js +3 -0
  101. package/lib/components/settings/pie-settings/style-settings.js +123 -0
  102. package/lib/components/settings/style-settings.js +100 -0
  103. package/lib/components/settings/table-settings/data-settings.js +488 -0
  104. package/lib/components/settings/table-settings/index.js +2 -0
  105. package/lib/components/settings/time-comparison-settings/data-settings.js +157 -0
  106. package/lib/components/settings/time-comparison-settings/index.js +3 -0
  107. package/lib/components/settings/time-comparison-settings/style-settings.js +191 -0
  108. package/lib/components/settings/widgets/basic-summary/index.css +12 -0
  109. package/lib/components/settings/widgets/basic-summary/index.js +173 -0
  110. package/lib/components/settings/widgets/common-data-settings.js +42 -0
  111. package/lib/components/settings/widgets/data-filter/index.css +17 -0
  112. package/lib/components/settings/widgets/data-filter/index.js +76 -0
  113. package/lib/components/settings/widgets/data-sort.js +38 -0
  114. package/lib/components/settings/widgets/date-summary-item.js +126 -0
  115. package/lib/components/settings/widgets/display-values-settings/index.css +13 -0
  116. package/lib/components/settings/widgets/display-values-settings/index.js +37 -0
  117. package/lib/components/settings/widgets/divider/index.css +4 -0
  118. package/lib/components/settings/widgets/divider/index.js +10 -0
  119. package/lib/components/settings/widgets/font-settings/font-size-settings.js +31 -0
  120. package/lib/components/settings/widgets/font-settings/font-weight-settings.js +46 -0
  121. package/lib/components/settings/widgets/font-settings/index.js +3 -0
  122. package/lib/components/settings/widgets/group-by.js +168 -0
  123. package/lib/components/settings/widgets/label-color.js +30 -0
  124. package/lib/components/settings/widgets/min-max-setting.js +64 -0
  125. package/lib/components/settings/widgets/mininum-slice-percent.js +72 -0
  126. package/lib/components/settings/widgets/numeric-summary-item.js +109 -0
  127. package/lib/components/settings/widgets/select-table/index.css +0 -0
  128. package/lib/components/settings/widgets/select-table/index.js +49 -0
  129. package/lib/components/settings/widgets/stack.js +58 -0
  130. package/lib/components/settings/widgets/statistic-type/index.css +31 -0
  131. package/lib/components/settings/widgets/statistic-type/index.js +54 -0
  132. package/lib/components/settings/widgets/summary-method-setting.js +80 -0
  133. package/lib/components/settings/widgets/summary-settings.js +394 -0
  134. package/lib/components/settings/widgets/switch/index.css +37 -0
  135. package/lib/components/settings/widgets/switch/index.js +21 -0
  136. package/lib/components/settings/widgets/text-horizontal-settings.js +23 -0
  137. package/lib/components/settings/widgets/time-picker.js +182 -0
  138. package/lib/components/settings/widgets/title-settings/index.js +58 -0
  139. package/lib/components/settings/widgets/title-settings/title-text.js +31 -0
  140. package/lib/components/settings/widgets/x-axios.js +0 -0
  141. package/lib/components/settings/widgets/y-axis-group-settings.js +399 -0
  142. package/lib/components/types-dialog/index.css +97 -0
  143. package/lib/components/types-dialog/index.js +127 -0
  144. package/lib/constants/geolocation.js +11 -0
  145. package/lib/constants/index.js +164 -0
  146. package/lib/constants/model.js +167 -0
  147. package/lib/constants/style.js +13 -0
  148. package/lib/constants/type-image.js +32 -0
  149. package/lib/constants/type.js +97 -0
  150. package/lib/context.js +49 -0
  151. package/lib/index.js +6 -0
  152. package/lib/intl.js +37 -0
  153. package/lib/layout/index.js +4 -0
  154. package/lib/layout/statistic/index.css +53 -0
  155. package/lib/layout/statistic/index.js +190 -0
  156. package/lib/layout/title/index.css +3 -0
  157. package/lib/layout/title/index.js +41 -0
  158. package/lib/locale/index.js +11 -0
  159. package/lib/locale/lang/de.js +141 -0
  160. package/lib/locale/lang/en.js +143 -0
  161. package/lib/locale/lang/es.js +141 -0
  162. package/lib/locale/lang/fr.js +141 -0
  163. package/lib/locale/lang/pt.js +141 -0
  164. package/lib/locale/lang/ru.js +141 -0
  165. package/lib/locale/lang/zh_CN.js +143 -0
  166. package/lib/model/area-group.js +51 -0
  167. package/lib/model/area.js +42 -0
  168. package/lib/model/bar-group.js +54 -0
  169. package/lib/model/bar-stack.js +51 -0
  170. package/lib/model/bar.js +48 -0
  171. package/lib/model/base-model.js +11 -0
  172. package/lib/model/basic-number-card.js +32 -0
  173. package/lib/model/combination.js +48 -0
  174. package/lib/model/compare-bar.js +49 -0
  175. package/lib/model/completeness-group.js +34 -0
  176. package/lib/model/completeness.js +28 -0
  177. package/lib/model/dashboard.js +26 -0
  178. package/lib/model/generic-model.js +235 -0
  179. package/lib/model/heat-map.js +33 -0
  180. package/lib/model/horizontal-bar.js +48 -0
  181. package/lib/model/horizontal-group-bar.js +53 -0
  182. package/lib/model/index.js +36 -0
  183. package/lib/model/line-group.js +54 -0
  184. package/lib/model/line.js +48 -0
  185. package/lib/model/map-bubble.js +37 -0
  186. package/lib/model/map.js +37 -0
  187. package/lib/model/mirror.js +36 -0
  188. package/lib/model/pie.js +36 -0
  189. package/lib/model/ring.js +36 -0
  190. package/lib/model/scatter.js +29 -0
  191. package/lib/model/stacked-horizontal-bar.js +42 -0
  192. package/lib/model/statistic.js +22 -0
  193. package/lib/model/table.js +33 -0
  194. package/lib/model/tree-map.js +30 -0
  195. package/lib/model/trend.js +34 -0
  196. package/lib/model/user.js +22 -0
  197. package/lib/model/world-map-bubble.js +36 -0
  198. package/lib/model/world-map.js +36 -0
  199. package/lib/utils/cell-format-utils.js +41 -0
  200. package/lib/utils/chart.js +6 -0
  201. package/lib/utils/collaborator-utils.js +40 -0
  202. package/lib/utils/column-utils.js +247 -0
  203. package/lib/utils/custom-g2.js +612 -0
  204. package/lib/utils/data-filter/filter-item-utils.js +80 -0
  205. package/lib/utils/data-filter/filters-utils.js +406 -0
  206. package/lib/utils/data-filter/index.js +3 -0
  207. package/lib/utils/date-translate.js +66 -0
  208. package/lib/utils/index.js +50 -0
  209. package/lib/utils/key-generator.js +13 -0
  210. package/lib/utils/object-utils.js +61 -0
  211. package/lib/utils/options-utils.js +61 -0
  212. package/lib/utils/statistic-column-2-sql-column-utils.js +499 -0
  213. package/lib/utils/statistic-utils.js +1685 -0
  214. package/package.json +160 -0
package/README.md ADDED
@@ -0,0 +1,4 @@
1
+ # seatable-statistic
2
+
3
+
4
+
@@ -0,0 +1,10 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M1.5,1h2C3.8,1,4,1.2,4,1.5V28H1V1.5C1,1.2,1.2,1,1.5,1z M1,28h29.5c0.3,0,0.5,0.2,0.5,0.5v2
9
+ c0,0.3-0.2,0.5-0.5,0.5H1V28z M29,9.3L18.1,19l-6.5-4.3L6,21.3V27h23V9.3z"/>
10
+ </svg>
@@ -0,0 +1,12 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M4,10h23.5c0.3,0,0.5,0.2,0.5,0.5v3c0,0.3-0.2,0.5-0.5,0.5H4V10z M4,22h12.5c0.3,0,0.5,0.2,0.5,0.5v3
9
+ c0,0.3-0.2,0.5-0.5,0.5H4V22z M4,4h14.5C18.8,4,19,4.2,19,4.5v3C19,7.8,18.8,8,18.5,8H4V4z M4,16h9.5c0.3,0,0.5,0.2,0.5,0.5v3
10
+ c0,0.3-0.2,0.5-0.5,0.5H4V16z M1.5,1h2C3.8,1,4,1.2,4,1.5V28H1V1.5C1,1.2,1.2,1,1.5,1z M1,28h29.5c0.3,0,0.5,0.2,0.5,0.5v2
11
+ c0,0.3-0.2,0.5-0.5,0.5H1V28z"/>
12
+ </svg>
@@ -0,0 +1,22 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M30,2c1.1,0,2,0.9,2,2v24c0,1.1-0.9,2-2,2H2c-1.1,0-2-0.9-2-2V4c0-1.1,0.9-2,2-2H30z M27,6H5C4.4,6,4,6.4,4,7
9
+ v18c0,0.6,0.4,1,1,1h22c0.6,0,1-0.4,1-1V7C28,6.4,27.6,6,27,6z"/>
10
+ <path class="st0" d="M9,21c0.6,0,1,0.4,1,1s-0.4,1-1,1s-1-0.4-1-1S8.4,21,9,21z M23,21c0.6,0,1,0.4,1,1s-0.4,1-1,1H12
11
+ c-0.6,0-1-0.4-1-1s0.4-1,1-1H23z M21.3,10c0.8,0,1.5,0.2,1.8,0.6c0.4,0.4,0.6,0.8,0.6,1.4c0,0.3-0.1,0.6-0.2,0.9
12
+ c-0.2,0.3-0.4,0.5-0.7,0.7l0.6,0.3c0.2,0.2,0.4,0.4,0.5,0.6c0.1,0.3,0.2,0.6,0.2,0.9c0,0.5-0.1,0.9-0.3,1.3c-0.2,0.4-0.5,0.7-0.9,1
13
+ C22.5,17.9,22,18,21.4,18s-1.1-0.1-1.4-0.2c-0.3-0.2-0.6-0.4-0.8-0.7c-0.2-0.4-0.4-0.8-0.5-1.2l1.8-0.3v0.2c0,0.2,0.1,0.5,0.3,0.7
14
+ c0.1,0.2,0.3,0.2,0.6,0.2c0.2,0,0.5-0.1,0.6-0.3c0.2-0.2,0.3-0.5,0.2-0.8c0-0.4-0.1-0.6-0.2-0.8c-0.2-0.2-0.4-0.3-0.6-0.3
15
+ c-0.1,0-0.3,0-0.6,0.1l0.1-1.5h0.2c0.2,0,0.4-0.1,0.6-0.3s0.2-0.4,0.2-0.6c0-0.2-0.1-0.4-0.2-0.6c-0.1-0.1-0.3-0.2-0.5-0.2
16
+ s-0.4,0.1-0.5,0.2c-0.1,0.2-0.2,0.4-0.3,0.8L18.7,12l0.1-0.3c0.2-0.5,0.4-0.9,0.7-1.2C20,10.2,20.5,10,21.3,10z M10.7,10v7.9H8.9
17
+ v-5.2C8.6,13,8.3,13.2,8,13.4v-1.8c0.5-0.4,1-0.9,1.2-1.6C9.2,10,10.7,10,10.7,10z M15.3,10c0.6,0,1.1,0.1,1.5,0.3s0.6,0.4,0.8,0.8
18
+ c0.2,0.4,0.3,0.8,0.3,1.2c0,0.5-0.1,0.9-0.3,1.4c-0.2,0.4-0.7,0.9-1.3,1.4c-0.2,0.2-0.5,0.4-0.7,0.6c-0.1,0.1-0.3,0.3-0.4,0.5H18V18
19
+ h-5.4l0.1-0.4c0.1-0.5,0.3-1,0.5-1.4c0.3-0.6,0.9-1.2,1.8-2c0.5-0.5,0.9-0.8,1-1.1c0.1-0.2,0.2-0.4,0.2-0.7c0-0.2-0.1-0.4-0.2-0.6
20
+ c-0.1-0.2-0.3-0.3-0.6-0.3c-0.2,0-0.4,0.1-0.6,0.3c-0.1,0.2-0.2,0.5-0.3,0.9l-1.8-0.2l0.1-0.3c0.1-0.4,0.2-0.8,0.3-1.1
21
+ c0.2-0.3,0.5-0.6,0.8-0.8S14.7,10,15.3,10z"/>
22
+ </svg>
@@ -0,0 +1,17 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M13,28V15.5c0-0.2,0.2-0.5,0.4-0.5h3.3c0.2,0,0.4,0.2,0.4,0.5V28H13z M19,28v-9.7c0-0.2,0.2-0.3,0.4-0.3h3.3
9
+ c0.2,0,0.4,0.2,0.4,0.3V28H19z M28.6,13c0.2,0,0.4,0.1,0.4,0.3V28h-4V13.3c0-0.1,0.2-0.3,0.4-0.3H28.6z M10.6,20
10
+ c0.2,0,0.4,0.2,0.4,0.5V28H7v-7.5C7,20.2,7.2,20,7.4,20H10.6z M1.5,1h2C3.8,1,4,1.2,4,1.5V28H1V1.5C1,1.2,1.2,1,1.5,1z M1,28h29.5
11
+ c0.3,0,0.5,0.2,0.5,0.5v2c0,0.3-0.2,0.5-0.5,0.5H1V28z"/>
12
+ <path class="st0" d="M26.9,7C28.1,7,29,8,29,9.1c0,1.2-1,2.1-2.1,2.1c-0.4,0-0.8-0.1-1.2-0.4L22.9,13c0.4,1-0.1,2.3-1.1,2.7
13
+ c-0.8,0.3-1.8,0-2.4-0.6c-0.4-0.4-0.6-0.9-0.5-1.5l-2.4-1.2c-0.7,0.7-1.7,0.7-2.5,0.3l-3,2.6c0.5,1,0.1,2.3-1,2.8
14
+ c-0.9,0.4-1.8,0.1-2.5-0.5c-0.7-0.9-0.6-2.2,0.3-2.9c0.7-0.6,1.6-0.7,2.4-0.2l3-2.6c-0.5-1-0.1-2.3,1-2.8c0.3-0.1,0.6-0.2,0.9-0.2
15
+ c1.2,0,2.1,1,2.1,2.1c0,0.1,0,0.3-0.1,0.5l2.3,1.2c0.7-0.8,1.9-1,2.8-0.4l2.9-2.2c-0.4-1,0.1-2.3,1.1-2.7C26.4,7.1,26.6,7,26.9,7z"
16
+ />
17
+ </svg>
@@ -0,0 +1,16 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M9.4,21.6c0.6,0,1,0.4,1,1V29c0,0.6-0.4,1-1,1H3c-0.6,0-1-0.4-1-1v-6.4c0-0.6,0.4-1,1-1H9.4z M19.2,21.6
9
+ c0.6,0,1,0.4,1,1V29c0,0.6-0.4,1-1,1h-6.4c-0.6,0-1-0.4-1-1v-6.4c0-0.6,0.4-1,1-1H19.2z M29,21.6c0.6,0,1,0.4,1,1V29
10
+ c0,0.6-0.4,1-1,1h-6.4c-0.6,0-1-0.4-1-1v-6.4c0-0.6,0.4-1,1-1H29z M9.4,11.8c0.6,0,1,0.4,1,1v6.4c0,0.6-0.4,1-1,1H3
11
+ c-0.6,0-1-0.4-1-1v-6.4c0-0.6,0.4-1,1-1C3,11.8,9.4,11.8,9.4,11.8z M29,11.8c0.6,0,1,0.4,1,1v6.4c0,0.6-0.4,1-1,1h-6.4
12
+ c-0.6,0-1-0.4-1-1v-6.4c0-0.6,0.4-1,1-1C22.6,11.8,29,11.8,29,11.8z M19.2,11.8c0.6,0,1,0.4,1,1v6.4c0,0.6-0.4,1-1,1h-6.4
13
+ c-0.6,0-1-0.4-1-1v-6.4c0-0.6,0.4-1,1-1C12.8,11.8,19.2,11.8,19.2,11.8z M9.4,2c0.6,0,1,0.4,1,1v6.4c0,0.6-0.4,1-1,1H3
14
+ c-0.6,0-1-0.4-1-1V3c0-0.6,0.4-1,1-1H9.4z M19.2,2c0.6,0,1,0.4,1,1v6.4c0,0.6-0.4,1-1,1h-6.4c-0.6,0-1-0.4-1-1V3c0-0.6,0.4-1,1-1
15
+ H19.2z M29,2c0.6,0,1,0.4,1,1v6.4c0,0.6-0.4,1-1,1h-6.4c-0.6,0-1-0.4-1-1V3c0-0.6,0.4-1,1-1H29z"/>
16
+ </svg>
@@ -0,0 +1,12 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M15,1h2c0.3,0,0.5,0.2,0.5,0.5V28h-3V1.5C14.5,1.2,14.7,1,15,1z M0,28h32v3H0V28z M11.5,4C11.8,4,12,4.2,12,4.5
9
+ V28H9.3v-3H4.7v3H2V4.5C2,4.2,2.2,4,2.5,4H11.5z M9.3,19H4.7v3h4.5v-3H9.3z M9.3,13H4.7v3h4.5v-3H9.3z M9.3,7H4.7v3h4.5V7H9.3z
10
+ M29.5,4C29.8,4,30,4.2,30,4.5V28h-2.7v-3h-4.5v3H20V4.5C20,4.2,20.2,4,20.5,4H29.5z M27.3,19h-4.5v3h4.5V19z M27.3,13h-4.5v3h4.5
11
+ V13z M27.3,7h-4.5v3h4.5V7z"/>
12
+ </svg>
@@ -0,0 +1,18 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M29.3,21.1h-1.8c-0.5,0-0.9-0.4-0.9-0.9s0.4-0.9,0.9-0.9h1.8c0.5,0,0.9,0.4,0.9,0.9S29.8,21.1,29.3,21.1z
9
+ M25.2,14.8c-0.3-0.4-0.1-1,0.3-1.2l1.5-0.9c0.4-0.2,1-0.1,1.2,0.4c0.2,0.4,0.1,0.9-0.3,1.2l-1.5,0.9C26,15.4,25.5,15.3,25.2,14.8z
10
+ M17.6,20.7c0,0.9-0.5,1.8-1.3,2.3c-0.6,0.4-1.3,0.5-2.1,0.3c-0.7-0.2-1.3-0.6-1.7-1.2S12,20.7,12.1,20c0.2-0.8,0.6-1.3,1.2-1.8
11
+ c0.9-0.6,1.9-0.6,2.8,0l7.5-3.1C23.6,15.1,17.6,20.7,17.6,20.7z M10.7,10.9c-0.4,0.2-1,0.1-1.2-0.3L8.6,9C8.3,8.5,8.5,8,8.9,7.7
12
+ C9.3,7.5,9.8,7.6,10.1,8L11,9.6C11.2,10.1,11.1,10.6,10.7,10.9z M6.8,14.8c-0.2,0.4-0.8,0.6-1.2,0.4L4,14.3C3.6,14,3.4,13.5,3.7,13
13
+ c0.2-0.4,0.8-0.6,1.2-0.4l1.5,0.9C6.9,13.8,7,14.4,6.8,14.8z M4.4,21.1H2.7c-0.5,0-0.9-0.4-0.9-0.9s0.4-0.9,0.9-0.9h1.8
14
+ c0.5,0,0.9,0.4,0.9,0.9C5.3,20.7,5,21.1,4.4,21.1z M15.1,6.7c0-0.5,0.4-0.9,0.9-0.9c0.5,0,0.9,0.4,0.9,0.9v1.8
15
+ c0,0.5-0.4,0.9-0.9,0.9c-0.2,0-0.5-0.1-0.6-0.3c-0.2-0.2-0.3-0.4-0.3-0.6V6.7z M21,9.6L21.9,8c0.2-0.4,0.8-0.6,1.2-0.3
16
+ C23.5,8,23.7,8.5,23.4,9l-0.9,1.5c-0.2,0.4-0.8,0.6-1.2,0.3C20.9,10.6,20.8,10.1,21,9.6z M26,7.7c-5.8-4.9-14.2-4.9-20,0
17
+ C0.1,12.6-1.7,21,1.7,28h28.7C33.7,21,31.9,12.6,26,7.7z"/>
18
+ </svg>
@@ -0,0 +1,14 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32.1 32" style="enable-background:new 0 0 32.1 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M30.2,18.6c-5.2-5.2-4.7-7.1-3.9-9.2s-1.1-11.2-8-7.6s-4.8,8.3-9.8,8.1c-4.9-0.2-11,2.4-7.4,11.8
9
+ c1.4,3.7,4.1,7.3,8.2,7.8s11-0.8,15.1,1.2S35.4,23.8,30.2,18.6z M23.4,28.3c-3.5-1.6-9.2-0.7-12.7-1c-3.5-0.4-6.2-2.8-7.4-5.8
10
+ c-3-7.6,2.8-9.8,6.9-9.7s2.4-4.6,8.3-7.5s6.3,4.7,5.6,6.4c-0.8,1.9-0.7,3.8,3.8,8.1C32.3,22.9,26.9,29.9,23.4,28.3z"/>
11
+ <path class="st0" d="M5.9,17.3c-1.9,1.6-0.3,5.5,2.2,6.3c2.4,0.8,4.9-0.1,6.8-1.7c1.9-1.7,1.6-7.3-1.5-5.9
12
+ C10.2,17.5,9.8,14,5.9,17.3z M19.7,6.4c-2.3,0.6-4.4,4.4-3.5,6.1s2.9,4.7,2.2,6.9s-0.2,4.8,2,5.6s6.8,0.5,6.8-1.8s-5.4-4.7-5.6-8.4
13
+ C21.5,11,23.3,5.4,19.7,6.4z"/>
14
+ </svg>
@@ -0,0 +1,12 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M1.5,1h2C3.8,1,4,1.2,4,1.5V28H1V1.5C1,1.2,1.2,1,1.5,1z M7.5,20h3c0.3,0,0.5,0.2,0.5,0.5V28H7v-7.5
9
+ C7,20.2,7.2,20,7.5,20z M13.5,7h3C16.8,7,17,7.2,17,7.5V28h-4V7.5C13,7.2,13.2,7,13.5,7z M25.5,14h3c0.3,0,0.5,0.2,0.5,0.5V28h-4
10
+ V14.5C25,14.2,25.2,14,25.5,14z M19.5,17h3c0.3,0,0.5,0.2,0.5,0.5V28h-4V17.5C19,17.2,19.2,17,19.5,17z M1,28h29.5
11
+ c0.3,0,0.5,0.2,0.5,0.5v2c0,0.3-0.2,0.5-0.5,0.5H1V28z"/>
12
+ </svg>
@@ -0,0 +1,12 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M1.5,1h2C3.8,1,4,1.2,4,1.5V28H1V1.5C1,1.2,1.2,1,1.5,1z M1,28h29.5c0.3,0,0.5,0.2,0.5,0.5v2
9
+ c0,0.3-0.2,0.5-0.5,0.5H1V28z M28.9,9.8l0.3,0.2c0.8,0.6,0.7,1.7,0.3,2.3l-0.2,0.1l-8.9,9l-0.1,0.1l-0.2,0.2
10
+ c-0.5,0.4-0.9,0.8-1.8,0.4L18,22l-5.8-5.8l-4,4c-0.5,0.5-1.6,0.7-2.3,0L5.7,20c-0.5-0.7-0.5-1.5,0-2.2L6,17.6l5.4-5.4
11
+ c0.2-0.2,0.6-0.4,0.8-0.4h0.3c0.2,0,0.5,0.1,0.7,0.2l0.2,0.2l5.6,5.6l7.9-8C27.3,9.5,28.2,9.3,28.9,9.8z"/>
12
+ </svg>
@@ -0,0 +1,20 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M16,1C7.7,1,1,7.7,1,16s6.7,15,15,15s15-6.7,15-15S24.3,1,16,1z M10.9,28.1c-1.6-0.7-3-1.6-4.2-2.8
9
+ c-1.2-1.2-2.2-2.6-2.8-4.2c-0.7-1.6-1-3.3-1-5.1c0-0.8,0.1-1.7,0.2-2.5c0.2,0.1,0.4,0.1,0.6,0.1c0.3,0,0.6-0.1,0.8-0.2
10
+ c0.2-0.2,0.5-0.2,0.8-0.2c0.2,0,0.5,0.1,0.7,0.2c0.2,0.1,0.4,0.3,0.4,0.7c0,2.4,0.1,4.9,2.3,5c0.1,0,1.2,0.4,1.8,1.9
11
+ c0.1,0.2,0.2,0.2,0.4,0.2c0.3,0,0.8-0.2,1.4-0.2c0.4,0,0,0.7,0,2.2s3.2,3.8,3.2,3.8c0,0.9,0,1.7,0.1,2.3
12
+ C13.9,29,12.3,28.7,10.9,28.1z M25.3,25.3c-1.2,1.2-2.6,2.2-4.2,2.8c-0.7,0.3-1.4,0.5-2.2,0.7h-0.5c0.5-1.9,0.7-3,1.6-3.8
13
+ c1.3-1.1,0.3-2.4-0.7-2.4h-0.2H19c-0.7,0-0.2-1-0.9-1.1c-0.7-0.1-1.7-1.5-2.7-2c-0.6-0.3-1.1-1-2-1c-0.5,0-1.2,0.3-1.6,0.3
14
+ c-0.1,0-0.2-0.1-0.2-0.2c0-1.7-0.2-2.9-0.2-3.3c0-0.2-0.1-0.2,0-0.2c0,0,0.2,0.1,0.8,0.1c0.5,0,0.3-1.1,0.8-1.2h0.1
15
+ c0.5,0,1.4,0.3,1.9,0.3h0.2c0.3,0,1.3,2.5,1.8,2.5c0.2,0,0.4-0.4,0.4-1.6c0-0.5-0.3-1.4,0-1.9c1-1.9,2-3.4,1.9-3.6
16
+ c0-0.1-0.3-0.1-0.7-0.1c-0.3,0-0.8,0-1.1,0.2c-0.3,0.1,0.1,0.5-0.3,0.6c-0.3,0.1-0.5,0.1-0.7,0.1c-1.1,0-1.9-0.6-1.6-1.2
17
+ C15.4,8.6,17,9,17.2,7.6c0.1-0.7,0.1-1.4,0.2-2c0-0.2,0.2-0.4,0.4-0.4C18.9,5.1,19,3.8,18,3c1.1,0.2,2.2,0.5,3.2,0.9
18
+ c1.6,0.7,3,1.6,4.2,2.8c1.1,1.1,2,2.4,2.6,3.7c-0.2-0.1-0.3-0.2-0.5-0.2c-0.8,0-1.6,1.1-1.1,2.4c-3.9,3-2.9,5.1-1.6,6.3
19
+ c0.4,0.4,0.7,0.8,1.1,1.3c0.3,0.4,0.5,0.9,0.6,1.4c0,0.2,0.2,0.3,0.4,0.3c0.3,0,0.8-0.2,1.3-0.6C27.3,22.8,26.4,24.1,25.3,25.3z"/>
20
+ </svg>
@@ -0,0 +1,11 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M31,15.2H16.8V1c3.8,0.2,7.2,1.8,9.8,4.4S30.8,11.5,31,15.2z M4.6,25.9C2.3,23.2,1,19.8,1,16.4
9
+ C1,12.5,2.5,8.8,5.3,6c2.5-2.5,5.8-4,9.3-4.2V16C14.6,16,4.6,25.9,4.6,25.9z M15.6,31c3.8,0,7.6-1.5,10.3-4.3c2.5-2.5,4-5.8,4.2-9.3
10
+ H16l-9.9,10C8.8,29.7,12.2,31,15.6,31z"/>
11
+ </svg>
@@ -0,0 +1,10 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M13,15v14H0V15H13z M23,19v10h-8V19H23z M32,19v10h-7V19H32z M20,11v6h-5v-6H20z M26,11v6h-4v-6H26z M32,11v6
9
+ h-4v-6H32z M13,3v10H0V3H13z M20,3v6h-5V3H20z M26,7v2h-4V7H26z M32,7v2h-4V7H32z M26,3v2h-4V3H26z M32,3v2h-4V3H32z"/>
10
+ </svg>
@@ -0,0 +1,15 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#999999;}
7
+ </style>
8
+ <path class="st0" d="M1.5,1h2C3.8,1,4,1.2,4,1.5V28H1V1.5C1,1.2,1.2,1,1.5,1z M1,28h29.5c0.3,0,0.5,0.2,0.5,0.5v2
9
+ c0,0.3-0.2,0.5-0.5,0.5H1V28z M21.4,18.9c0,1.4,1.1,2.6,2.6,2.6c1.4,0,2.6-1.1,2.6-2.6c0-1.4-1.1-2.6-2.6-2.6S21.4,17.5,21.4,18.9z
10
+ M19.4,12.9c1.3,0,2.3-1,2.3-2.3s-1-2.3-2.3-2.3s-2.3,1-2.3,2.3S18.1,12.9,19.4,12.9z M24.8,8.7c1.3,0,2.3-1,2.3-2.3s-1-2.3-2.3-2.3
11
+ s-2.3,1-2.3,2.3S23.5,8.7,24.8,8.7z M26.7,14.6c1.3,0,2.3-1,2.3-2.3S28,10,26.7,10s-2.3,1-2.3,2.3S25.4,14.6,26.7,14.6z M6,20.6
12
+ c0,1.1,0.9,2,2,2s2-0.9,2-2s-0.9-2-2-2S6,19.5,6,20.6 M11.7,17.5c1.6,0,2.8-1.3,2.8-2.8c0-1.6-1.3-2.8-2.8-2.8S8.8,13,8.8,14.6
13
+ S10.1,17.5,11.7,17.5z M12.2,22.9c0,1.1,0.9,2,2,2s2-0.9,2-2s-0.9-2-2-2S12.2,21.8,12.2,22.9z M17.7,20.9c1.1,0,2-0.9,2-2
14
+ s-0.9-2-2-2s-2,0.9-2,2S16.6,20.9,17.7,20.9z"/>
15
+ </svg>
@@ -0,0 +1,17 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
3
+ <svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
+ viewBox="0 0 32 32" style="enable-background:new 0 0 32 32;" xml:space="preserve">
5
+ <style type="text/css">
6
+ .st0{fill:#949494;}
7
+ </style>
8
+ <title>switch</title>
9
+ <g id="switch">
10
+ <g id="batch-replacement" transform="translate(1.000000, 3.000000)">
11
+ <path id="形状" class="st0" d="M9.1,11.7V8.9h12.8c1.4,0,2.5,1.2,3,2.3c0.4-0.6,0.7-1.8,0.7-2.7c0-2.1-1.7-4.5-3.8-4.5H9.1V0.7
12
+ c0-0.5-0.5-0.9-1-0.5L0.2,5.7c-0.3,0.2-0.3,0.8,0,1.1l7.8,5.6C8.6,12.6,9.1,12.3,9.1,11.7z M29.8,20.2l-7.8-5.6
13
+ c-0.4-0.3-1,0-1,0.5v3.2H8.1c-1.4,0-2.4-1.4-3.1-2.6c-0.4,0.6-0.8,2-0.8,2.9c0,2.1,1.7,4.3,3.8,4.3h12.8v3.2c0,0.5,0.5,0.9,1,0.5
14
+ l7.8-5.6C30.1,21,30.1,20.5,29.8,20.2L29.8,20.2z"/>
15
+ </g>
16
+ </g>
17
+ </svg>
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
@@ -0,0 +1,24 @@
1
+ import React from 'react';
2
+ var Collaborator = function Collaborator(_ref) {
3
+ var _ref$collaborator = _ref.collaborator,
4
+ collaborator = _ref$collaborator === void 0 ? {} : _ref$collaborator;
5
+ var _ref2 = collaborator || {},
6
+ avatar_url = _ref2.avatar_url,
7
+ name = _ref2.name;
8
+ return /*#__PURE__*/React.createElement("div", {
9
+ className: "collaborators-formatter"
10
+ }, /*#__PURE__*/React.createElement("div", {
11
+ className: "collaborator"
12
+ }, /*#__PURE__*/React.createElement("span", {
13
+ className: "collaborator-avatar-container"
14
+ }, /*#__PURE__*/React.createElement("img", {
15
+ src: avatar_url,
16
+ alt: '',
17
+ className: "collaborator-avatar"
18
+ })), /*#__PURE__*/React.createElement("span", {
19
+ className: "collaborator-name",
20
+ title: name,
21
+ "aria-label": name
22
+ }, name)));
23
+ };
24
+ export default Collaborator;
@@ -0,0 +1,162 @@
1
+ import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
2
+ import _createClass from "@babel/runtime/helpers/esm/createClass";
3
+ import _inherits from "@babel/runtime/helpers/esm/inherits";
4
+ import _createSuper from "@babel/runtime/helpers/esm/createSuper";
5
+ import React from 'react';
6
+ import PropTypes from 'prop-types';
7
+ import classnames from 'classnames';
8
+ import { STATISTIC_SUMMARY_TYPE, STATISTIC_SUMMARY_SHOW } from '../../constants';
9
+ import intl from '../../intl';
10
+ import { StatisticsUtils } from '../../utils';
11
+ import ChartComponent from './chart-component';
12
+ var Area = /*#__PURE__*/function (_ChartComponent) {
13
+ _inherits(Area, _ChartComponent);
14
+ var _super = _createSuper(Area);
15
+ function Area(props) {
16
+ var _this;
17
+ _classCallCheck(this, Area);
18
+ _this = _super.call(this, props);
19
+ _this.createChart = function () {
20
+ var statistic = _this.props.statistic;
21
+ var y_axis_show_value = statistic.config.y_axis_show_value;
22
+ var appendPadding = [y_axis_show_value ? 17 : 0, 0, 0, 0];
23
+ _this.initChart(_this.container, {
24
+ appendPadding: appendPadding
25
+ });
26
+ _this.chart.on('interval:click', function (e) {
27
+ _this.props.toggleRecords(e.data.data);
28
+ });
29
+ };
30
+ _this.clearChart = function () {
31
+ _this.chart.annotation().clear(true);
32
+ _this.chart.clear(true);
33
+ };
34
+ _this.drawChart = function () {
35
+ var data = _this.props.result;
36
+ data = StatisticsUtils.formatEmptyName(data, '', intl.get('Empty'));
37
+ if (!Array.isArray(data)) return;
38
+ _this.loadData(data);
39
+ _this.draw(data);
40
+ _this.chart.render();
41
+ };
42
+ _this.draw = function (data) {
43
+ var _this$props = _this.props,
44
+ statistic = _this$props.statistic,
45
+ summaryColumn = _this$props.summaryColumn,
46
+ theme = _this$props.theme;
47
+ var _statistic$config = statistic.config,
48
+ y_axis_summary_type = _statistic$config.y_axis_summary_type,
49
+ y_axis_summary_method = _statistic$config.y_axis_summary_method,
50
+ y_axis_label_color = _statistic$config.y_axis_label_color,
51
+ y_axis_show_value = _statistic$config.y_axis_show_value,
52
+ label_font_size = _statistic$config.label_font_size;
53
+ var chartBarColor = y_axis_label_color || '#2a67d1';
54
+ _this.drawLabels(data);
55
+
56
+ // set Coord type
57
+ _this.chart.coordinate('rect');
58
+ _this.autoAdjustDataOptions(statistic, data, summaryColumn);
59
+ _this.chart.line().position('name*value').color(chartBarColor);
60
+ _this.chart.point().label(y_axis_show_value ? 'value' : false, {
61
+ style: {
62
+ fontSize: StatisticsUtils.getLabelFontSize(label_font_size),
63
+ fill: '#6e6e6e'
64
+ }
65
+ }).position('name*value').color(chartBarColor).tooltip('name*value', function (name, value) {
66
+ return {
67
+ title: y_axis_summary_type === STATISTIC_SUMMARY_TYPE.COUNT ? intl.get('Amount') : intl.get(STATISTIC_SUMMARY_SHOW[y_axis_summary_method]),
68
+ value: StatisticsUtils.getSummaryValueDisplayString(summaryColumn, value, y_axis_summary_method),
69
+ name: name
70
+ };
71
+ }).shape('circle').style({
72
+ lineWidth: 1,
73
+ stroke: '#fff'
74
+ }).state({
75
+ active: {
76
+ style: {
77
+ stroke: null
78
+ }
79
+ }
80
+ });
81
+ _this.chart.area().position('name*value').color(chartBarColor).tooltip('name*value', function (name, value) {
82
+ return {
83
+ name: name,
84
+ value: StatisticsUtils.getSummaryValueDisplayString(summaryColumn, value, y_axis_summary_method),
85
+ title: y_axis_summary_type === STATISTIC_SUMMARY_TYPE.COUNT ? intl.get('Amount') : intl.get(STATISTIC_SUMMARY_SHOW[y_axis_summary_method])
86
+ };
87
+ });
88
+ _this.chart.tooltip({
89
+ showTitle: true,
90
+ showMarkers: false,
91
+ containerTpl: '<div class="g2-tooltip"><div class="g2-tooltip-list"></div></div>',
92
+ itemTpl: '<div class="g2-tooltip-content"><div class="tooltip-name">{title}<div><div class="tooltip-item">{name}: {value}<div></div>',
93
+ domStyles: {
94
+ 'g2-tooltip': {
95
+ borderRadius: '2px',
96
+ backgroundColor: '#fff',
97
+ padding: '10px'
98
+ },
99
+ 'tooltip-item': {
100
+ marginTop: '5px'
101
+ }
102
+ }
103
+ });
104
+ _this.setNameLabelAndTooltip(theme, _this.labelCount);
105
+ _this.setValueLabel(theme);
106
+ _this.chart.interaction('active-region');
107
+ };
108
+ _this.chart = null;
109
+ return _this;
110
+ }
111
+ _createClass(Area, [{
112
+ key: "componentDidMount",
113
+ value: function componentDidMount() {
114
+ this.createChart();
115
+ this.drawChart();
116
+ this.renderAxisLabel(this.props.statistic, this.props.tables);
117
+ }
118
+ }, {
119
+ key: "componentDidUpdate",
120
+ value: function componentDidUpdate(prevProps) {
121
+ if (StatisticsUtils.shouldChartComponentUpdate(prevProps, this.props)) {
122
+ this.chart && this.chart.destroy();
123
+ this.createChart();
124
+ this.drawChart();
125
+ this.renderAxisLabel(prevProps.statistic, prevProps.tables);
126
+ }
127
+ }
128
+ }, {
129
+ key: "componentWillUnmount",
130
+ value: function componentWillUnmount() {
131
+ this.chart && this.chart.destroy();
132
+ }
133
+ }, {
134
+ key: "render",
135
+ value: function render() {
136
+ var _this2 = this;
137
+ var statistic = this.props.statistic;
138
+ return /*#__PURE__*/React.createElement("div", {
139
+ className: classnames('seastatistic-container w-100', {
140
+ 'show-x-axis-label': this.isShowXAxisLabel(statistic),
141
+ 'show-y-axis-label': this.isShowYAxisLabel(statistic)
142
+ }),
143
+ ref: function ref(_ref) {
144
+ return _this2.container = _ref;
145
+ }
146
+ });
147
+ }
148
+ }]);
149
+ return Area;
150
+ }(ChartComponent);
151
+ Area.propTypes = {
152
+ canvasStyle: PropTypes.object,
153
+ statistic: PropTypes.object,
154
+ groupbyColumn: PropTypes.object,
155
+ columnGroupbyColumn: PropTypes.object,
156
+ summaryColumn: PropTypes.object,
157
+ result: PropTypes.array,
158
+ tables: PropTypes.array,
159
+ theme: PropTypes.object,
160
+ toggleRecords: PropTypes.func
161
+ };
162
+ export default Area;