@kdcloudjs/table 1.2.1-canary.6 → 1.2.2-canary.3

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 (288) hide show
  1. package/LICENSE +568 -568
  2. package/README.md +111 -111
  3. package/dist/@kdcloudjs/table.css +1 -1
  4. package/dist/@kdcloudjs/table.js +5480 -6087
  5. package/dist/@kdcloudjs/table.js.map +1 -1
  6. package/dist/@kdcloudjs/table.min.css +1 -1
  7. package/dist/@kdcloudjs/table.min.js +18 -16
  8. package/dist/@kdcloudjs/table.min.js.map +1 -1
  9. package/dist/kd-ui-complete.less +777 -777
  10. package/es/_utils/arrayUtil.js +0 -3
  11. package/es/_utils/devwarning.js +0 -1
  12. package/es/_utils/formatUtil.js +36 -101
  13. package/es/_utils/hooks.js +21 -45
  14. package/es/_utils/index.js +0 -2
  15. package/es/_utils/numberUtil.js +32 -55
  16. package/es/_utils/omit.js +0 -2
  17. package/es/_utils/type.js +0 -2
  18. package/es/_utils/usePopper.js +81 -144
  19. package/es/config-provider/compDefaultProps.js +0 -1
  20. package/es/config-provider/configProvider.js +2 -7
  21. package/es/config-provider/defaultConfig.js +0 -1
  22. package/es/index.js +0 -2
  23. package/es/locale/locale.js +11 -50
  24. package/es/style/color/colors.less +1 -1
  25. package/es/style/core/index.less +1 -1
  26. package/es/style/core/motion/other.less +27 -27
  27. package/es/style/core/motion/slide.less +53 -53
  28. package/es/style/core/motion.less +1 -1
  29. package/es/style/core/reset.less +185 -185
  30. package/es/style/index.less +1 -1
  31. package/es/style/mixins/index.less +18 -18
  32. package/es/style/mixins/overlay.less +21 -21
  33. package/es/style/mixins/reset.less +12 -12
  34. package/es/style/themes/default.less +445 -445
  35. package/es/table/base/calculations.js +25 -75
  36. package/es/table/base/colgroup.js +0 -1
  37. package/es/table/base/empty.js +6 -6
  38. package/es/table/base/globalStyleComponent.d.ts +4 -0
  39. package/es/table/base/globalStyleComponent.js +24 -0
  40. package/es/table/base/header.js +21 -76
  41. package/es/table/base/helpers/SpanManager.js +4 -11
  42. package/es/table/base/helpers/TableDOMUtils.js +9 -34
  43. package/es/table/base/helpers/__test__/SpanManager.test.js +2 -2
  44. package/es/table/base/helpers/__test__/TableDOMUtils.test.js +0 -1
  45. package/es/table/base/helpers/getRichVisibleRectsStream.js +13 -45
  46. package/es/table/base/helpers/rowHeightManager.js +0 -28
  47. package/es/table/base/html-table.js +17 -39
  48. package/es/table/base/loading.js +8 -10
  49. package/es/table/base/renderTemplates.js +42 -60
  50. package/es/table/base/styles.d.ts +10 -0
  51. package/es/table/base/styles.js +17 -16
  52. package/es/table/base/table.js +113 -201
  53. package/es/table/base/utils.js +17 -57
  54. package/es/table/common-views.js +0 -7
  55. package/es/table/interfaces.d.ts +38 -0
  56. package/es/table/internals.js +0 -13
  57. package/es/table/pipeline/const.d.ts +3 -0
  58. package/es/table/pipeline/const.js +3 -0
  59. package/es/table/pipeline/features/autoFill.js +11 -40
  60. package/es/table/pipeline/features/autoRowSpan.js +1 -14
  61. package/es/table/pipeline/features/colGroupExtendable.js +4 -19
  62. package/es/table/pipeline/features/columnDrag.js +41 -97
  63. package/es/table/pipeline/features/columnFilter.js +12 -51
  64. package/es/table/pipeline/features/columnHover.js +1 -7
  65. package/es/table/pipeline/features/columnRangeHover.js +1 -8
  66. package/es/table/pipeline/features/columnResizeWidth.js +13 -39
  67. package/es/table/pipeline/features/contextMenu.js +22 -95
  68. package/es/table/pipeline/features/featureApi/RowDragApi.d.ts +15 -0
  69. package/es/table/pipeline/features/featureApi/RowDragApi.js +66 -0
  70. package/es/table/pipeline/features/featureApi/utils.d.ts +2 -0
  71. package/es/table/pipeline/features/featureApi/utils.js +10 -0
  72. package/es/table/pipeline/features/filter/DefaultFilterContent.js +14 -30
  73. package/es/table/pipeline/features/filter/DefaultFilterIcon.js +1 -1
  74. package/es/table/pipeline/features/filter/Filter.js +27 -51
  75. package/es/table/pipeline/features/filter/FilterPanel.js +11 -25
  76. package/es/table/pipeline/features/filter/util.js +0 -4
  77. package/es/table/pipeline/features/footerDataSource.js +0 -3
  78. package/es/table/pipeline/features/mergeCellHover.js +0 -1
  79. package/es/table/pipeline/features/multiSelect.js +15 -57
  80. package/es/table/pipeline/features/rangeSelection.js +73 -152
  81. package/es/table/pipeline/features/rowDetail.js +4 -43
  82. package/es/table/pipeline/features/rowDrag.d.ts +10 -12
  83. package/es/table/pipeline/features/rowDrag.js +491 -236
  84. package/es/table/pipeline/features/rowGrouping.js +4 -37
  85. package/es/table/pipeline/features/singleSelect.js +0 -24
  86. package/es/table/pipeline/features/sort.js +38 -96
  87. package/es/table/pipeline/features/tips.js +4 -10
  88. package/es/table/pipeline/features/treeMode.d.ts +1 -0
  89. package/es/table/pipeline/features/treeMode.js +38 -57
  90. package/es/table/pipeline/features/treeSelect.js +2 -28
  91. package/es/table/pipeline/pipeline.d.ts +3 -0
  92. package/es/table/pipeline/pipeline.js +35 -54
  93. package/es/table/pivot/cross-table/buildCrossTable.js +21 -72
  94. package/es/table/pivot/cross-table/cross-table.js +23 -31
  95. package/es/table/pivot/cross-tree-table/buildCrossTreeTable.js +22 -57
  96. package/es/table/pivot/cross-tree-table/cross-tree-table.js +36 -61
  97. package/es/table/pivot/pivot-utils/buildDrillTree.js +10 -23
  98. package/es/table/pivot/pivot-utils/builders.js +34 -74
  99. package/es/table/pivot/pivot-utils/convert-utils.js +16 -42
  100. package/es/table/pivot/pivot-utils/simpleEncode.js +0 -1
  101. package/es/table/style/index.less +1 -1
  102. package/es/table/transforms/autoRowSpan.js +1 -15
  103. package/es/table/transforms/autoWidth.js +13 -35
  104. package/es/table/transforms/buildTree.js +1 -2
  105. package/es/table/transforms/columnHover.js +9 -15
  106. package/es/table/transforms/columnRangeHover.js +12 -19
  107. package/es/table/transforms/columnResize.js +18 -42
  108. package/es/table/transforms/flatten.js +0 -3
  109. package/es/table/transforms/orderField.js +0 -3
  110. package/es/table/transforms/sort.js +42 -101
  111. package/es/table/transforms/tips.js +5 -10
  112. package/es/table/transforms/treeMode.js +36 -77
  113. package/es/table/transforms/visible.js +0 -2
  114. package/es/table/use/useResizeObserver.js +1 -4
  115. package/es/table/utils/applyTransforms.js +0 -1
  116. package/es/table/utils/browserType.js +12 -19
  117. package/es/table/utils/buildTree.js +7 -22
  118. package/es/table/utils/collectNodes.js +4 -13
  119. package/es/table/utils/console.js +0 -14
  120. package/es/table/utils/copyToClipboard.js +0 -4
  121. package/es/table/utils/element.js +14 -41
  122. package/es/table/utils/exportTableAsExcel.js +7 -43
  123. package/es/table/utils/getTreeDepth.js +4 -12
  124. package/es/table/utils/groupBy.js +4 -13
  125. package/es/table/utils/layeredFilter.js +0 -4
  126. package/es/table/utils/layeredSort.js +0 -5
  127. package/es/table/utils/makeRecursiveMapper.js +4 -15
  128. package/es/table/utils/mergeCellProps.js +6 -14
  129. package/es/table/utils/others.js +6 -19
  130. package/es/table/utils/proto.js +2 -30
  131. package/es/table/utils/smartCompare.js +4 -12
  132. package/es/table/utils/traverseColumn.js +5 -18
  133. package/es/table/utils/tree-data-helpers/StrictTreeDataHelper.js +8 -30
  134. package/es/table/utils/tree-data-helpers/TreeDataHelper.js +19 -74
  135. package/es/table/utils/uiDegrade.js +0 -5
  136. package/lib/_utils/arrayUtil.js +2 -8
  137. package/lib/_utils/devwarning.js +0 -5
  138. package/lib/_utils/formatUtil.js +36 -105
  139. package/lib/_utils/hooks.js +21 -56
  140. package/lib/_utils/index.js +2 -9
  141. package/lib/_utils/numberUtil.js +32 -63
  142. package/lib/_utils/omit.js +0 -5
  143. package/lib/_utils/react-children.js +0 -5
  144. package/lib/_utils/type.js +3 -11
  145. package/lib/_utils/usePopper.js +86 -173
  146. package/lib/config-provider/ConfigContext.js +2 -6
  147. package/lib/config-provider/compDefaultProps.js +1 -3
  148. package/lib/config-provider/configProvider.js +6 -22
  149. package/lib/config-provider/defaultConfig.js +1 -7
  150. package/lib/config-provider/index.js +1 -8
  151. package/lib/index.js +2 -8
  152. package/lib/locale/index.js +3 -11
  153. package/lib/locale/locale.js +15 -71
  154. package/lib/locale/zh-CN.js +1 -2
  155. package/lib/style/color/colors.less +1 -1
  156. package/lib/style/components.less +1 -1
  157. package/lib/style/core/index.less +1 -1
  158. package/lib/style/core/motion/other.less +27 -27
  159. package/lib/style/core/motion/slide.less +53 -53
  160. package/lib/style/core/motion.less +1 -1
  161. package/lib/style/core/reset.less +185 -185
  162. package/lib/style/index.less +1 -1
  163. package/lib/style/mixins/index.less +18 -18
  164. package/lib/style/mixins/overlay.less +21 -21
  165. package/lib/style/mixins/reset.less +12 -12
  166. package/lib/style/themes/default.less +445 -445
  167. package/lib/table/base/calculations.js +25 -86
  168. package/lib/table/base/colgroup.js +0 -5
  169. package/lib/table/base/empty.js +8 -20
  170. package/lib/table/base/globalStyleComponent.d.ts +4 -0
  171. package/lib/table/base/globalStyleComponent.js +35 -0
  172. package/lib/table/base/header.js +21 -86
  173. package/lib/table/base/helpers/SpanManager.js +6 -16
  174. package/lib/table/base/helpers/TableDOMUtils.js +9 -37
  175. package/lib/table/base/helpers/__test__/SpanManager.test.js +2 -4
  176. package/lib/table/base/helpers/__test__/TableDOMUtils.test.js +0 -5
  177. package/lib/table/base/helpers/__test__/rowHeightManager.test.js +0 -1
  178. package/lib/table/base/helpers/getRichVisibleRectsStream.js +15 -65
  179. package/lib/table/base/helpers/rowHeightManager.js +0 -33
  180. package/lib/table/base/html-table.js +17 -49
  181. package/lib/table/base/index.js +0 -2
  182. package/lib/table/base/loading.js +8 -14
  183. package/lib/table/base/renderTemplates.js +45 -76
  184. package/lib/table/base/styles.d.ts +10 -0
  185. package/lib/table/base/styles.js +24 -42
  186. package/lib/table/base/table.js +125 -245
  187. package/lib/table/base/utils.js +27 -109
  188. package/lib/table/common-views.js +4 -24
  189. package/lib/table/index.js +0 -13
  190. package/lib/table/interfaces.d.ts +38 -0
  191. package/lib/table/internals.js +2 -17
  192. package/lib/table/pipeline/const.d.ts +3 -0
  193. package/lib/table/pipeline/const.js +9 -0
  194. package/lib/table/pipeline/features/autoFill.js +14 -53
  195. package/lib/table/pipeline/features/autoRowSpan.js +1 -19
  196. package/lib/table/pipeline/features/buildTree.js +0 -2
  197. package/lib/table/pipeline/features/colGroupExtendable.js +6 -35
  198. package/lib/table/pipeline/features/columnDrag.js +41 -103
  199. package/lib/table/pipeline/features/columnFilter.js +12 -65
  200. package/lib/table/pipeline/features/columnHover.js +1 -11
  201. package/lib/table/pipeline/features/columnRangeHover.js +1 -13
  202. package/lib/table/pipeline/features/columnResizeWidth.js +18 -63
  203. package/lib/table/pipeline/features/contextMenu.js +24 -121
  204. package/lib/table/pipeline/features/featureApi/RowDragApi.d.ts +15 -0
  205. package/lib/table/pipeline/features/featureApi/RowDragApi.js +72 -0
  206. package/lib/table/pipeline/features/featureApi/utils.d.ts +2 -0
  207. package/lib/table/pipeline/features/featureApi/utils.js +17 -0
  208. package/lib/table/pipeline/features/filter/DefaultFilterContent.js +17 -52
  209. package/lib/table/pipeline/features/filter/DefaultFilterIcon.js +1 -4
  210. package/lib/table/pipeline/features/filter/Filter.js +30 -77
  211. package/lib/table/pipeline/features/filter/FilterPanel.js +14 -44
  212. package/lib/table/pipeline/features/filter/index.js +0 -5
  213. package/lib/table/pipeline/features/filter/util.js +2 -10
  214. package/lib/table/pipeline/features/footerDataSource.js +1 -12
  215. package/lib/table/pipeline/features/index.js +0 -23
  216. package/lib/table/pipeline/features/mergeCellHover.js +0 -5
  217. package/lib/table/pipeline/features/multiSelect.js +15 -71
  218. package/lib/table/pipeline/features/rangeSelection.js +75 -173
  219. package/lib/table/pipeline/features/rowDetail.js +4 -67
  220. package/lib/table/pipeline/features/rowDrag.d.ts +10 -12
  221. package/lib/table/pipeline/features/rowDrag.js +494 -252
  222. package/lib/table/pipeline/features/rowGrouping.js +4 -57
  223. package/lib/table/pipeline/features/singleSelect.js +0 -34
  224. package/lib/table/pipeline/features/sort.js +37 -115
  225. package/lib/table/pipeline/features/tips.js +4 -19
  226. package/lib/table/pipeline/features/treeMode.d.ts +1 -0
  227. package/lib/table/pipeline/features/treeMode.js +40 -80
  228. package/lib/table/pipeline/features/treeSelect.js +2 -36
  229. package/lib/table/pipeline/index.js +2 -10
  230. package/lib/table/pipeline/pipeline.d.ts +3 -0
  231. package/lib/table/pipeline/pipeline.js +36 -65
  232. package/lib/table/pivot/cross-table/buildCrossTable.js +21 -83
  233. package/lib/table/pivot/cross-table/constants.js +1 -2
  234. package/lib/table/pivot/cross-table/cross-table.js +25 -42
  235. package/lib/table/pivot/cross-table/index.js +0 -4
  236. package/lib/table/pivot/cross-tree-table/buildCrossTreeTable.js +22 -70
  237. package/lib/table/pivot/cross-tree-table/cross-tree-table.js +37 -73
  238. package/lib/table/pivot/cross-tree-table/index.js +0 -3
  239. package/lib/table/pivot/pivot-utils/buildDrillTree.js +10 -29
  240. package/lib/table/pivot/pivot-utils/builders.js +34 -85
  241. package/lib/table/pivot/pivot-utils/convert-utils.js +16 -60
  242. package/lib/table/pivot/pivot-utils/index.js +0 -7
  243. package/lib/table/pivot/pivot-utils/simpleEncode.js +0 -2
  244. package/lib/table/style/css.js +0 -1
  245. package/lib/table/style/index.js +0 -1
  246. package/lib/table/style/index.less +1 -1
  247. package/lib/table/transforms/autoRowSpan.js +1 -21
  248. package/lib/table/transforms/autoWidth.js +15 -58
  249. package/lib/table/transforms/buildTree.js +1 -4
  250. package/lib/table/transforms/columnHover.js +9 -22
  251. package/lib/table/transforms/columnRangeHover.js +12 -27
  252. package/lib/table/transforms/columnResize.js +20 -63
  253. package/lib/table/transforms/flatten.js +0 -5
  254. package/lib/table/transforms/index.js +0 -12
  255. package/lib/table/transforms/orderField.js +0 -7
  256. package/lib/table/transforms/sort.js +44 -127
  257. package/lib/table/transforms/tips.js +5 -20
  258. package/lib/table/transforms/treeMode.js +38 -106
  259. package/lib/table/transforms/visible.js +0 -7
  260. package/lib/table/transforms/warnTransformsDeprecated.js +0 -4
  261. package/lib/table/use/useResizeObserver.js +2 -10
  262. package/lib/table/utils/applyTransforms.js +0 -2
  263. package/lib/table/utils/browserType.js +14 -23
  264. package/lib/table/utils/buildTree.js +7 -33
  265. package/lib/table/utils/collectNodes.js +4 -18
  266. package/lib/table/utils/console.js +2 -19
  267. package/lib/table/utils/copyToClipboard.js +1 -8
  268. package/lib/table/utils/element.js +14 -46
  269. package/lib/table/utils/exportTableAsExcel.js +7 -52
  270. package/lib/table/utils/getTreeDepth.js +4 -17
  271. package/lib/table/utils/groupBy.js +4 -17
  272. package/lib/table/utils/index.js +0 -22
  273. package/lib/table/utils/isGroupColumn.js +0 -3
  274. package/lib/table/utils/isLeafNode.js +0 -1
  275. package/lib/table/utils/keyCode.js +1 -2
  276. package/lib/table/utils/layeredFilter.js +0 -10
  277. package/lib/table/utils/layeredSort.js +0 -10
  278. package/lib/table/utils/makeRecursiveMapper.js +4 -24
  279. package/lib/table/utils/mergeCellProps.js +6 -18
  280. package/lib/table/utils/others.js +7 -36
  281. package/lib/table/utils/proto.js +3 -35
  282. package/lib/table/utils/selectColumn.js +2 -5
  283. package/lib/table/utils/smartCompare.js +4 -13
  284. package/lib/table/utils/traverseColumn.js +5 -25
  285. package/lib/table/utils/tree-data-helpers/StrictTreeDataHelper.js +10 -41
  286. package/lib/table/utils/tree-data-helpers/TreeDataHelper.js +21 -90
  287. package/lib/table/utils/uiDegrade.js +1 -8
  288. package/package.json +218 -218
