{"ast":null,"code":"/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\n\n/**\n * AUTO-GENERATED FILE. DO NOT MODIFY.\n */\n\n/*\r\n* Licensed to the Apache Software Foundation (ASF) under one\r\n* or more contributor license agreements. See the NOTICE file\r\n* distributed with this work for additional information\r\n* regarding copyright ownership. The ASF licenses this file\r\n* to you under the Apache License, Version 2.0 (the\r\n* \"License\"); you may not use this file except in compliance\r\n* with the License. You may obtain a copy of the License at\r\n*\r\n* http://www.apache.org/licenses/LICENSE-2.0\r\n*\r\n* Unless required by applicable law or agreed to in writing,\r\n* software distributed under the License is distributed on an\r\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\n* KIND, either express or implied. See the License for the\r\n* specific language governing permissions and limitations\r\n* under the License.\r\n*/\nimport * as vec2 from 'zrender/lib/core/vector.js';\nimport { getSymbolSize, getNodeGlobalScale } from './graphHelper.js';\nimport * as zrUtil from 'zrender/lib/core/util.js';\nimport { getCurvenessForEdge } from '../helper/multipleGraphEdgeHelper.js';\nvar PI = Math.PI;\nvar _symbolRadiansHalf = [];\n/**\r\n * `basedOn` can be:\r\n * 'value':\r\n * This layout is not accurate and have same bad case. For example,\r\n * if the min value is very smaller than the max value, the nodes\r\n * with the min value probably overlap even though there is enough\r\n * space to layout them. So we only use this approach in the as the\r\n * init layout of the force layout.\r\n * FIXME\r\n * Probably we do not need this method any more but use\r\n * `basedOn: 'symbolSize'` in force layout if\r\n * delay its init operations to GraphView.\r\n * 'symbolSize':\r\n * This approach work only if all of the symbol size calculated.\r\n * That is, the progressive rendering is not applied to graph.\r\n * FIXME\r\n * If progressive rendering is applied to graph some day,\r\n * probably we have to use `basedOn: 'value'`.\r\n */\nexport function circularLayout(seriesModel, basedOn, draggingNode, pointer) {\n var coordSys = seriesModel.coordinateSystem;\n if (coordSys && coordSys.type !== 'view') {\n return;\n }\n var rect = coordSys.getBoundingRect();\n var nodeData = seriesModel.getData();\n var graph = nodeData.graph;\n var cx = rect.width / 2 + rect.x;\n var cy = rect.height / 2 + rect.y;\n var r = Math.min(rect.width, rect.height) / 2;\n var count = nodeData.count();\n nodeData.setLayout({\n cx: cx,\n cy: cy\n });\n if (!count) {\n return;\n }\n if (draggingNode) {\n var _a = coordSys.pointToData(pointer),\n tempX = _a[0],\n tempY = _a[1];\n var v = [tempX - cx, tempY - cy];\n vec2.normalize(v, v);\n vec2.scale(v, v, r);\n draggingNode.setLayout([cx + v[0], cy + v[1]], true);\n var circularRotateLabel = seriesModel.get(['circular', 'rotateLabel']);\n rotateNodeLabel(draggingNode, circularRotateLabel, cx, cy);\n }\n _layoutNodesBasedOn[basedOn](seriesModel, graph, nodeData, r, cx, cy, count);\n graph.eachEdge(function (edge, index) {\n var curveness = zrUtil.retrieve3(edge.getModel().get(['lineStyle', 'curveness']), getCurvenessForEdge(edge, seriesModel, index), 0);\n var p1 = vec2.clone(edge.node1.getLayout());\n var p2 = vec2.clone(edge.node2.getLayout());\n var cp1;\n var x12 = (p1[0] + p2[0]) / 2;\n var y12 = (p1[1] + p2[1]) / 2;\n if (+curveness) {\n curveness *= 3;\n cp1 = [cx * curveness + x12 * (1 - curveness), cy * curveness + y12 * (1 - curveness)];\n }\n edge.setLayout([p1, p2, cp1]);\n });\n}\nvar _layoutNodesBasedOn = {\n value: function (seriesModel, graph, nodeData, r, cx, cy, count) {\n var angle = 0;\n var sum = nodeData.getSum('value');\n var unitAngle = Math.PI * 2 / (sum || count);\n graph.eachNode(function (node) {\n var value = node.getValue('value');\n var radianHalf = unitAngle * (sum ? value : 1) / 2;\n angle += radianHalf;\n node.setLayout([r * Math.cos(angle) + cx, r * Math.sin(angle) + cy]);\n angle += radianHalf;\n });\n },\n symbolSize: function (seriesModel, graph, nodeData, r, cx, cy, count) {\n var sumRadian = 0;\n _symbolRadiansHalf.length = count;\n var nodeScale = getNodeGlobalScale(seriesModel);\n graph.eachNode(function (node) {\n var symbolSize = getSymbolSize(node);\n // Normally this case will not happen, but we still add\n // some the defensive code (2px is an arbitrary value).\n isNaN(symbolSize) && (symbolSize = 2);\n symbolSize < 0 && (symbolSize = 0);\n symbolSize *= nodeScale;\n var symbolRadianHalf = Math.asin(symbolSize / 2 / r);\n // when `symbolSize / 2` is bigger than `r`.\n isNaN(symbolRadianHalf) && (symbolRadianHalf = PI / 2);\n _symbolRadiansHalf[node.dataIndex] = symbolRadianHalf;\n sumRadian += symbolRadianHalf * 2;\n });\n var halfRemainRadian = (2 * PI - sumRadian) / count / 2;\n var angle = 0;\n graph.eachNode(function (node) {\n var radianHalf = halfRemainRadian + _symbolRadiansHalf[node.dataIndex];\n angle += radianHalf;\n // init circular layout for\n // 1. layout undefined node\n // 2. not fixed node\n (!node.getLayout() || !node.getLayout().fixed) && node.setLayout([r * Math.cos(angle) + cx, r * Math.sin(angle) + cy]);\n angle += radianHalf;\n });\n }\n};\nexport function rotateNodeLabel(node, circularRotateLabel, cx, cy) {\n var el = node.getGraphicEl();\n // need to check if el exists. '-' value may not create node element.\n if (!el) {\n return;\n }\n var nodeModel = node.getModel();\n var labelRotate = nodeModel.get(['label', 'rotate']) || 0;\n var symbolPath = el.getSymbolPath();\n if (circularRotateLabel) {\n var pos = node.getLayout();\n var rad = Math.atan2(pos[1] - cy, pos[0] - cx);\n if (rad < 0) {\n rad = Math.PI * 2 + rad;\n }\n var isLeft = pos[0] < cx;\n if (isLeft) {\n rad = rad - Math.PI;\n }\n var textPosition = isLeft ? 'left' : 'right';\n symbolPath.setTextConfig({\n rotation: -rad,\n position: textPosition,\n origin: 'center'\n });\n var emphasisState = symbolPath.ensureState('emphasis');\n zrUtil.extend(emphasisState.textConfig || (emphasisState.textConfig = {}), {\n position: textPosition\n });\n } else {\n symbolPath.setTextConfig({\n rotation: labelRotate *= Math.PI / 180\n });\n }\n}","map":{"version":3,"names":["vec2","getSymbolSize","getNodeGlobalScale","zrUtil","getCurvenessForEdge","PI","Math","_symbolRadiansHalf","circularLayout","seriesModel","basedOn","draggingNode","pointer","coordSys","coordinateSystem","type","rect","getBoundingRect","nodeData","getData","graph","cx","width","x","cy","height","y","r","min","count","setLayout","_a","pointToData","tempX","tempY","v","normalize","scale","circularRotateLabel","get","rotateNodeLabel","_layoutNodesBasedOn","eachEdge","edge","index","curveness","retrieve3","getModel","p1","clone","node1","getLayout","p2","node2","cp1","x12","y12","value","angle","sum","getSum","unitAngle","eachNode","node","getValue","radianHalf","cos","sin","symbolSize","sumRadian","length","nodeScale","isNaN","symbolRadianHalf","asin","dataIndex","halfRemainRadian","fixed","el","getGraphicEl","nodeModel","labelRotate","symbolPath","getSymbolPath","pos","rad","atan2","isLeft","textPosition","setTextConfig","rotation","position","origin","emphasisState","ensureState","extend","textConfig"],"sources":["/data/jenkins/workspace/badp-bcxin-web-access/node_modules/echarts/lib/chart/graph/circularLayoutHelper.js"],"sourcesContent":["\n/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\n\n\n/**\n * AUTO-GENERATED FILE. DO NOT MODIFY.\n */\n\n/*\r\n* Licensed to the Apache Software Foundation (ASF) under one\r\n* or more contributor license agreements. See the NOTICE file\r\n* distributed with this work for additional information\r\n* regarding copyright ownership. The ASF licenses this file\r\n* to you under the Apache License, Version 2.0 (the\r\n* \"License\"); you may not use this file except in compliance\r\n* with the License. You may obtain a copy of the License at\r\n*\r\n* http://www.apache.org/licenses/LICENSE-2.0\r\n*\r\n* Unless required by applicable law or agreed to in writing,\r\n* software distributed under the License is distributed on an\r\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\n* KIND, either express or implied. See the License for the\r\n* specific language governing permissions and limitations\r\n* under the License.\r\n*/\nimport * as vec2 from 'zrender/lib/core/vector.js';\nimport { getSymbolSize, getNodeGlobalScale } from './graphHelper.js';\nimport * as zrUtil from 'zrender/lib/core/util.js';\nimport { getCurvenessForEdge } from '../helper/multipleGraphEdgeHelper.js';\nvar PI = Math.PI;\nvar _symbolRadiansHalf = [];\n/**\r\n * `basedOn` can be:\r\n * 'value':\r\n * This layout is not accurate and have same bad case. For example,\r\n * if the min value is very smaller than the max value, the nodes\r\n * with the min value probably overlap even though there is enough\r\n * space to layout them. So we only use this approach in the as the\r\n * init layout of the force layout.\r\n * FIXME\r\n * Probably we do not need this method any more but use\r\n * `basedOn: 'symbolSize'` in force layout if\r\n * delay its init operations to GraphView.\r\n * 'symbolSize':\r\n * This approach work only if all of the symbol size calculated.\r\n * That is, the progressive rendering is not applied to graph.\r\n * FIXME\r\n * If progressive rendering is applied to graph some day,\r\n * probably we have to use `basedOn: 'value'`.\r\n */\nexport function circularLayout(seriesModel, basedOn, draggingNode, pointer) {\n var coordSys = seriesModel.coordinateSystem;\n if (coordSys && coordSys.type !== 'view') {\n return;\n }\n var rect = coordSys.getBoundingRect();\n var nodeData = seriesModel.getData();\n var graph = nodeData.graph;\n var cx = rect.width / 2 + rect.x;\n var cy = rect.height / 2 + rect.y;\n var r = Math.min(rect.width, rect.height) / 2;\n var count = nodeData.count();\n nodeData.setLayout({\n cx: cx,\n cy: cy\n });\n if (!count) {\n return;\n }\n if (draggingNode) {\n var _a = coordSys.pointToData(pointer),\n tempX = _a[0],\n tempY = _a[1];\n var v = [tempX - cx, tempY - cy];\n vec2.normalize(v, v);\n vec2.scale(v, v, r);\n draggingNode.setLayout([cx + v[0], cy + v[1]], true);\n var circularRotateLabel = seriesModel.get(['circular', 'rotateLabel']);\n rotateNodeLabel(draggingNode, circularRotateLabel, cx, cy);\n }\n _layoutNodesBasedOn[basedOn](seriesModel, graph, nodeData, r, cx, cy, count);\n graph.eachEdge(function (edge, index) {\n var curveness = zrUtil.retrieve3(edge.getModel().get(['lineStyle', 'curveness']), getCurvenessForEdge(edge, seriesModel, index), 0);\n var p1 = vec2.clone(edge.node1.getLayout());\n var p2 = vec2.clone(edge.node2.getLayout());\n var cp1;\n var x12 = (p1[0] + p2[0]) / 2;\n var y12 = (p1[1] + p2[1]) / 2;\n if (+curveness) {\n curveness *= 3;\n cp1 = [cx * curveness + x12 * (1 - curveness), cy * curveness + y12 * (1 - curveness)];\n }\n edge.setLayout([p1, p2, cp1]);\n });\n}\nvar _layoutNodesBasedOn = {\n value: function (seriesModel, graph, nodeData, r, cx, cy, count) {\n var angle = 0;\n var sum = nodeData.getSum('value');\n var unitAngle = Math.PI * 2 / (sum || count);\n graph.eachNode(function (node) {\n var value = node.getValue('value');\n var radianHalf = unitAngle * (sum ? value : 1) / 2;\n angle += radianHalf;\n node.setLayout([r * Math.cos(angle) + cx, r * Math.sin(angle) + cy]);\n angle += radianHalf;\n });\n },\n symbolSize: function (seriesModel, graph, nodeData, r, cx, cy, count) {\n var sumRadian = 0;\n _symbolRadiansHalf.length = count;\n var nodeScale = getNodeGlobalScale(seriesModel);\n graph.eachNode(function (node) {\n var symbolSize = getSymbolSize(node);\n // Normally this case will not happen, but we still add\n // some the defensive code (2px is an arbitrary value).\n isNaN(symbolSize) && (symbolSize = 2);\n symbolSize < 0 && (symbolSize = 0);\n symbolSize *= nodeScale;\n var symbolRadianHalf = Math.asin(symbolSize / 2 / r);\n // when `symbolSize / 2` is bigger than `r`.\n isNaN(symbolRadianHalf) && (symbolRadianHalf = PI / 2);\n _symbolRadiansHalf[node.dataIndex] = symbolRadianHalf;\n sumRadian += symbolRadianHalf * 2;\n });\n var halfRemainRadian = (2 * PI - sumRadian) / count / 2;\n var angle = 0;\n graph.eachNode(function (node) {\n var radianHalf = halfRemainRadian + _symbolRadiansHalf[node.dataIndex];\n angle += radianHalf;\n // init circular layout for\n // 1. layout undefined node\n // 2. not fixed node\n (!node.getLayout() || !node.getLayout().fixed) && node.setLayout([r * Math.cos(angle) + cx, r * Math.sin(angle) + cy]);\n angle += radianHalf;\n });\n }\n};\nexport function rotateNodeLabel(node, circularRotateLabel, cx, cy) {\n var el = node.getGraphicEl();\n // need to check if el exists. '-' value may not create node element.\n if (!el) {\n return;\n }\n var nodeModel = node.getModel();\n var labelRotate = nodeModel.get(['label', 'rotate']) || 0;\n var symbolPath = el.getSymbolPath();\n if (circularRotateLabel) {\n var pos = node.getLayout();\n var rad = Math.atan2(pos[1] - cy, pos[0] - cx);\n if (rad < 0) {\n rad = Math.PI * 2 + rad;\n }\n var isLeft = pos[0] < cx;\n if (isLeft) {\n rad = rad - Math.PI;\n }\n var textPosition = isLeft ? 'left' : 'right';\n symbolPath.setTextConfig({\n rotation: -rad,\n position: textPosition,\n origin: 'center'\n });\n var emphasisState = symbolPath.ensureState('emphasis');\n zrUtil.extend(emphasisState.textConfig || (emphasisState.textConfig = {}), {\n position: textPosition\n });\n } else {\n symbolPath.setTextConfig({\n rotation: labelRotate *= Math.PI / 180\n });\n }\n}"],"mappings":"AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,K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