{"ast":null,"code":"var _excluded = [\"width\", \"height\", \"className\", \"style\", \"children\", \"type\"];\nfunction _typeof(o) {\n \"@babel/helpers - typeof\";\n\n return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) {\n return typeof o;\n } : function (o) {\n return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o;\n }, _typeof(o);\n}\nfunction _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}\nfunction _objectWithoutProperties(source, excluded) {\n if (source == null) return {};\n var target = _objectWithoutPropertiesLoose(source, excluded);\n var key, i;\n if (Object.getOwnPropertySymbols) {\n var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n for (i = 0; i < sourceSymbolKeys.length; i++) {\n key = sourceSymbolKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n target[key] = source[key];\n }\n }\n return target;\n}\nfunction _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n }\n return target;\n}\nfunction _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\nfunction _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor);\n }\n}\nfunction _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n Object.defineProperty(Constructor, \"prototype\", {\n writable: false\n });\n return Constructor;\n}\nfunction _callSuper(t, o, e) {\n return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e));\n}\nfunction _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n } else if (call !== void 0) {\n throw new TypeError(\"Derived constructors may only return object or undefined\");\n }\n return _assertThisInitialized(self);\n}\nfunction _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n return self;\n}\nfunction _isNativeReflectConstruct() {\n try {\n var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));\n } catch (t) {}\n return (_isNativeReflectConstruct = function _isNativeReflectConstruct() {\n return !!t;\n })();\n}\nfunction _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}\nfunction _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n Object.defineProperty(subClass, \"prototype\", {\n writable: false\n });\n if (superClass) _setPrototypeOf(subClass, superClass);\n}\nfunction _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}\nfunction ownKeys(e, r) {\n var t = Object.keys(e);\n if (Object.getOwnPropertySymbols) {\n var o = Object.getOwnPropertySymbols(e);\n r && (o = o.filter(function (r) {\n return Object.getOwnPropertyDescriptor(e, r).enumerable;\n })), t.push.apply(t, o);\n }\n return t;\n}\nfunction _objectSpread(e) {\n for (var r = 1; r < arguments.length; r++) {\n var t = null != arguments[r] ? arguments[r] : {};\n r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {\n _defineProperty(e, r, t[r]);\n }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {\n Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));\n });\n }\n return e;\n}\nfunction _defineProperty(obj, key, value) {\n key = _toPropertyKey(key);\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n return obj;\n}\nfunction _toPropertyKey(t) {\n var i = _toPrimitive(t, \"string\");\n return \"symbol\" == _typeof(i) ? i : i + \"\";\n}\nfunction _toPrimitive(t, r) {\n if (\"object\" != _typeof(t) || !t) return t;\n var e = t[Symbol.toPrimitive];\n if (void 0 !== e) {\n var i = e.call(t, r || \"default\");\n if (\"object\" != _typeof(i)) return i;\n throw new TypeError(\"@@toPrimitive must return a primitive value.\");\n }\n return (\"string\" === r ? String : Number)(t);\n}\nimport isNan from 'lodash/isNaN';\nimport isFunction from 'lodash/isFunction';\nimport omit from 'lodash/omit';\nimport get from 'lodash/get';\nimport clsx from 'clsx';\n/**\n * @fileOverview TreemapChart\n */\nimport React, { PureComponent } from 'react';\nimport Smooth from 'react-smooth';\nimport { Tooltip } from '../component/Tooltip';\nimport { Layer } from '../container/Layer';\nimport { Surface } from '../container/Surface';\nimport { Polygon } from '../shape/Polygon';\nimport { Rectangle } from '../shape/Rectangle';\nimport { getValueByDataKey } from '../util/ChartUtils';\nimport { COLOR_PANEL } from '../util/Constants';\nimport { uniqueId } from '../util/DataUtils';\nimport { getStringSize } from '../util/DOMUtils';\nimport { Global } from '../util/Global';\nimport { filterSvgElements, findChildByType, validateWidthHeight, filterProps } from '../util/ReactUtils';\nvar NODE_VALUE_KEY = 'value';\nvar computeNode = function computeNode(_ref) {\n var depth = _ref.depth,\n node = _ref.node,\n index = _ref.index,\n valueKey = _ref.valueKey;\n var children = node.children;\n var childDepth = depth + 1;\n var computedChildren = children && children.length ? children.map(function (child, i) {\n return computeNode({\n depth: childDepth,\n node: child,\n index: i,\n valueKey: valueKey\n });\n }) : null;\n var nodeValue;\n if (children && children.length) {\n nodeValue = computedChildren.reduce(function (result, child) {\n return result + child[NODE_VALUE_KEY];\n }, 0);\n } else {\n // TODO need to verify valueKey\n nodeValue = isNan(node[valueKey]) || node[valueKey] <= 0 ? 0 : node[valueKey];\n }\n return _objectSpread(_objectSpread({}, node), {}, _defineProperty(_defineProperty(_defineProperty({\n children: computedChildren\n }, NODE_VALUE_KEY, nodeValue), \"depth\", depth), \"index\", index));\n};\nvar filterRect = function filterRect(node) {\n return {\n x: node.x,\n y: node.y,\n width: node.width,\n height: node.height\n };\n};\n\n// Compute the area for each child based on value & scale.\nvar getAreaOfChildren = function getAreaOfChildren(children, areaValueRatio) {\n var ratio = areaValueRatio < 0 ? 0 : areaValueRatio;\n return children.map(function (child) {\n var area = child[NODE_VALUE_KEY] * ratio;\n return _objectSpread(_objectSpread({}, child), {}, {\n area: isNan(area) || area <= 0 ? 0 : area\n });\n });\n};\n\n// Computes the score for the specified row, as the worst aspect ratio.\nvar getWorstScore = function getWorstScore(row, parentSize, aspectRatio) {\n var parentArea = parentSize * parentSize;\n var rowArea = row.area * row.area;\n var _row$reduce = row.reduce(function (result, child) {\n return {\n min: Math.min(result.min, child.area),\n max: Math.max(result.max, child.area)\n };\n }, {\n min: Infinity,\n max: 0\n }),\n min = _row$reduce.min,\n max = _row$reduce.max;\n return rowArea ? Math.max(parentArea * max * aspectRatio / rowArea, rowArea / (parentArea * min * aspectRatio)) : Infinity;\n};\nvar horizontalPosition = function horizontalPosition(row, parentSize, parentRect, isFlush) {\n var rowHeight = parentSize ? Math.round(row.area / parentSize) : 0;\n if (isFlush || rowHeight > parentRect.height) {\n rowHeight = parentRect.height;\n }\n var curX = parentRect.x;\n var child;\n for (var i = 0, len = row.length; i < len; i++) {\n child = row[i];\n child.x = curX;\n child.y = parentRect.y;\n child.height = rowHeight;\n child.width = Math.min(rowHeight ? Math.round(child.area / rowHeight) : 0, parentRect.x + parentRect.width - curX);\n curX += child.width;\n }\n // add the remain x to the last one of row\n child.width += parentRect.x + parentRect.width - curX;\n return _objectSpread(_objectSpread({}, parentRect), {}, {\n y: parentRect.y + rowHeight,\n height: parentRect.height - rowHeight\n });\n};\nvar verticalPosition = function verticalPosition(row, parentSize, parentRect, isFlush) {\n var rowWidth = parentSize ? Math.round(row.area / parentSize) : 0;\n if (isFlush || rowWidth > parentRect.width) {\n rowWidth = parentRect.width;\n }\n var curY = parentRect.y;\n var child;\n for (var i = 0, len = row.length; i < len; i++) {\n child = row[i];\n child.x = parentRect.x;\n child.y = curY;\n child.width = rowWidth;\n child.height = Math.min(rowWidth ? Math.round(child.area / rowWidth) : 0, parentRect.y + parentRect.height - curY);\n curY += child.height;\n }\n if (child) {\n child.height += parentRect.y + parentRect.height - curY;\n }\n return _objectSpread(_objectSpread({}, parentRect), {}, {\n x: parentRect.x + rowWidth,\n width: parentRect.width - rowWidth\n });\n};\nvar position = function position(row, parentSize, parentRect, isFlush) {\n if (parentSize === parentRect.width) {\n return horizontalPosition(row, parentSize, parentRect, isFlush);\n }\n return verticalPosition(row, parentSize, parentRect, isFlush);\n};\n\n// Recursively arranges the specified node's children into squarified rows.\nvar squarify = function squarify(node, aspectRatio) {\n var children = node.children;\n if (children && children.length) {\n var rect = filterRect(node);\n // maybe a bug\n var row = [];\n var best = Infinity; // the best row score so far\n var child, score; // the current row score\n var size = Math.min(rect.width, rect.height); // initial orientation\n var scaleChildren = getAreaOfChildren(children, rect.width * rect.height / node[NODE_VALUE_KEY]);\n var tempChildren = scaleChildren.slice();\n row.area = 0;\n while (tempChildren.length > 0) {\n // row first\n // eslint-disable-next-line prefer-destructuring\n row.push(child = tempChildren[0]);\n row.area += child.area;\n score = getWorstScore(row, size, aspectRatio);\n if (score <= best) {\n // continue with this orientation\n tempChildren.shift();\n best = score;\n } else {\n // abort, and try a different orientation\n row.area -= row.pop().area;\n rect = position(row, size, rect, false);\n size = Math.min(rect.width, rect.height);\n row.length = row.area = 0;\n best = Infinity;\n }\n }\n if (row.length) {\n rect = position(row, size, rect, true);\n row.length = row.area = 0;\n }\n return _objectSpread(_objectSpread({}, node), {}, {\n children: scaleChildren.map(function (c) {\n return squarify(c, aspectRatio);\n })\n });\n }\n return node;\n};\nvar defaultState = {\n isTooltipActive: false,\n isAnimationFinished: false,\n activeNode: null,\n formatRoot: null,\n currentRoot: null,\n nestIndex: []\n};\nexport var Treemap = /*#__PURE__*/function (_PureComponent) {\n function Treemap() {\n var _this;\n _classCallCheck(this, Treemap);\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n _this = _callSuper(this, Treemap, [].concat(args));\n _defineProperty(_this, \"state\", _objectSpread({}, defaultState));\n _defineProperty(_this, \"handleAnimationEnd\", function () {\n var onAnimationEnd = _this.props.onAnimationEnd;\n _this.setState({\n isAnimationFinished: true\n });\n if (isFunction(onAnimationEnd)) {\n onAnimationEnd();\n }\n });\n _defineProperty(_this, \"handleAnimationStart\", function () {\n var onAnimationStart = _this.props.onAnimationStart;\n _this.setState({\n isAnimationFinished: false\n });\n if (isFunction(onAnimationStart)) {\n onAnimationStart();\n }\n });\n return _this;\n }\n _inherits(Treemap, _PureComponent);\n return _createClass(Treemap, [{\n key: \"handleMouseEnter\",\n value: function handleMouseEnter(node, e) {\n e.persist();\n var _this$props = this.props,\n onMouseEnter = _this$props.onMouseEnter,\n children = _this$props.children;\n var tooltipItem = findChildByType(children, Tooltip);\n if (tooltipItem) {\n this.setState({\n isTooltipActive: true,\n activeNode: node\n }, function () {\n if (onMouseEnter) {\n onMouseEnter(node, e);\n }\n });\n } else if (onMouseEnter) {\n onMouseEnter(node, e);\n }\n }\n }, {\n key: \"handleMouseLeave\",\n value: function handleMouseLeave(node, e) {\n e.persist();\n var _this$props2 = this.props,\n onMouseLeave = _this$props2.onMouseLeave,\n children = _this$props2.children;\n var tooltipItem = findChildByType(children, Tooltip);\n if (tooltipItem) {\n this.setState({\n isTooltipActive: false,\n activeNode: null\n }, function () {\n if (onMouseLeave) {\n onMouseLeave(node, e);\n }\n });\n } else if (onMouseLeave) {\n onMouseLeave(node, e);\n }\n }\n }, {\n key: \"handleClick\",\n value: function handleClick(node) {\n var _this$props3 = this.props,\n onClick = _this$props3.onClick,\n type = _this$props3.type;\n if (type === 'nest' && node.children) {\n var _this$props4 = this.props,\n width = _this$props4.width,\n height = _this$props4.height,\n dataKey = _this$props4.dataKey,\n aspectRatio = _this$props4.aspectRatio;\n var root = computeNode({\n depth: 0,\n node: _objectSpread(_objectSpread({}, node), {}, {\n x: 0,\n y: 0,\n width: width,\n height: height\n }),\n index: 0,\n valueKey: dataKey\n });\n var formatRoot = squarify(root, aspectRatio);\n var nestIndex = this.state.nestIndex;\n nestIndex.push(node);\n this.setState({\n formatRoot: formatRoot,\n currentRoot: root,\n nestIndex: nestIndex\n });\n }\n if (onClick) {\n onClick(node);\n }\n }\n }, {\n key: \"handleNestIndex\",\n value: function handleNestIndex(node, i) {\n var nestIndex = this.state.nestIndex;\n var _this$props5 = this.props,\n width = _this$props5.width,\n height = _this$props5.height,\n dataKey = _this$props5.dataKey,\n aspectRatio = _this$props5.aspectRatio;\n var root = computeNode({\n depth: 0,\n node: _objectSpread(_objectSpread({}, node), {}, {\n x: 0,\n y: 0,\n width: width,\n height: height\n }),\n index: 0,\n valueKey: dataKey\n });\n var formatRoot = squarify(root, aspectRatio);\n nestIndex = nestIndex.slice(0, i + 1);\n this.setState({\n formatRoot: formatRoot,\n currentRoot: node,\n nestIndex: nestIndex\n });\n }\n }, {\n key: \"renderItem\",\n value: function renderItem(content, nodeProps, isLeaf) {\n var _this2 = this;\n var _this$props6 = this.props,\n isAnimationActive = _this$props6.isAnimationActive,\n animationBegin = _this$props6.animationBegin,\n animationDuration = _this$props6.animationDuration,\n animationEasing = _this$props6.animationEasing,\n isUpdateAnimationActive = _this$props6.isUpdateAnimationActive,\n type = _this$props6.type,\n animationId = _this$props6.animationId,\n colorPanel = _this$props6.colorPanel;\n var isAnimationFinished = this.state.isAnimationFinished;\n var width = nodeProps.width,\n height = nodeProps.height,\n x = nodeProps.x,\n y = nodeProps.y,\n depth = nodeProps.depth;\n var translateX = parseInt(\"\".concat((Math.random() * 2 - 1) * width), 10);\n var event = {};\n if (isLeaf || type === 'nest') {\n event = {\n onMouseEnter: this.handleMouseEnter.bind(this, nodeProps),\n onMouseLeave: this.handleMouseLeave.bind(this, nodeProps),\n onClick: this.handleClick.bind(this, nodeProps)\n };\n }\n if (!isAnimationActive) {\n return /*#__PURE__*/React.createElement(Layer, event, this.constructor.renderContentItem(content, _objectSpread(_objectSpread({}, nodeProps), {}, {\n isAnimationActive: false,\n isUpdateAnimationActive: false,\n width: width,\n height: height,\n x: x,\n y: y\n }), type, colorPanel));\n }\n return /*#__PURE__*/React.createElement(Smooth, {\n begin: animationBegin,\n duration: animationDuration,\n isActive: isAnimationActive,\n easing: animationEasing,\n key: \"treemap-\".concat(animationId),\n from: {\n x: x,\n y: y,\n width: width,\n height: height\n },\n to: {\n x: x,\n y: y,\n width: width,\n height: height\n },\n onAnimationStart: this.handleAnimationStart,\n onAnimationEnd: this.handleAnimationEnd\n }, function (_ref2) {\n var currX = _ref2.x,\n currY = _ref2.y,\n currWidth = _ref2.width,\n currHeight = _ref2.height;\n return /*#__PURE__*/React.createElement(Smooth, {\n from: \"translate(\".concat(translateX, \"px, \").concat(translateX, \"px)\"),\n to: \"translate(0, 0)\",\n attributeName: \"transform\",\n begin: animationBegin,\n easing: animationEasing,\n isActive: isAnimationActive,\n duration: animationDuration\n }, /*#__PURE__*/React.createElement(Layer, event, function () {\n // when animation Duration , only render depth=1 nodes\n if (depth > 2 && !isAnimationFinished) {\n return null;\n }\n return _this2.constructor.renderContentItem(content, _objectSpread(_objectSpread({}, nodeProps), {}, {\n isAnimationActive: isAnimationActive,\n isUpdateAnimationActive: !isUpdateAnimationActive,\n width: currWidth,\n height: currHeight,\n x: currX,\n y: currY\n }), type, colorPanel);\n }()));\n });\n }\n }, {\n key: \"renderNode\",\n value: function renderNode(root, node) {\n var _this3 = this;\n var _this$props7 = this.props,\n content = _this$props7.content,\n type = _this$props7.type;\n var nodeProps = _objectSpread(_objectSpread(_objectSpread({}, filterProps(this.props, false)), node), {}, {\n root: root\n });\n var isLeaf = !node.children || !node.children.length;\n var currentRoot = this.state.currentRoot;\n var isCurrentRootChild = (currentRoot.children || []).filter(function (item) {\n return item.depth === node.depth && item.name === node.name;\n });\n if (!isCurrentRootChild.length && root.depth && type === 'nest') {\n return null;\n }\n return /*#__PURE__*/React.createElement(Layer, {\n key: \"recharts-treemap-node-\".concat(nodeProps.x, \"-\").concat(nodeProps.y, \"-\").concat(nodeProps.name),\n className: \"recharts-treemap-depth-\".concat(node.depth)\n }, this.renderItem(content, nodeProps, isLeaf), node.children && node.children.length ? node.children.map(function (child) {\n return _this3.renderNode(node, child);\n }) : null);\n }\n }, {\n key: \"renderAllNodes\",\n value: function renderAllNodes() {\n var formatRoot = this.state.formatRoot;\n if (!formatRoot) {\n return null;\n }\n return this.renderNode(formatRoot, formatRoot);\n }\n }, {\n key: \"renderTooltip\",\n value: function renderTooltip() {\n var _this$props8 = this.props,\n children = _this$props8.children,\n nameKey = _this$props8.nameKey;\n var tooltipItem = findChildByType(children, Tooltip);\n if (!tooltipItem) {\n return null;\n }\n var _this$props9 = this.props,\n width = _this$props9.width,\n height = _this$props9.height;\n var _this$state = this.state,\n isTooltipActive = _this$state.isTooltipActive,\n activeNode = _this$state.activeNode;\n var viewBox = {\n x: 0,\n y: 0,\n width: width,\n height: height\n };\n var coordinate = activeNode ? {\n x: activeNode.x + activeNode.width / 2,\n y: activeNode.y + activeNode.height / 2\n } : null;\n var payload = isTooltipActive && activeNode ? [{\n payload: activeNode,\n name: getValueByDataKey(activeNode, nameKey, ''),\n value: getValueByDataKey(activeNode, NODE_VALUE_KEY)\n }] : [];\n return /*#__PURE__*/React.cloneElement(tooltipItem, {\n viewBox: viewBox,\n active: isTooltipActive,\n coordinate: coordinate,\n label: '',\n payload: payload\n });\n }\n\n // render nest treemap\n }, {\n key: \"renderNestIndex\",\n value: function renderNestIndex() {\n var _this4 = this;\n var _this$props10 = this.props,\n nameKey = _this$props10.nameKey,\n nestIndexContent = _this$props10.nestIndexContent;\n var nestIndex = this.state.nestIndex;\n return /*#__PURE__*/React.createElement(\"div\", {\n className: \"recharts-treemap-nest-index-wrapper\",\n style: {\n marginTop: '8px',\n textAlign: 'center'\n }\n }, nestIndex.map(function (item, i) {\n // TODO need to verify nameKey type\n var name = get(item, nameKey, 'root');\n var content = null;\n if (/*#__PURE__*/React.isValidElement(nestIndexContent)) {\n content = /*#__PURE__*/React.cloneElement(nestIndexContent, item, i);\n }\n if (isFunction(nestIndexContent)) {\n content = nestIndexContent(item, i);\n } else {\n content = name;\n }\n return (/*#__PURE__*/\n // eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions\n React.createElement(\"div\", {\n onClick: _this4.handleNestIndex.bind(_this4, item, i),\n key: \"nest-index-\".concat(uniqueId()),\n className: \"recharts-treemap-nest-index-box\",\n style: {\n cursor: 'pointer',\n display: 'inline-block',\n padding: '0 7px',\n background: '#000',\n color: '#fff',\n marginRight: '3px'\n }\n }, content)\n );\n }));\n }\n }, {\n key: \"render\",\n value: function render() {\n if (!validateWidthHeight(this)) {\n return null;\n }\n var _this$props11 = this.props,\n width = _this$props11.width,\n height = _this$props11.height,\n className = _this$props11.className,\n style = _this$props11.style,\n children = _this$props11.children,\n type = _this$props11.type,\n others = _objectWithoutProperties(_this$props11, _excluded);\n var attrs = filterProps(others, false);\n return /*#__PURE__*/React.createElement(\"div\", {\n className: clsx('recharts-wrapper', className),\n style: _objectSpread(_objectSpread({}, style), {}, {\n position: 'relative',\n cursor: 'default',\n width: width,\n height: height\n }),\n role: \"region\"\n }, /*#__PURE__*/React.createElement(Surface, _extends({}, attrs, {\n width: width,\n height: type === 'nest' ? height - 30 : height\n }), this.renderAllNodes(), filterSvgElements(children)), this.renderTooltip(), type === 'nest' && this.renderNestIndex());\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(nextProps, prevState) {\n if (nextProps.data !== prevState.prevData || nextProps.type !== prevState.prevType || nextProps.width !== prevState.prevWidth || nextProps.height !== prevState.prevHeight || nextProps.dataKey !== prevState.prevDataKey || nextProps.aspectRatio !== prevState.prevAspectRatio) {\n var root = computeNode({\n depth: 0,\n node: {\n children: nextProps.data,\n x: 0,\n y: 0,\n width: nextProps.width,\n height: nextProps.height\n },\n index: 0,\n valueKey: nextProps.dataKey\n });\n var formatRoot = squarify(root, nextProps.aspectRatio);\n return _objectSpread(_objectSpread({}, prevState), {}, {\n formatRoot: formatRoot,\n currentRoot: root,\n nestIndex: [root],\n prevAspectRatio: nextProps.aspectRatio,\n prevData: nextProps.data,\n prevWidth: nextProps.width,\n prevHeight: nextProps.height,\n prevDataKey: nextProps.dataKey,\n prevType: nextProps.type\n });\n }\n return null;\n }\n }, {\n key: \"renderContentItem\",\n value: function renderContentItem(content, nodeProps, type, colorPanel) {\n if (/*#__PURE__*/React.isValidElement(content)) {\n return /*#__PURE__*/React.cloneElement(content, nodeProps);\n }\n if (isFunction(content)) {\n return content(nodeProps);\n }\n // optimize default shape\n var x = nodeProps.x,\n y = nodeProps.y,\n width = nodeProps.width,\n height = nodeProps.height,\n index = nodeProps.index;\n var arrow = null;\n if (width > 10 && height > 10 && nodeProps.children && type === 'nest') {\n arrow = /*#__PURE__*/React.createElement(Polygon, {\n points: [{\n x: x + 2,\n y: y + height / 2\n }, {\n x: x + 6,\n y: y + height / 2 + 3\n }, {\n x: x + 2,\n y: y + height / 2 + 6\n }]\n });\n }\n var text = null;\n var nameSize = getStringSize(nodeProps.name);\n if (width > 20 && height > 20 && nameSize.width < width && nameSize.height < height) {\n text = /*#__PURE__*/React.createElement(\"text\", {\n x: x + 8,\n y: y + height / 2 + 7,\n fontSize: 14\n }, nodeProps.name);\n }\n var colors = colorPanel || COLOR_PANEL;\n return /*#__PURE__*/React.createElement(\"g\", null, /*#__PURE__*/React.createElement(Rectangle, _extends({\n fill: nodeProps.depth < 2 ? colors[index % colors.length] : 'rgba(255,255,255,0)',\n stroke: \"#fff\"\n }, omit(nodeProps, 'children'), {\n role: \"img\"\n })), arrow, text);\n }\n }]);\n}(PureComponent);\n_defineProperty(Treemap, \"displayName\", 'Treemap');\n_defineProperty(Treemap, \"defaultProps\", {\n aspectRatio: 0.5 * (1 + Math.sqrt(5)),\n dataKey: 'value',\n type: 'flat',\n isAnimationActive: !Global.isSsr,\n isUpdateAnimationActive: !Global.isSsr,\n animationBegin: 0,\n animationDuration: 1500,\n animationEasing: 'linear'\n});","map":{"version":3,"names":["_excluded","_typeof","o","Symbol","iterator","constructor","prototype","_extends","Object","assign","bind","target","i","arguments","length","source","key","hasOwnProperty","call","apply","_objectWithoutProperties","excluded","_objectWithoutPropertiesLoose","getOwnPropertySymbols","sourceSymbolKeys","indexOf","propertyIsEnumerable","_classCallCheck","instance","Constructor","TypeError","_defineProperties","props","descriptor","enumerable","configurable","writable","defineProperty","_toPropertyKey","_createClass","protoProps","staticProps","_callSuper","t","e","_getPrototypeOf","_possibleConstructorReturn","_isNativeReflectConstruct","Reflect","construct","self","_assertThisInitialized","ReferenceError","Boolean","valueOf","setPrototypeOf","getPrototypeOf","__proto__","_inherits","subClass","superClass","create","value","_setPrototypeOf","p","ownKeys","r","keys","filter","getOwnPropertyDescriptor","push","_objectSpread","forEach","_defineProperty","getOwnPropertyDescriptors","defineProperties","obj","_toPrimitive","toPrimitive","String","Number","isNan","isFunction","omit","get","clsx","React","PureComponent","Smooth","Tooltip","Layer","Surface","Polygon","Rectangle","getValueByDataKey","COLOR_PANEL","uniqueId","getStringSize","Global","filterSvgElements","findChildByType","validateWidthHeight","filterProps","NODE_VALUE_KEY","computeNode","_ref","depth","node","index","valueKey","children","childDepth","computedChildren","map","child","nodeValue","reduce","result","filterRect","x","y","width","height","getAreaOfChildren","areaValueRatio","ratio","area","getWorstScore","row","parentSize","aspectRatio","parentArea","rowArea","_row$reduce","min","Math","max","Infinity","horizontalPosition","parentRect","isFlush","rowHeight","round","curX","len","verticalPosition","rowWidth","curY","position","squarify","rect","best","score","size","scaleChildren","tempChildren","slice","shift","pop","c","defaultState","isTooltipActive","isAnimationFinished","activeNode","formatRoot","currentRoot","nestIndex","Treemap","_PureComponent","_this","_len","args","Array","_key","concat","onAnimationEnd","setState","onAnimationStart","handleMouseEnter","persist","_this$props","onMouseEnter","tooltipItem","handleMouseLeave","_this$props2","onMouseLeave","handleClick","_this$props3","onClick","type","_this$props4","dataKey","root","state","handleNestIndex","_this$props5","renderItem","content","nodeProps","isLeaf","_this2","_this$props6","isAnimationActive","animationBegin","animationDuration","animationEasing","isUpdateAnimationActive","animationId","colorPanel","translateX","parseInt","random","event","createElement","renderContentItem","begin","duration","isActive","easing","from","to","handleAnimationStart","handleAnimationEnd","_ref2","currX","currY","currWidth","currHeight","attributeName","renderNode","_this3","_this$props7","isCurrentRootChild","item","name","className","renderAllNodes","renderTooltip","_this$props8","nameKey","_this$props9","_this$state","viewBox","coordinate","payload","cloneElement","active","label","renderNestIndex","_this4","_this$props10","nestIndexContent","style","marginTop","textAlign","isValidElement","cursor","display","padding","background","color","marginRight","render","_this$props11","others","attrs","role","getDerivedStateFromProps","nextProps","prevState","data","prevData","prevType","prevWidth","prevHeight","prevDataKey","prevAspectRatio","arrow","points","text","nameSize","fontSize","colors","fill","stroke","sqrt","isSsr"],"sources":["/home/gnx/Desktop/ETB/ETB-FrontEnd/node_modules/recharts/es6/chart/Treemap.js"],"sourcesContent":["var _excluded = [\"width\", \"height\", \"className\", \"style\", \"children\", \"type\"];\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, \"prototype\", { writable: false }); return Constructor; }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) { return call; } else if (call !== void 0) { throw new TypeError(\"Derived constructors may only return object or undefined\"); } return _assertThisInitialized(self); }\nfunction _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return self; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function\"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, \"prototype\", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }\nfunction _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport isNan from 'lodash/isNaN';\nimport isFunction from 'lodash/isFunction';\nimport omit from 'lodash/omit';\nimport get from 'lodash/get';\nimport clsx from 'clsx';\n/**\n * @fileOverview TreemapChart\n */\nimport React, { PureComponent } from 'react';\nimport Smooth from 'react-smooth';\nimport { Tooltip } from '../component/Tooltip';\nimport { Layer } from '../container/Layer';\nimport { Surface } from '../container/Surface';\nimport { Polygon } from '../shape/Polygon';\nimport { Rectangle } from '../shape/Rectangle';\nimport { getValueByDataKey } from '../util/ChartUtils';\nimport { COLOR_PANEL } from '../util/Constants';\nimport { uniqueId } from '../util/DataUtils';\nimport { getStringSize } from '../util/DOMUtils';\nimport { Global } from '../util/Global';\nimport { filterSvgElements, findChildByType, validateWidthHeight, filterProps } from '../util/ReactUtils';\nvar NODE_VALUE_KEY = 'value';\nvar computeNode = function computeNode(_ref) {\n var depth = _ref.depth,\n node = _ref.node,\n index = _ref.index,\n valueKey = _ref.valueKey;\n var children = node.children;\n var childDepth = depth + 1;\n var computedChildren = children && children.length ? children.map(function (child, i) {\n return computeNode({\n depth: childDepth,\n node: child,\n index: i,\n valueKey: valueKey\n });\n }) : null;\n var nodeValue;\n if (children && children.length) {\n nodeValue = computedChildren.reduce(function (result, child) {\n return result + child[NODE_VALUE_KEY];\n }, 0);\n } else {\n // TODO need to verify valueKey\n nodeValue = isNan(node[valueKey]) || node[valueKey] <= 0 ? 0 : node[valueKey];\n }\n return _objectSpread(_objectSpread({}, node), {}, _defineProperty(_defineProperty(_defineProperty({\n children: computedChildren\n }, NODE_VALUE_KEY, nodeValue), \"depth\", depth), \"index\", index));\n};\nvar filterRect = function filterRect(node) {\n return {\n x: node.x,\n y: node.y,\n width: node.width,\n height: node.height\n };\n};\n\n// Compute the area for each child based on value & scale.\nvar getAreaOfChildren = function getAreaOfChildren(children, areaValueRatio) {\n var ratio = areaValueRatio < 0 ? 0 : areaValueRatio;\n return children.map(function (child) {\n var area = child[NODE_VALUE_KEY] * ratio;\n return _objectSpread(_objectSpread({}, child), {}, {\n area: isNan(area) || area <= 0 ? 0 : area\n });\n });\n};\n\n// Computes the score for the specified row, as the worst aspect ratio.\nvar getWorstScore = function getWorstScore(row, parentSize, aspectRatio) {\n var parentArea = parentSize * parentSize;\n var rowArea = row.area * row.area;\n var _row$reduce = row.reduce(function (result, child) {\n return {\n min: Math.min(result.min, child.area),\n max: Math.max(result.max, child.area)\n };\n }, {\n min: Infinity,\n max: 0\n }),\n min = _row$reduce.min,\n max = _row$reduce.max;\n return rowArea ? Math.max(parentArea * max * aspectRatio / rowArea, rowArea / (parentArea * min * aspectRatio)) : Infinity;\n};\nvar horizontalPosition = function horizontalPosition(row, parentSize, parentRect, isFlush) {\n var rowHeight = parentSize ? Math.round(row.area / parentSize) : 0;\n if (isFlush || rowHeight > parentRect.height) {\n rowHeight = parentRect.height;\n }\n var curX = parentRect.x;\n var child;\n for (var i = 0, len = row.length; i < len; i++) {\n child = row[i];\n child.x = curX;\n child.y = parentRect.y;\n child.height = rowHeight;\n child.width = Math.min(rowHeight ? Math.round(child.area / rowHeight) : 0, parentRect.x + parentRect.width - curX);\n curX += child.width;\n }\n // add the remain x to the last one of row\n child.width += parentRect.x + parentRect.width - curX;\n return _objectSpread(_objectSpread({}, parentRect), {}, {\n y: parentRect.y + rowHeight,\n height: parentRect.height - rowHeight\n });\n};\nvar verticalPosition = function verticalPosition(row, parentSize, parentRect, isFlush) {\n var rowWidth = parentSize ? Math.round(row.area / parentSize) : 0;\n if (isFlush || rowWidth > parentRect.width) {\n rowWidth = parentRect.width;\n }\n var curY = parentRect.y;\n var child;\n for (var i = 0, len = row.length; i < len; i++) {\n child = row[i];\n child.x = parentRect.x;\n child.y = curY;\n child.width = rowWidth;\n child.height = Math.min(rowWidth ? Math.round(child.area / rowWidth) : 0, parentRect.y + parentRect.height - curY);\n curY += child.height;\n }\n if (child) {\n child.height += parentRect.y + parentRect.height - curY;\n }\n return _objectSpread(_objectSpread({}, parentRect), {}, {\n x: parentRect.x + rowWidth,\n width: parentRect.width - rowWidth\n });\n};\nvar position = function position(row, parentSize, parentRect, isFlush) {\n if (parentSize === parentRect.width) {\n return horizontalPosition(row, parentSize, parentRect, isFlush);\n }\n return verticalPosition(row, parentSize, parentRect, isFlush);\n};\n\n// Recursively arranges the specified node's children into squarified rows.\nvar squarify = function squarify(node, aspectRatio) {\n var children = node.children;\n if (children && children.length) {\n var rect = filterRect(node);\n // maybe a bug\n var row = [];\n var best = Infinity; // the best row score so far\n var child, score; // the current row score\n var size = Math.min(rect.width, rect.height); // initial orientation\n var scaleChildren = getAreaOfChildren(children, rect.width * rect.height / node[NODE_VALUE_KEY]);\n var tempChildren = scaleChildren.slice();\n row.area = 0;\n while (tempChildren.length > 0) {\n // row first\n // eslint-disable-next-line prefer-destructuring\n row.push(child = tempChildren[0]);\n row.area += child.area;\n score = getWorstScore(row, size, aspectRatio);\n if (score <= best) {\n // continue with this orientation\n tempChildren.shift();\n best = score;\n } else {\n // abort, and try a different orientation\n row.area -= row.pop().area;\n rect = position(row, size, rect, false);\n size = Math.min(rect.width, rect.height);\n row.length = row.area = 0;\n best = Infinity;\n }\n }\n if (row.length) {\n rect = position(row, size, rect, true);\n row.length = row.area = 0;\n }\n return _objectSpread(_objectSpread({}, node), {}, {\n children: scaleChildren.map(function (c) {\n return squarify(c, aspectRatio);\n })\n });\n }\n return node;\n};\nvar defaultState = {\n isTooltipActive: false,\n isAnimationFinished: false,\n activeNode: null,\n formatRoot: null,\n currentRoot: null,\n nestIndex: []\n};\nexport var Treemap = /*#__PURE__*/function (_PureComponent) {\n function Treemap() {\n var _this;\n _classCallCheck(this, Treemap);\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n _this = _callSuper(this, Treemap, [].concat(args));\n _defineProperty(_this, \"state\", _objectSpread({}, defaultState));\n _defineProperty(_this, \"handleAnimationEnd\", function () {\n var onAnimationEnd = _this.props.onAnimationEnd;\n _this.setState({\n isAnimationFinished: true\n });\n if (isFunction(onAnimationEnd)) {\n onAnimationEnd();\n }\n });\n _defineProperty(_this, \"handleAnimationStart\", function () {\n var onAnimationStart = _this.props.onAnimationStart;\n _this.setState({\n isAnimationFinished: false\n });\n if (isFunction(onAnimationStart)) {\n onAnimationStart();\n }\n });\n return _this;\n }\n _inherits(Treemap, _PureComponent);\n return _createClass(Treemap, [{\n key: \"handleMouseEnter\",\n value: function handleMouseEnter(node, e) {\n e.persist();\n var _this$props = this.props,\n onMouseEnter = _this$props.onMouseEnter,\n children = _this$props.children;\n var tooltipItem = findChildByType(children, Tooltip);\n if (tooltipItem) {\n this.setState({\n isTooltipActive: true,\n activeNode: node\n }, function () {\n if (onMouseEnter) {\n onMouseEnter(node, e);\n }\n });\n } else if (onMouseEnter) {\n onMouseEnter(node, e);\n }\n }\n }, {\n key: \"handleMouseLeave\",\n value: function handleMouseLeave(node, e) {\n e.persist();\n var _this$props2 = this.props,\n onMouseLeave = _this$props2.onMouseLeave,\n children = _this$props2.children;\n var tooltipItem = findChildByType(children, Tooltip);\n if (tooltipItem) {\n this.setState({\n isTooltipActive: false,\n activeNode: null\n }, function () {\n if (onMouseLeave) {\n onMouseLeave(node, e);\n }\n });\n } else if (onMouseLeave) {\n onMouseLeave(node, e);\n }\n }\n }, {\n key: \"handleClick\",\n value: function handleClick(node) {\n var _this$props3 = this.props,\n onClick = _this$props3.onClick,\n type = _this$props3.type;\n if (type === 'nest' && node.children) {\n var _this$props4 = this.props,\n width = _this$props4.width,\n height = _this$props4.height,\n dataKey = _this$props4.dataKey,\n aspectRatio = _this$props4.aspectRatio;\n var root = computeNode({\n depth: 0,\n node: _objectSpread(_objectSpread({}, node), {}, {\n x: 0,\n y: 0,\n width: width,\n height: height\n }),\n index: 0,\n valueKey: dataKey\n });\n var formatRoot = squarify(root, aspectRatio);\n var nestIndex = this.state.nestIndex;\n nestIndex.push(node);\n this.setState({\n formatRoot: formatRoot,\n currentRoot: root,\n nestIndex: nestIndex\n });\n }\n if (onClick) {\n onClick(node);\n }\n }\n }, {\n key: \"handleNestIndex\",\n value: function handleNestIndex(node, i) {\n var nestIndex = this.state.nestIndex;\n var _this$props5 = this.props,\n width = _this$props5.width,\n height = _this$props5.height,\n dataKey = _this$props5.dataKey,\n aspectRatio = _this$props5.aspectRatio;\n var root = computeNode({\n depth: 0,\n node: _objectSpread(_objectSpread({}, node), {}, {\n x: 0,\n y: 0,\n width: width,\n height: height\n }),\n index: 0,\n valueKey: dataKey\n });\n var formatRoot = squarify(root, aspectRatio);\n nestIndex = nestIndex.slice(0, i + 1);\n this.setState({\n formatRoot: formatRoot,\n currentRoot: node,\n nestIndex: nestIndex\n });\n }\n }, {\n key: \"renderItem\",\n value: function renderItem(content, nodeProps, isLeaf) {\n var _this2 = this;\n var _this$props6 = this.props,\n isAnimationActive = _this$props6.isAnimationActive,\n animationBegin = _this$props6.animationBegin,\n animationDuration = _this$props6.animationDuration,\n animationEasing = _this$props6.animationEasing,\n isUpdateAnimationActive = _this$props6.isUpdateAnimationActive,\n type = _this$props6.type,\n animationId = _this$props6.animationId,\n colorPanel = _this$props6.colorPanel;\n var isAnimationFinished = this.state.isAnimationFinished;\n var width = nodeProps.width,\n height = nodeProps.height,\n x = nodeProps.x,\n y = nodeProps.y,\n depth = nodeProps.depth;\n var translateX = parseInt(\"\".concat((Math.random() * 2 - 1) * width), 10);\n var event = {};\n if (isLeaf || type === 'nest') {\n event = {\n onMouseEnter: this.handleMouseEnter.bind(this, nodeProps),\n onMouseLeave: this.handleMouseLeave.bind(this, nodeProps),\n onClick: this.handleClick.bind(this, nodeProps)\n };\n }\n if (!isAnimationActive) {\n return /*#__PURE__*/React.createElement(Layer, event, this.constructor.renderContentItem(content, _objectSpread(_objectSpread({}, nodeProps), {}, {\n isAnimationActive: false,\n isUpdateAnimationActive: false,\n width: width,\n height: height,\n x: x,\n y: y\n }), type, colorPanel));\n }\n return /*#__PURE__*/React.createElement(Smooth, {\n begin: animationBegin,\n duration: animationDuration,\n isActive: isAnimationActive,\n easing: animationEasing,\n key: \"treemap-\".concat(animationId),\n from: {\n x: x,\n y: y,\n width: width,\n height: height\n },\n to: {\n x: x,\n y: y,\n width: width,\n height: height\n },\n onAnimationStart: this.handleAnimationStart,\n onAnimationEnd: this.handleAnimationEnd\n }, function (_ref2) {\n var currX = _ref2.x,\n currY = _ref2.y,\n currWidth = _ref2.width,\n currHeight = _ref2.height;\n return /*#__PURE__*/React.createElement(Smooth, {\n from: \"translate(\".concat(translateX, \"px, \").concat(translateX, \"px)\"),\n to: \"translate(0, 0)\",\n attributeName: \"transform\",\n begin: animationBegin,\n easing: animationEasing,\n isActive: isAnimationActive,\n duration: animationDuration\n }, /*#__PURE__*/React.createElement(Layer, event, function () {\n // when animation Duration , only render depth=1 nodes\n if (depth > 2 && !isAnimationFinished) {\n return null;\n }\n return _this2.constructor.renderContentItem(content, _objectSpread(_objectSpread({}, nodeProps), {}, {\n isAnimationActive: isAnimationActive,\n isUpdateAnimationActive: !isUpdateAnimationActive,\n width: currWidth,\n height: currHeight,\n x: currX,\n y: currY\n }), type, colorPanel);\n }()));\n });\n }\n }, {\n key: \"renderNode\",\n value: function renderNode(root, node) {\n var _this3 = this;\n var _this$props7 = this.props,\n content = _this$props7.content,\n type = _this$props7.type;\n var nodeProps = _objectSpread(_objectSpread(_objectSpread({}, filterProps(this.props, false)), node), {}, {\n root: root\n });\n var isLeaf = !node.children || !node.children.length;\n var currentRoot = this.state.currentRoot;\n var isCurrentRootChild = (currentRoot.children || []).filter(function (item) {\n return item.depth === node.depth && item.name === node.name;\n });\n if (!isCurrentRootChild.length && root.depth && type === 'nest') {\n return null;\n }\n return /*#__PURE__*/React.createElement(Layer, {\n key: \"recharts-treemap-node-\".concat(nodeProps.x, \"-\").concat(nodeProps.y, \"-\").concat(nodeProps.name),\n className: \"recharts-treemap-depth-\".concat(node.depth)\n }, this.renderItem(content, nodeProps, isLeaf), node.children && node.children.length ? node.children.map(function (child) {\n return _this3.renderNode(node, child);\n }) : null);\n }\n }, {\n key: \"renderAllNodes\",\n value: function renderAllNodes() {\n var formatRoot = this.state.formatRoot;\n if (!formatRoot) {\n return null;\n }\n return this.renderNode(formatRoot, formatRoot);\n }\n }, {\n key: \"renderTooltip\",\n value: function renderTooltip() {\n var _this$props8 = this.props,\n children = _this$props8.children,\n nameKey = _this$props8.nameKey;\n var tooltipItem = findChildByType(children, Tooltip);\n if (!tooltipItem) {\n return null;\n }\n var _this$props9 = this.props,\n width = _this$props9.width,\n height = _this$props9.height;\n var _this$state = this.state,\n isTooltipActive = _this$state.isTooltipActive,\n activeNode = _this$state.activeNode;\n var viewBox = {\n x: 0,\n y: 0,\n width: width,\n height: height\n };\n var coordinate = activeNode ? {\n x: activeNode.x + activeNode.width / 2,\n y: activeNode.y + activeNode.height / 2\n } : null;\n var payload = isTooltipActive && activeNode ? [{\n payload: activeNode,\n name: getValueByDataKey(activeNode, nameKey, ''),\n value: getValueByDataKey(activeNode, NODE_VALUE_KEY)\n }] : [];\n return /*#__PURE__*/React.cloneElement(tooltipItem, {\n viewBox: viewBox,\n active: isTooltipActive,\n coordinate: coordinate,\n label: '',\n payload: payload\n });\n }\n\n // render nest treemap\n }, {\n key: \"renderNestIndex\",\n value: function renderNestIndex() {\n var _this4 = this;\n var _this$props10 = this.props,\n nameKey = _this$props10.nameKey,\n nestIndexContent = _this$props10.nestIndexContent;\n var nestIndex = this.state.nestIndex;\n return /*#__PURE__*/React.createElement(\"div\", {\n className: \"recharts-treemap-nest-index-wrapper\",\n style: {\n marginTop: '8px',\n textAlign: 'center'\n }\n }, nestIndex.map(function (item, i) {\n // TODO need to verify nameKey type\n var name = get(item, nameKey, 'root');\n var content = null;\n if ( /*#__PURE__*/React.isValidElement(nestIndexContent)) {\n content = /*#__PURE__*/React.cloneElement(nestIndexContent, item, i);\n }\n if (isFunction(nestIndexContent)) {\n content = nestIndexContent(item, i);\n } else {\n content = name;\n }\n return (\n /*#__PURE__*/\n // eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions\n React.createElement(\"div\", {\n onClick: _this4.handleNestIndex.bind(_this4, item, i),\n key: \"nest-index-\".concat(uniqueId()),\n className: \"recharts-treemap-nest-index-box\",\n style: {\n cursor: 'pointer',\n display: 'inline-block',\n padding: '0 7px',\n background: '#000',\n color: '#fff',\n marginRight: '3px'\n }\n }, content)\n );\n }));\n }\n }, {\n key: \"render\",\n value: function render() {\n if (!validateWidthHeight(this)) {\n return null;\n }\n var _this$props11 = this.props,\n width = _this$props11.width,\n height = _this$props11.height,\n className = _this$props11.className,\n style = _this$props11.style,\n children = _this$props11.children,\n type = _this$props11.type,\n others = _objectWithoutProperties(_this$props11, _excluded);\n var attrs = filterProps(others, false);\n return /*#__PURE__*/React.createElement(\"div\", {\n className: clsx('recharts-wrapper', className),\n style: _objectSpread(_objectSpread({}, style), {}, {\n position: 'relative',\n cursor: 'default',\n width: width,\n height: height\n }),\n role: \"region\"\n }, /*#__PURE__*/React.createElement(Surface, _extends({}, attrs, {\n width: width,\n height: type === 'nest' ? height - 30 : height\n }), this.renderAllNodes(), filterSvgElements(children)), this.renderTooltip(), type === 'nest' && this.renderNestIndex());\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(nextProps, prevState) {\n if (nextProps.data !== prevState.prevData || nextProps.type !== prevState.prevType || nextProps.width !== prevState.prevWidth || nextProps.height !== prevState.prevHeight || nextProps.dataKey !== prevState.prevDataKey || nextProps.aspectRatio !== prevState.prevAspectRatio) {\n var root = computeNode({\n depth: 0,\n node: {\n children: nextProps.data,\n x: 0,\n y: 0,\n width: nextProps.width,\n height: nextProps.height\n },\n index: 0,\n valueKey: nextProps.dataKey\n });\n var formatRoot = squarify(root, nextProps.aspectRatio);\n return _objectSpread(_objectSpread({}, prevState), {}, {\n formatRoot: formatRoot,\n currentRoot: root,\n nestIndex: [root],\n prevAspectRatio: nextProps.aspectRatio,\n prevData: nextProps.data,\n prevWidth: nextProps.width,\n prevHeight: nextProps.height,\n prevDataKey: nextProps.dataKey,\n prevType: nextProps.type\n });\n }\n return null;\n }\n }, {\n key: \"renderContentItem\",\n value: function renderContentItem(content, nodeProps, type, colorPanel) {\n if ( /*#__PURE__*/React.isValidElement(content)) {\n return /*#__PURE__*/React.cloneElement(content, nodeProps);\n }\n if (isFunction(content)) {\n return content(nodeProps);\n }\n // optimize default shape\n var x = nodeProps.x,\n y = nodeProps.y,\n width = nodeProps.width,\n height = nodeProps.height,\n index = nodeProps.index;\n var arrow = null;\n if (width > 10 && height > 10 && nodeProps.children && type === 'nest') {\n arrow = /*#__PURE__*/React.createElement(Polygon, {\n points: [{\n x: x + 2,\n y: y + height / 2\n }, {\n x: x + 6,\n y: y + height / 2 + 3\n }, {\n x: x + 2,\n y: y + height / 2 + 6\n }]\n });\n }\n var text = null;\n var nameSize = getStringSize(nodeProps.name);\n if (width > 20 && height > 20 && nameSize.width < width && nameSize.height < height) {\n text = /*#__PURE__*/React.createElement(\"text\", {\n x: x + 8,\n y: y + height / 2 + 7,\n fontSize: 14\n }, nodeProps.name);\n }\n var colors = colorPanel || COLOR_PANEL;\n return /*#__PURE__*/React.createElement(\"g\", null, /*#__PURE__*/React.createElement(Rectangle, _extends({\n fill: nodeProps.depth < 2 ? colors[index % colors.length] : 'rgba(255,255,255,0)',\n stroke: \"#fff\"\n }, omit(nodeProps, 'children'), {\n role: \"img\"\n })), arrow, text);\n }\n }]);\n}(PureComponent);\n_defineProperty(Treemap, \"displayName\", 'Treemap');\n_defineProperty(Treemap, \"defaultProps\", {\n aspectRatio: 0.5 * (1 + Math.sqrt(5)),\n dataKey: 'value',\n type: 'flat',\n isAnimationActive: !Global.isSsr,\n isUpdateAnimationActive: !Global.isSsr,\n animationBegin: 0,\n animationDuration: 1500,\n animationEasing: 'linear'\n});"],"mappings":"AAAA,IAAIA,SAAS,GAAG,CAAC,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,CAAC;AAC7E,SAASC,OAAOA,CAACC,CAAC,EAAE;EAAE,yBAAyB;;EAAE,OAAOD,OAAO,GAAG,UAAU,IAAI,OAAOE,MAAM,IAAI,QAAQ,IAAI,OAAOA,MAAM,CAACC,QAAQ,GAAG,UAAUF,CAAC,EAAE;IAAE,OAAO,OAAOA,CAAC;EAAE,CAAC,GAAG,UAAUA,CAAC,EAAE;IAAE,OAAOA,CAAC,IAAI,UAAU,IAAI,OAAOC,MAAM,IAAID,CAAC,CAACG,WAAW,KAAKF,MAAM,IAAID,CAAC,KAAKC,MAAM,CAACG,SAAS,GAAG,QAAQ,GAAG,OAAOJ,CAAC;EAAE,CAAC,EAAED,OAAO,CAACC,CAAC,CAAC;AAAE;AAC7T,SAASK,QAAQA,CAAA,EAAG;EAAEA,QAAQ,GAAGC,MAAM,CAACC,MAAM,GAAGD,MAAM,CAACC,MAAM,CAACC,IAAI,CAAC,CAAC,GAAG,UAAUC,MAAM,EAAE;IAAE,KAAK,IAAIC,CAAC,GAAG,CAAC,EAAEA,CAAC,GAAGC,SAAS,CAACC,MAAM,EAAEF,CAAC,EAAE,EAAE;MAAE,IAAIG,MAAM,GAAGF,SAAS,CAACD,CAAC,CAAC;MAAE,KAAK,IAAII,GAAG,IAAID,MAAM,EAAE;QAAE,IAAIP,MAAM,CAACF,SAAS,CAACW,cAAc,CAACC,IAAI,CAACH,MAAM,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