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AKqH,UAEnD,OADAwC,EAAMA,GAAO,GACNxC,EAAYjC,EAAiByE,EAAKtH,EAAM8E,GAAarC,EAAOgE,KAAKa,EAAKtH,EAC/E,EAOAW,YAAa,SAAUC,GACrB,IAAIgG,EAAenJ,KAAKmJ,aACxB,OAAOA,EAAe/D,EAAiB,GAAIjC,EAAOgG,GAAgB,CAAChG,EAAM,GAAIA,EAAM,GACrF,EAMA2G,eAAgB/E,EAAOgF,MAAMhE,EAAW,eAMxCiE,iBAAkBjF,EAAOgF,MAAMhE,EAAW,eAM1CkE,aAAc,SAAU9G,GACtB,OAAOnD,KAAKyJ,uBAAuBvH,QAAQiB,EAAM,GAAIA,EAAM,GAC7D,GAYF4B,EAAOwB,MAAMf,EAAML,GASnB,IAAIP,EAAWY,EACfX,EAAOC,QAAUF,C","sources":["webpack://i4proportal/./node_modules/echarts/lib/coord/Axis.js","webpack://i4proportal/./node_modules/echarts/lib/coord/View.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\nvar _util = require(\"zrender/lib/core/util\");\n\nvar each = _util.each;\nvar map = _util.map;\n\nvar _number = require(\"../util/number\");\n\nvar linearMap = _number.linearMap;\nvar getPixelPrecision = _number.getPixelPrecision;\nvar round = _number.round;\n\nvar _axisTickLabelBuilder = require(\"./axisTickLabelBuilder\");\n\nvar createAxisTicks = _axisTickLabelBuilder.createAxisTicks;\nvar createAxisLabels = _axisTickLabelBuilder.createAxisLabels;\nvar calculateCategoryInterval = _axisTickLabelBuilder.calculateCategoryInterval;\n\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*/\nvar NORMALIZED_EXTENT = [0, 1];\n/**\n * Base class of Axis.\n * @constructor\n */\n\nvar Axis = function (dim, scale, extent) {\n /**\n * Axis dimension. Such as 'x', 'y', 'z', 'angle', 'radius'.\n * @type {string}\n */\n this.dim = dim;\n /**\n * Axis scale\n * @type {module:echarts/coord/scale/*}\n */\n\n this.scale = scale;\n /**\n * @type {Array.}\n * @private\n */\n\n this._extent = extent || [0, 0];\n /**\n * @type {boolean}\n */\n\n this.inverse = false;\n /**\n * Usually true when axis has a ordinal scale\n * @type {boolean}\n */\n\n this.onBand = false;\n};\n\nAxis.prototype = {\n constructor: Axis,\n\n /**\n * If axis extent contain given coord\n * @param {number} coord\n * @return {boolean}\n */\n contain: function (coord) {\n var extent = this._extent;\n var min = Math.min(extent[0], extent[1]);\n var max = Math.max(extent[0], extent[1]);\n return coord >= min && coord <= max;\n },\n\n /**\n * If axis extent contain given data\n * @param {number} data\n * @return {boolean}\n */\n containData: function (data) {\n return this.scale.contain(data);\n },\n\n /**\n * Get coord extent.\n * @return {Array.}\n */\n getExtent: function () {\n return this._extent.slice();\n },\n\n /**\n * Get precision used for formatting\n * @param {Array.} [dataExtent]\n * @return {number}\n */\n getPixelPrecision: function (dataExtent) {\n return getPixelPrecision(dataExtent || this.scale.getExtent(), this._extent);\n },\n\n /**\n * Set coord extent\n * @param {number} start\n * @param {number} end\n */\n setExtent: function (start, end) {\n var extent = this._extent;\n extent[0] = start;\n extent[1] = end;\n },\n\n /**\n * Convert data to coord. Data is the rank if it has an ordinal scale\n * @param {number} data\n * @param {boolean} clamp\n * @return {number}\n */\n dataToCoord: function (data, clamp) {\n var extent = this._extent;\n var scale = this.scale;\n data = scale.normalize(data);\n\n if (this.onBand && scale.type === 'ordinal') {\n extent = extent.slice();\n fixExtentWithBands(extent, scale.count());\n }\n\n return linearMap(data, NORMALIZED_EXTENT, extent, clamp);\n },\n\n /**\n * Convert coord to data. Data is the rank if it has an ordinal scale\n * @param {number} coord\n * @param {boolean} clamp\n * @return {number}\n */\n coordToData: function (coord, clamp) {\n var extent = this._extent;\n var scale = this.scale;\n\n if (this.onBand && scale.type === 'ordinal') {\n extent = extent.slice();\n fixExtentWithBands(extent, scale.count());\n }\n\n var t = linearMap(coord, extent, NORMALIZED_EXTENT, clamp);\n return this.scale.scale(t);\n },\n\n /**\n * Convert pixel point to data in axis\n * @param {Array.} point\n * @param {boolean} clamp\n * @return {number} data\n */\n pointToData: function (point, clamp) {// Should be implemented in derived class if necessary.\n },\n\n /**\n * Different from `zrUtil.map(axis.getTicks(), axis.dataToCoord, axis)`,\n * `axis.getTicksCoords` considers `onBand`, which is used by\n * `boundaryGap:true` of category axis and splitLine and splitArea.\n * @param {Object} [opt]\n * @param {Model} [opt.tickModel=axis.model.getModel('axisTick')]\n * @param {boolean} [opt.clamp] If `true`, the first and the last\n * tick must be at the axis end points. Otherwise, clip ticks\n * that outside the axis extent.\n * @return {Array.} [{\n * coord: ...,\n * tickValue: ...\n * }, ...]\n */\n getTicksCoords: function (opt) {\n opt = opt || {};\n var tickModel = opt.tickModel || this.getTickModel();\n var result = createAxisTicks(this, tickModel);\n var ticks = result.ticks;\n var ticksCoords = map(ticks, function (tickValue) {\n return {\n coord: this.dataToCoord(tickValue),\n tickValue: tickValue\n };\n }, this);\n var alignWithLabel = tickModel.get('alignWithLabel');\n fixOnBandTicksCoords(this, ticksCoords, alignWithLabel, opt.clamp);\n return ticksCoords;\n },\n\n /**\n * @return {Array.>} [{ coord: ..., tickValue: ...}]\n */\n getMinorTicksCoords: function () {\n if (this.scale.type === 'ordinal') {\n // Category axis doesn't support minor ticks\n return [];\n }\n\n var minorTickModel = this.model.getModel('minorTick');\n var splitNumber = minorTickModel.get('splitNumber'); // Protection.\n\n if (!(splitNumber > 0 && splitNumber < 100)) {\n splitNumber = 5;\n }\n\n var minorTicks = this.scale.getMinorTicks(splitNumber);\n var minorTicksCoords = map(minorTicks, function (minorTicksGroup) {\n return map(minorTicksGroup, function (minorTick) {\n return {\n coord: this.dataToCoord(minorTick),\n tickValue: minorTick\n };\n }, this);\n }, this);\n return minorTicksCoords;\n },\n\n /**\n * @return {Array.} [{\n * formattedLabel: string,\n * rawLabel: axis.scale.getLabel(tickValue)\n * tickValue: number\n * }, ...]\n */\n getViewLabels: function () {\n return createAxisLabels(this).labels;\n },\n\n /**\n * @return {module:echarts/coord/model/Model}\n */\n getLabelModel: function () {\n return this.model.getModel('axisLabel');\n },\n\n /**\n * Notice here we only get the default tick model. For splitLine\n * or splitArea, we should pass the splitLineModel or splitAreaModel\n * manually when calling `getTicksCoords`.\n * In GL, this method may be overrided to:\n * `axisModel.getModel('axisTick', grid3DModel.getModel('axisTick'));`\n * @return {module:echarts/coord/model/Model}\n */\n getTickModel: function () {\n return this.model.getModel('axisTick');\n },\n\n /**\n * Get width of band\n * @return {number}\n */\n getBandWidth: function () {\n var axisExtent = this._extent;\n var dataExtent = this.scale.getExtent();\n var len = dataExtent[1] - dataExtent[0] + (this.onBand ? 1 : 0); // Fix #2728, avoid NaN when only one data.\n\n len === 0 && (len = 1);\n var size = Math.abs(axisExtent[1] - axisExtent[0]);\n return Math.abs(size) / len;\n },\n\n /**\n * @abstract\n * @return {boolean} Is horizontal\n */\n isHorizontal: null,\n\n /**\n * @abstract\n * @return {number} Get axis rotate, by degree.\n */\n getRotate: null,\n\n /**\n * Only be called in category axis.\n * Can be overrided, consider other axes like in 3D.\n * @return {number} Auto interval for cateogry axis tick and label\n */\n calculateCategoryInterval: function () {\n return calculateCategoryInterval(this);\n }\n};\n\nfunction fixExtentWithBands(extent, nTick) {\n var size = extent[1] - extent[0];\n var len = nTick;\n var margin = size / len / 2;\n extent[0] += margin;\n extent[1] -= margin;\n} // If axis has labels [1, 2, 3, 4]. Bands on the axis are\n// |---1---|---2---|---3---|---4---|.\n// So the displayed ticks and splitLine/splitArea should between\n// each data item, otherwise cause misleading (e.g., split tow bars\n// of a single data item when there are two bar series).\n// Also consider if tickCategoryInterval > 0 and onBand, ticks and\n// splitLine/spliteArea should layout appropriately corresponding\n// to displayed labels. (So we should not use `getBandWidth` in this\n// case).\n\n\nfunction fixOnBandTicksCoords(axis, ticksCoords, alignWithLabel, clamp) {\n var ticksLen = ticksCoords.length;\n\n if (!axis.onBand || alignWithLabel || !ticksLen) {\n return;\n }\n\n var axisExtent = axis.getExtent();\n var last;\n var diffSize;\n\n if (ticksLen === 1) {\n ticksCoords[0].coord = axisExtent[0];\n last = ticksCoords[1] = {\n coord: axisExtent[0]\n };\n } else {\n var crossLen = ticksCoords[ticksLen - 1].tickValue - ticksCoords[0].tickValue;\n var shift = (ticksCoords[ticksLen - 1].coord - ticksCoords[0].coord) / crossLen;\n each(ticksCoords, function (ticksItem) {\n ticksItem.coord -= shift / 2;\n });\n var dataExtent = axis.scale.getExtent();\n diffSize = 1 + dataExtent[1] - ticksCoords[ticksLen - 1].tickValue;\n last = {\n coord: ticksCoords[ticksLen - 1].coord + shift * diffSize\n };\n ticksCoords.push(last);\n }\n\n var inverse = axisExtent[0] > axisExtent[1]; // Handling clamp.\n\n if (littleThan(ticksCoords[0].coord, axisExtent[0])) {\n clamp ? ticksCoords[0].coord = axisExtent[0] : ticksCoords.shift();\n }\n\n if (clamp && littleThan(axisExtent[0], ticksCoords[0].coord)) {\n ticksCoords.unshift({\n coord: axisExtent[0]\n });\n }\n\n if (littleThan(axisExtent[1], last.coord)) {\n clamp ? last.coord = axisExtent[1] : ticksCoords.pop();\n }\n\n if (clamp && littleThan(last.coord, axisExtent[1])) {\n ticksCoords.push({\n coord: axisExtent[1]\n });\n }\n\n function littleThan(a, b) {\n // Avoid rounding error cause calculated tick coord different with extent.\n // It may cause an extra unecessary tick added.\n a = round(a);\n b = round(b);\n return inverse ? a > b : a < b;\n }\n}\n\nvar _default = Axis;\nmodule.exports = _default;","\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\nvar zrUtil = require(\"zrender/lib/core/util\");\n\nvar vector = require(\"zrender/lib/core/vector\");\n\nvar matrix = require(\"zrender/lib/core/matrix\");\n\nvar BoundingRect = require(\"zrender/lib/core/BoundingRect\");\n\nvar Transformable = require(\"zrender/lib/mixin/Transformable\");\n\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 * Simple view coordinate system\n * Mapping given x, y to transformd view x, y\n */\nvar v2ApplyTransform = vector.applyTransform; // Dummy transform node\n\nfunction TransformDummy() {\n Transformable.call(this);\n}\n\nzrUtil.mixin(TransformDummy, Transformable);\n\nfunction View(name) {\n /**\n * @type {string}\n */\n this.name = name;\n /**\n * @type {Object}\n */\n\n this.zoomLimit;\n Transformable.call(this);\n this._roamTransformable = new TransformDummy();\n this._rawTransformable = new TransformDummy();\n this._center;\n this._zoom;\n}\n\nView.prototype = {\n constructor: View,\n type: 'view',\n\n /**\n * @param {Array.}\n * @readOnly\n */\n dimensions: ['x', 'y'],\n\n /**\n * Set bounding rect\n * @param {number} x\n * @param {number} y\n * @param {number} width\n * @param {number} height\n */\n // PENDING to getRect\n setBoundingRect: function (x, y, width, height) {\n this._rect = new BoundingRect(x, y, width, height);\n return this._rect;\n },\n\n /**\n * @return {module:zrender/core/BoundingRect}\n */\n // PENDING to getRect\n getBoundingRect: function () {\n return this._rect;\n },\n\n /**\n * @param {number} x\n * @param {number} y\n * @param {number} width\n * @param {number} height\n */\n setViewRect: function (x, y, width, height) {\n this.transformTo(x, y, width, height);\n this._viewRect = new BoundingRect(x, y, width, height);\n },\n\n /**\n * Transformed to particular position and size\n * @param {number} x\n * @param {number} y\n * @param {number} width\n * @param {number} height\n */\n transformTo: function (x, y, width, height) {\n var rect = this.getBoundingRect();\n var rawTransform = this._rawTransformable;\n rawTransform.transform = rect.calculateTransform(new BoundingRect(x, y, width, height));\n rawTransform.decomposeTransform();\n\n this._updateTransform();\n },\n\n /**\n * Set center of view\n * @param {Array.} [centerCoord]\n */\n setCenter: function (centerCoord) {\n if (!centerCoord) {\n return;\n }\n\n this._center = centerCoord;\n\n this._updateCenterAndZoom();\n },\n\n /**\n * @param {number} zoom\n */\n setZoom: function (zoom) {\n zoom = zoom || 1;\n var zoomLimit = this.zoomLimit;\n\n if (zoomLimit) {\n if (zoomLimit.max != null) {\n zoom = Math.min(zoomLimit.max, zoom);\n }\n\n if (zoomLimit.min != null) {\n zoom = Math.max(zoomLimit.min, zoom);\n }\n }\n\n this._zoom = zoom;\n\n this._updateCenterAndZoom();\n },\n\n /**\n * Get default center without roam\n */\n getDefaultCenter: function () {\n // Rect before any transform\n var rawRect = this.getBoundingRect();\n var cx = rawRect.x + rawRect.width / 2;\n var cy = rawRect.y + rawRect.height / 2;\n return [cx, cy];\n },\n getCenter: function () {\n return this._center || this.getDefaultCenter();\n },\n getZoom: function () {\n return this._zoom || 1;\n },\n\n /**\n * @return {Array.} data\n * @param {boolean} noRoam\n * @param {Array.} [out]\n * @return {Array.}\n */\n dataToPoint: function (data, noRoam, out) {\n var transform = noRoam ? this._rawTransform : this.transform;\n out = out || [];\n return transform ? v2ApplyTransform(out, data, transform) : vector.copy(out, data);\n },\n\n /**\n * Convert a (x, y) point to (lon, lat) data\n * @param {Array.} point\n * @return {Array.}\n */\n pointToData: function (point) {\n var invTransform = this.invTransform;\n return invTransform ? v2ApplyTransform([], point, invTransform) : [point[0], point[1]];\n },\n\n /**\n * @implements\n * see {module:echarts/CoodinateSystem}\n */\n convertToPixel: zrUtil.curry(doConvert, 'dataToPoint'),\n\n /**\n * @implements\n * see {module:echarts/CoodinateSystem}\n */\n convertFromPixel: zrUtil.curry(doConvert, 'pointToData'),\n\n /**\n * @implements\n * see {module:echarts/CoodinateSystem}\n */\n containPoint: function (point) {\n return this.getViewRectAfterRoam().contain(point[0], point[1]);\n }\n /**\n * @return {number}\n */\n // getScalarScale: function () {\n // // Use determinant square root of transform to mutiply scalar\n // var m = this.transform;\n // var det = Math.sqrt(Math.abs(m[0] * m[3] - m[2] * m[1]));\n // return det;\n // }\n\n};\nzrUtil.mixin(View, Transformable);\n\nfunction doConvert(methodName, ecModel, finder, value) {\n var seriesModel = finder.seriesModel;\n var coordSys = seriesModel ? seriesModel.coordinateSystem : null; // e.g., graph.\n\n return coordSys === this ? coordSys[methodName](value) : null;\n}\n\nvar _default = View;\nmodule.exports = _default;"],"names":["_util","each","map","_number","linearMap","getPixelPrecision","round","_axisTickLabelBuilder","createAxisTicks","createAxisLabels","calculateCategoryInterval","NORMALIZED_EXTENT","Axis","dim","scale","extent","this","_extent","inverse","onBand","fixExtentWithBands","nTick","size","len","margin","fixOnBandTicksCoords","axis","ticksCoords","alignWithLabel","clamp","ticksLen","length","last","diffSize","axisExtent","getExtent","coord","crossLen","tickValue","shift","ticksItem","dataExtent","push","littleThan","unshift","pop","a","b","prototype","constructor","contain","min","Math","max","containData","data","slice","setExtent","start","end","dataToCoord","normalize","type","count","coordToData","t","pointToData","point","getTicksCoords","opt","tickModel","getTickModel","result","ticks","get","getMinorTicksCoords","minorTickModel","model","getModel","splitNumber","minorTicks","getMinorTicks","minorTicksCoords","minorTicksGroup","minorTick","getViewLabels","labels","getLabelModel","getBandWidth","abs","isHorizontal","getRotate","_default","module","exports","zrUtil","vector","matrix","BoundingRect","Transformable","v2ApplyTransform","applyTransform","TransformDummy","call","View","name","zoomLimit","_roamTransformable","_rawTransformable","_center","_zoom","doConvert","methodName","ecModel","finder","value","seriesModel","coordSys","coordinateSystem","mixin","dimensions","setBoundingRect","x","y","width","height","_rect","getBoundingRect","setViewRect","transformTo","_viewRect","rect","rawTransform","transform","calculateTransform","decomposeTransform","_updateTransform","setCenter","centerCoord","_updateCenterAndZoom","setZoom","zoom","getDefaultCenter","rawRect","cx","cy","getCenter","getZoom","getRoamTransform","getLocalTransform","rawTransformMatrix","roamTransform","defaultCenter","center","origin","position","roamTransformable","rawTransformable","parent","updateTransform","copy","create","_rawTransform","invTransform","invert","getTransformInfo","rawScale","rawPosition","getViewRect","getViewRectAfterRoam","clone","dataToPoint","noRoam","out","convertToPixel","curry","convertFromPixel","containPoint"],"sourceRoot":""}