@@ -1,43 +1,32 @@
1
1
  import _defineProperty from "@babel/runtime-corejs3/helpers/defineProperty";
2
2
  import _extends from "@babel/runtime-corejs3/helpers/extends";
3
3
  import _toConsumableArray from "@babel/runtime-corejs3/helpers/toConsumableArray";
4
-
5
- function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof _Symbol !== "undefined" && _getIteratorMethod(o) || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
6
-
7
- function _unsupportedIterableToArray(o, minLen) { var _context4; if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = _sliceInstanceProperty(_context4 = Object.prototype.toString.call(o)).call(_context4, 8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return _Array$from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
8
-
9
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
10
-
4
+ function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof _Symbol && _getIteratorMethod(r) || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
5
+ function _unsupportedIterableToArray(r, a) { if (r) { var _context4; if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = _sliceInstanceProperty(_context4 = {}.toString.call(r)).call(_context4, 8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? _Array$from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
6
+ function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
11
7
  import _Object$getOwnPropertySymbols from "@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols";
12
8
  import _concatInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/concat";
13
9
  import _sliceInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/slice";
14
10
  import _Array$from from "@babel/runtime-corejs3/core-js-stable/array/from";
15
11
  import _Symbol from "@babel/runtime-corejs3/core-js-stable/symbol";
16
12
  import _getIteratorMethod from "@babel/runtime-corejs3/core-js/get-iterator-method";
17
-
18
13
  var __rest = this && this.__rest || function (s, e) {
19
14
  var t = {};
20
-
21
- for (var p in s) {
22
- if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
23
- }
24
-
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
25
16
  if (s != null && typeof _Object$getOwnPropertySymbols === "function") for (var i = 0, p = _Object$getOwnPropertySymbols(s); i < p.length; i++) {
26
17
  if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
27
18
  }
28
19
  return t;
29
20
  };
30
-
31
21
  import { getTreeDepth, isLeafNode } from '../../utils';
32
22
  import { ROW_KEY } from './constants';
33
23
  export default function buildCrossTable(options) {
34
24
  var _a, _b, _c;
35
-
36
25
  var leftTotalNode = options.leftTotalNode,
37
- topTotalNode = options.topTotalNode; // 有的时候 leftTree/topTree 是通过 node.children 传入的
26
+ topTotalNode = options.topTotalNode;
27
+ // 有的时候 leftTree/topTree 是通过 node.children 传入的
38
28
  // 此时 leftTree/topTree 等于 null 和等于空数组是等价的
39
29
  // 故在这里兼容 leftTree/topTree 为空的情况
40
-
41
30
  var leftTree = (_a = options.leftTree) !== null && _a !== void 0 ? _a : [];
42
31
  var topTree = (_b = options.topTree) !== null && _b !== void 0 ? _b : [];
43
32
  var leftMetaColumns = (_c = options.leftMetaColumns) !== null && _c !== void 0 ? _c : [];
@@ -47,24 +36,17 @@ export default function buildCrossTable(options) {
47
36
  dataSource: getDataSource()
48
37
  };
49
38
  /** 获取表格的列配置 */
50
-
51
39
  function getColumns() {
52
40
  var _context;
53
-
54
41
  return _concatInstanceProperty(_context = []).call(_context, _toConsumableArray(getLeftPartColumns()), _toConsumableArray(getDataPartColumns()));
55
-
56
42
  function getLeftPartColumns() {
57
43
  var _a;
58
-
59
44
  var leftPartColumns = [];
60
-
61
45
  for (var index = 0; index < leftHeaderWidth; index++) {
62
46
  var metaCol = (_a = leftMetaColumns[index]) !== null && _a !== void 0 ? _a : {};
63
-
64
47
  var getCellProps = metaCol.getCellProps,
65
- render = metaCol.render,
66
- staticMetaColConfig = __rest(metaCol, ["getCellProps", "render"]);
67
-
48
+ render = metaCol.render,
49
+ staticMetaColConfig = __rest(metaCol, ["getCellProps", "render"]);
68
50
  leftPartColumns.push(_extends(_extends({
69
51
  columnType: 'left',
70
52
  lock: true
@@ -75,48 +57,37 @@ export default function buildCrossTable(options) {
75
57
  render: leftHeaderRenderFactory(metaCol, index)
76
58
  }));
77
59
  }
78
-
79
60
  return leftPartColumns;
80
-
81
61
  function leftHeaderGetCellPropsFactory(metaCol, colIndex) {
82
62
  return function (_value, row, rowIndex) {
83
63
  var _a;
84
-
85
64
  var node = row.nodes[colIndex];
86
65
  return (_a = metaCol.getCellProps) === null || _a === void 0 ? void 0 : _a.call(metaCol, node, colIndex);
87
66
  };
88
67
  }
89
-
90
68
  function leftHeaderGetSpanRectFactory(metaCol, colIndex) {
91
69
  return function (_value, row) {
92
70
  return row.rects[colIndex];
93
71
  };
94
72
  }
95
-
96
73
  function leftHeaderGetValueFactory(metaCol, colIndex) {
97
74
  return function (row, rowIndex) {
98
75
  var node = row.nodes[colIndex];
99
76
  return node.value;
100
77
  };
101
78
  }
102
-
103
79
  function leftHeaderRenderFactory(metaCol, colIndex) {
104
80
  return function (v, row, rowIndex) {
105
81
  var _a;
106
-
107
82
  var node = row.nodes[colIndex];
108
-
109
83
  if (metaCol.render) {
110
84
  return metaCol.render(node, colIndex);
111
85
  }
112
-
113
86
  return (_a = node.title) !== null && _a !== void 0 ? _a : node.value;
114
87
  };
115
88
  }
116
89
  }
117
90
  /** 获取表格数据部分的列配置 */
118
-
119
-
120
91
  function getDataPartColumns() {
121
92
  if (topTree.length > 0) {
122
93
  return dfs(topTree, {
@@ -131,29 +102,25 @@ export default function buildCrossTable(options) {
131
102
  } else {
132
103
  return [];
133
104
  }
134
-
135
105
  function dfs(nodes, ctx) {
136
106
  var result = [];
137
-
138
107
  var _iterator = _createForOfIteratorHelper(nodes),
139
- _step;
140
-
108
+ _step;
141
109
  try {
142
110
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
143
111
  var node = _step.value;
144
112
  ctx.valuePath.push(node.value);
145
-
146
113
  if (isLeafNode(node)) {
147
114
  // 叶子节点
148
115
  result.push(getDataColumn(node, ctx.depth));
149
116
  } else {
150
117
  var key = node.key,
151
- value = node.value,
152
- children = node.children,
153
- others = __rest(node // 强制展开的节点
154
- , ["key", "value", "children"]); // 强制展开的节点
155
-
156
-
118
+ value = node.value,
119
+ children = node.children,
120
+ others = __rest(node
121
+ // 强制展开的节点
122
+ , ["key", "value", "children"]);
123
+ // 强制展开的节点
157
124
  result.push(_extends(_extends({
158
125
  columnType: 'data-parent'
159
126
  }, others), {
@@ -164,7 +131,6 @@ export default function buildCrossTable(options) {
164
131
  })
165
132
  }));
166
133
  }
167
-
168
134
  ctx.valuePath.pop();
169
135
  }
170
136
  } catch (err) {
@@ -172,23 +138,19 @@ export default function buildCrossTable(options) {
172
138
  } finally {
173
139
  _iterator.f();
174
140
  }
175
-
176
141
  return result;
177
142
  }
178
143
  }
179
-
180
144
  function getDataColumn(topNode, topDepth) {
181
145
  var columnGetValue = function columnGetValue(row) {
182
146
  var leftDepth = row.nodes.length - 1;
183
147
  var leftNode = row.nodes[leftDepth];
184
148
  return options.getValue(leftNode, topNode, leftDepth, topDepth);
185
149
  };
186
-
187
150
  var key = topNode.key,
188
- value = topNode.value,
189
- children = topNode.children,
190
- others = __rest(topNode, ["key", "value", "children"]);
191
-
151
+ value = topNode.value,
152
+ children = topNode.children,
153
+ others = __rest(topNode, ["key", "value", "children"]);
192
154
  return _extends(_extends({
193
155
  columnType: 'data'
194
156
  }, others), {
@@ -201,7 +163,6 @@ export default function buildCrossTable(options) {
201
163
  var leftNode = row.nodes[leftDepth];
202
164
  return options.render(value, leftNode, topNode, leftDepth, topDepth);
203
165
  }
204
-
205
166
  return value;
206
167
  },
207
168
  getCellProps: function getCellProps(value, row) {
@@ -214,7 +175,6 @@ export default function buildCrossTable(options) {
214
175
  });
215
176
  }
216
177
  }
217
-
218
178
  function getDataSource() {
219
179
  var flatRows = [];
220
180
  var ctx = {
@@ -223,41 +183,31 @@ export default function buildCrossTable(options) {
223
183
  rects: [],
224
184
  rowIndex: 0
225
185
  };
226
-
227
186
  if (leftTree.length > 0) {
228
187
  dfs(leftTree, ctx);
229
188
  } else if (leftTotalNode) {
230
189
  dfs([leftTotalNode], ctx);
231
190
  } // else 表格没有行,展示空表格
232
-
233
-
234
191
  return flatRows;
235
-
236
192
  function dfs(nodes, ctx) {
237
193
  var count = 0;
238
-
239
194
  var _iterator2 = _createForOfIteratorHelper(nodes),
240
- _step2;
241
-
195
+ _step2;
242
196
  try {
243
197
  for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
244
- var _context2, _context3, _row;
245
-
198
+ var _context2, _context3;
246
199
  var node = _step2.value;
247
-
248
200
  if (node.hidden) {
249
201
  // 跳过被隐藏的节点
250
202
  continue;
251
203
  }
252
-
253
204
  var rect = {
254
205
  top: ctx.rowIndex + count,
255
206
  bottom: -1,
256
207
  left: ctx.depth,
257
208
  right: -1
258
209
  };
259
- var row = (_row = {}, _defineProperty(_row, ROW_KEY, node.key), _defineProperty(_row, "rects", _concatInstanceProperty(_context2 = []).call(_context2, _toConsumableArray(ctx.rects), [rect])), _defineProperty(_row, "nodes", _concatInstanceProperty(_context3 = []).call(_context3, _toConsumableArray(ctx.nodes), [node])), _row);
260
-
210
+ var row = _defineProperty(_defineProperty(_defineProperty({}, ROW_KEY, node.key), "rects", _concatInstanceProperty(_context2 = []).call(_context2, _toConsumableArray(ctx.rects), [rect])), "nodes", _concatInstanceProperty(_context3 = []).call(_context3, _toConsumableArray(ctx.nodes), [node]));
261
211
  if (isLeafNode(node)) {
262
212
  rect.right = leftHeaderWidth;
263
213
  rect.bottom = rect.top + 1;
@@ -284,7 +234,6 @@ export default function buildCrossTable(options) {
284
234
  } finally {
285
235
  _iterator2.f();
286
236
  }
287
-
288
237
  return {
289
238
  count: count
290
239
  };
@@ -1,50 +1,42 @@
1
1
  import _extends from "@babel/runtime-corejs3/helpers/extends";
2
2
  import _Object$getOwnPropertySymbols from "@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols";
3
-
4
3
  var __rest = this && this.__rest || function (s, e) {
5
4
  var t = {};
6
-
7
- for (var p in s) {
8
- if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
9
- }
10
-
5
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
11
6
  if (s != null && typeof _Object$getOwnPropertySymbols === "function") for (var i = 0, p = _Object$getOwnPropertySymbols(s); i < p.length; i++) {
12
7
  if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
13
8
  }
14
9
  return t;
15
10
  };
16
-
17
11
  import React from 'react';
18
12
  import { Table } from '../../base';
19
13
  import buildCrossTable from './buildCrossTable';
20
14
  import { ROW_KEY } from './constants';
21
15
  export default (function CrossTable(_a) {
22
16
  var _a$BaseTableComponent = _a.BaseTableComponent,
23
- BaseTableComponent = _a$BaseTableComponent === void 0 ? Table : _a$BaseTableComponent,
24
- leftTree = _a.leftTree,
25
- leftTotalNode = _a.leftTotalNode,
26
- topTree = _a.topTree,
27
- topTotalNode = _a.topTotalNode,
28
- getValue = _a.getValue,
29
- getCellProps = _a.getCellProps,
30
- leftMetaColumns = _a.leftMetaColumns,
31
- render = _a.render,
32
- baseTableRef = _a.baseTableRef,
33
- others = __rest(_a, ["BaseTableComponent", "leftTree", "leftTotalNode", "topTree", "topTotalNode", "getValue", "getCellProps", "leftMetaColumns", "render", "baseTableRef"]);
34
-
17
+ BaseTableComponent = _a$BaseTableComponent === void 0 ? Table : _a$BaseTableComponent,
18
+ leftTree = _a.leftTree,
19
+ leftTotalNode = _a.leftTotalNode,
20
+ topTree = _a.topTree,
21
+ topTotalNode = _a.topTotalNode,
22
+ getValue = _a.getValue,
23
+ getCellProps = _a.getCellProps,
24
+ leftMetaColumns = _a.leftMetaColumns,
25
+ render = _a.render,
26
+ baseTableRef = _a.baseTableRef,
27
+ others = __rest(_a, ["BaseTableComponent", "leftTree", "leftTotalNode", "topTree", "topTotalNode", "getValue", "getCellProps", "leftMetaColumns", "render", "baseTableRef"]);
35
28
  var _buildCrossTable = buildCrossTable({
36
- leftTree: leftTree,
37
- topTree: topTree,
38
- leftTotalNode: leftTotalNode,
39
- topTotalNode: topTotalNode,
40
- getValue: getValue,
41
- getCellProps: getCellProps,
42
- render: render,
43
- leftMetaColumns: leftMetaColumns
44
- }),
45
- dataSource = _buildCrossTable.dataSource,
46
- columns = _buildCrossTable.columns;
47
-
29
+ leftTree: leftTree,
30
+ topTree: topTree,
31
+ leftTotalNode: leftTotalNode,
32
+ topTotalNode: topTotalNode,
33
+ getValue: getValue,
34
+ getCellProps: getCellProps,
35
+ render: render,
36
+ leftMetaColumns: leftMetaColumns
37
+ }),
38
+ dataSource = _buildCrossTable.dataSource,
39
+ columns = _buildCrossTable.columns;
48
40
  return /*#__PURE__*/React.createElement(BaseTableComponent, _extends({
49
41
  ref: baseTableRef
50
42
  }, others, {
@@ -1,49 +1,38 @@
1
1
  import _defineProperty from "@babel/runtime-corejs3/helpers/defineProperty";
2
2
  import _extends from "@babel/runtime-corejs3/helpers/extends";
3
3
  import _toConsumableArray from "@babel/runtime-corejs3/helpers/toConsumableArray";
4
-
5
- function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof _Symbol !== "undefined" && _getIteratorMethod(o) || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
6
-
7
- function _unsupportedIterableToArray(o, minLen) { var _context4; if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = _sliceInstanceProperty(_context4 = Object.prototype.toString.call(o)).call(_context4, 8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return _Array$from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
8
-
9
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
10
-
4
+ function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof _Symbol && _getIteratorMethod(r) || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
5
+ function _unsupportedIterableToArray(r, a) { if (r) { var _context4; if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = _sliceInstanceProperty(_context4 = {}.toString.call(r)).call(_context4, 8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? _Array$from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
6
+ function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
11
7
  import _Object$getOwnPropertySymbols from "@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols";
12
8
  import _concatInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/concat";
13
9
  import _sliceInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/slice";
14
10
  import _Array$from from "@babel/runtime-corejs3/core-js-stable/array/from";
15
11
  import _Symbol from "@babel/runtime-corejs3/core-js-stable/symbol";
16
12
  import _getIteratorMethod from "@babel/runtime-corejs3/core-js/get-iterator-method";
17
-
18
13
  var __rest = this && this.__rest || function (s, e) {
19
14
  var t = {};
20
-
21
- for (var p in s) {
22
- if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
23
- }
24
-
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
25
16
  if (s != null && typeof _Object$getOwnPropertySymbols === "function") for (var i = 0, p = _Object$getOwnPropertySymbols(s); i < p.length; i++) {
26
17
  if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
27
18
  }
28
19
  return t;
29
20
  };
30
-
31
21
  import { noop } from 'rxjs';
32
22
  import { features, TablePipeline } from '../../pipeline';
33
23
  import { isLeafNode as standardIsLeafNode } from '../../utils';
34
24
  import { ROW_KEY } from '../cross-table';
35
25
  export default function buildCrossTreeTable(options) {
36
26
  var _a, _b;
37
-
38
27
  var primaryColumn = options.primaryColumn,
39
- openKeys = options.openKeys,
40
- onChangeOpenKeys = options.onChangeOpenKeys,
41
- indentSize = options.indentSize,
42
- _options$isLeafNode = options.isLeafNode,
43
- isLeafNodeOpt = _options$isLeafNode === void 0 ? standardIsLeafNode : _options$isLeafNode; // 有的时候 leftTree/topTree 是通过 node.children 传入的
28
+ openKeys = options.openKeys,
29
+ onChangeOpenKeys = options.onChangeOpenKeys,
30
+ indentSize = options.indentSize,
31
+ _options$isLeafNode = options.isLeafNode,
32
+ isLeafNodeOpt = _options$isLeafNode === void 0 ? standardIsLeafNode : _options$isLeafNode;
33
+ // 有的时候 leftTree/topTree 是通过 node.children 传入的
44
34
  // 此时 leftTree/topTree 等于 null 和等于空数组是等价的
45
35
  // 故在这里兼容 leftTree/topTree 为空的情况
46
-
47
36
  var leftTree = (_a = options.leftTree) !== null && _a !== void 0 ? _a : [];
48
37
  var topTree = (_b = options.topTree) !== null && _b !== void 0 ? _b : [];
49
38
  var pipeline = new TablePipeline({
@@ -71,10 +60,8 @@ export default function buildCrossTreeTable(options) {
71
60
  columns: pipeline.getColumns()
72
61
  };
73
62
  /** 获取表格的列配置 */
74
-
75
63
  function getColumns() {
76
64
  var _context;
77
-
78
65
  return _concatInstanceProperty(_context = [_extends(_extends({}, primaryColumn), {
79
66
  getValue: function getValue(row) {
80
67
  return row.node.value;
@@ -88,35 +75,28 @@ export default function buildCrossTreeTable(options) {
88
75
  if (primaryColumn.render) {
89
76
  return primaryColumn.render(row.node, row.nodes.length - 1);
90
77
  }
91
-
92
78
  return value;
93
79
  }
94
80
  })]).call(_context, _toConsumableArray(getDataPartColumns()));
95
81
  /** 获取表格数据部分的列配置 */
96
-
97
82
  function getDataPartColumns() {
98
83
  return dfs(topTree, {
99
84
  depth: 0
100
85
  });
101
-
102
86
  function dfs(nodes, ctx) {
103
87
  var result = [];
104
-
105
88
  var _iterator = _createForOfIteratorHelper(nodes),
106
- _step;
107
-
89
+ _step;
108
90
  try {
109
91
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
110
92
  var node = _step.value;
111
-
112
93
  if (standardIsLeafNode(node)) {
113
94
  result.push(getDataColumn(node, ctx.depth));
114
95
  } else {
115
96
  var key = node.key,
116
- value = node.value,
117
- children = node.children,
118
- others = __rest(node, ["key", "value", "children"]);
119
-
97
+ value = node.value,
98
+ children = node.children,
99
+ others = __rest(node, ["key", "value", "children"]);
120
100
  result.push(_extends(_extends({}, others), {
121
101
  name: value,
122
102
  children: dfs(children, {
@@ -130,23 +110,19 @@ export default function buildCrossTreeTable(options) {
130
110
  } finally {
131
111
  _iterator.f();
132
112
  }
133
-
134
113
  return result;
135
114
  }
136
115
  }
137
-
138
116
  function getDataColumn(topNode, topDepth) {
139
117
  var columnGetValue = function columnGetValue(row) {
140
118
  var leftDepth = row.nodes.length - 1;
141
119
  var leftNode = row.node;
142
120
  return options.getValue(leftNode, topNode, leftDepth, topDepth);
143
121
  };
144
-
145
122
  var key = topNode.key,
146
- value = topNode.value,
147
- children = topNode.children,
148
- others = __rest(topNode, ["key", "value", "children"]);
149
-
123
+ value = topNode.value,
124
+ children = topNode.children,
125
+ others = __rest(topNode, ["key", "value", "children"]);
150
126
  return _extends(_extends({}, others), {
151
127
  getValue: columnGetValue,
152
128
  name: value,
@@ -157,7 +133,6 @@ export default function buildCrossTreeTable(options) {
157
133
  var leftNode = row.node;
158
134
  return options.render(value, leftNode, topNode, leftDepth, topDepth);
159
135
  }
160
-
161
136
  return value;
162
137
  },
163
138
  getCellProps: function getCellProps(value, row) {
@@ -170,39 +145,30 @@ export default function buildCrossTreeTable(options) {
170
145
  });
171
146
  }
172
147
  }
173
-
174
148
  function getDataSource() {
175
149
  return dfs(leftTree, {
176
150
  nodes: []
177
151
  });
178
-
179
152
  function dfs(nodes, ctx) {
180
153
  var result = [];
181
-
182
154
  var _iterator2 = _createForOfIteratorHelper(nodes),
183
- _step2;
184
-
155
+ _step2;
185
156
  try {
186
157
  for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
187
158
  var node = _step2.value;
188
-
189
159
  if (node.hidden) {
190
160
  // 跳过被隐藏的节点
191
161
  continue;
192
162
  }
193
-
194
163
  if (standardIsLeafNode(node)) {
195
- var _context2, _result$push;
196
-
197
- result.push((_result$push = {}, _defineProperty(_result$push, ROW_KEY, node.key), _defineProperty(_result$push, "node", node), _defineProperty(_result$push, "nodes", _concatInstanceProperty(_context2 = []).call(_context2, _toConsumableArray(ctx.nodes), [node])), _result$push));
164
+ var _context2;
165
+ result.push(_defineProperty(_defineProperty(_defineProperty({}, ROW_KEY, node.key), "node", node), "nodes", _concatInstanceProperty(_context2 = []).call(_context2, _toConsumableArray(ctx.nodes), [node])));
198
166
  } else {
199
- var _context3, _result$push2;
200
-
167
+ var _context3;
201
168
  var _nodes = _concatInstanceProperty(_context3 = []).call(_context3, _toConsumableArray(ctx.nodes), [node]);
202
-
203
169
  ctx.nodes.push(node);
204
170
  var children = dfs(node.children, ctx);
205
- result.push((_result$push2 = {}, _defineProperty(_result$push2, ROW_KEY, node.key), _defineProperty(_result$push2, "node", node), _defineProperty(_result$push2, "nodes", _nodes), _defineProperty(_result$push2, "children", children), _result$push2));
171
+ result.push(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, ROW_KEY, node.key), "node", node), "nodes", _nodes), "children", children));
206
172
  ctx.nodes.pop();
207
173
  }
208
174
  }
@@ -211,7 +177,6 @@ export default function buildCrossTreeTable(options) {
211
177
  } finally {
212
178
  _iterator2.f();
213
179
  }
214
-
215
180
  return result;
216
181
  }
217
182
  }